net.sf.dict4j.url.dict
Class DictURLConnection

java.lang.Object
  extended by java.net.URLConnection
      extended by net.sf.dict4j.url.dict.DictURLConnection
Direct Known Subclasses:
DefineDictURLConnection, MatchDictURLConnection

public abstract class DictURLConnection
extends java.net.URLConnection


Field Summary
protected  java.lang.String database
           
protected  java.lang.Integer offset
           
protected  DictSession session
           
protected  java.lang.String word
           
 
Fields inherited from class java.net.URLConnection
allowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCaches
 
Constructor Summary
DictURLConnection(java.net.URL url)
           
 
Method Summary
 void addRequestProperty(java.lang.String s, java.lang.String s1)
          Deprecated. This method is not used by DictURLConnection class
 void connect()
           
 void disconnect()
           
 boolean getAllowUserInteraction()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getAuth()
           
 java.lang.Object getContent(java.lang.Class[] classes)
           
 java.lang.String getContentEncoding()
          Deprecated. This method is not used by DictURLConnection class
 int getContentLength()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getContentType()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getDatabase()
           
 long getDate()
          Deprecated. This method is not used by DictURLConnection class
 boolean getDefaultUseCaches()
          Deprecated. This method is not used by DictURLConnection class
 boolean getDoInput()
          Deprecated. This method is not used by DictURLConnection class
 boolean getDoOutput()
          Deprecated. This method is not used by DictURLConnection class
 long getExpiration()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getHeaderField(int i)
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getHeaderField(java.lang.String s)
          Deprecated. This method is not used by DictURLConnection class
 long getHeaderFieldDate(java.lang.String s, long l)
          Deprecated. This method is not used by DictURLConnection class
 int getHeaderFieldInt(java.lang.String s, int i)
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getHeaderFieldKey(int i)
          Deprecated. This method is not used by DictURLConnection class
 java.util.Map<java.lang.String,java.util.List<java.lang.String>> getHeaderFields()
          Deprecated. This method is not used by DictURLConnection class
 long getIfModifiedSince()
          Deprecated. This method is not used by DictURLConnection class
 java.io.InputStream getInputStream()
           
 long getLastModified()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.Integer getOffset()
           
 java.io.OutputStream getOutputStream()
           
 java.util.Map<java.lang.String,java.util.List<java.lang.String>> getRequestProperties()
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getRequestProperty(java.lang.String s)
          Deprecated. This method is not used by DictURLConnection class
 java.lang.String getUsername()
           
 java.lang.String getWord()
           
protected abstract  void parseParameters(java.lang.String[] parameters)
           
 void setAllowUserInteraction(boolean b)
          Deprecated. This method is not used by DictURLConnection class
 void setDefaultUseCaches(boolean b)
          Deprecated. This method is not used by DictURLConnection class
 void setDoInput(boolean b)
          Deprecated. This method is not used by DictURLConnection class
 void setDoOutput(boolean b)
          Deprecated. This method is not used by DictURLConnection class
 void setIfModifiedSince(long l)
          Deprecated. This method is not used by DictURLConnection class
 void setPassphrase(java.lang.String passphrase)
          Whenever authentication is required, the client SHOULD request additional information (e.g., a passphrase) from the user.
 void setRequestProperty(java.lang.String s, java.lang.String s1)
          Deprecated. This method is not used by DictURLConnection class
 
Methods inherited from class java.net.URLConnection
getConnectTimeout, getContent, getDefaultAllowUserInteraction, getDefaultRequestProperty, getFileNameMap, getPermission, getReadTimeout, getURL, getUseCaches, guessContentTypeFromName, guessContentTypeFromStream, setConnectTimeout, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setFileNameMap, setReadTimeout, setUseCaches, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

session

protected DictSession session

word

protected java.lang.String word

database

protected java.lang.String database

offset

protected java.lang.Integer offset
Constructor Detail

DictURLConnection

public DictURLConnection(java.net.URL url)
                  throws java.net.MalformedURLException
Throws:
java.net.MalformedURLException
Method Detail

connect

public void connect()
Specified by:
connect in class java.net.URLConnection

disconnect

public void disconnect()

parseParameters

protected abstract void parseParameters(java.lang.String[] parameters)
                                 throws java.net.MalformedURLException
Throws:
java.net.MalformedURLException

setPassphrase

public void setPassphrase(java.lang.String passphrase)
Whenever authentication is required, the client SHOULD request additional information (e.g., a passphrase) from the user. In contrast to [RFC1738], clear text passwords are not permitted in the URL.

Parameters:
passphrase - passphrase [RFC1738]

getOutputStream

public java.io.OutputStream getOutputStream()
                                     throws java.io.IOException
Overrides:
getOutputStream in class java.net.URLConnection
Throws:
java.io.IOException

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Overrides:
getInputStream in class java.net.URLConnection
Throws:
java.io.IOException

getContent

public java.lang.Object getContent(java.lang.Class[] classes)
                            throws java.io.IOException
Overrides:
getContent in class java.net.URLConnection
Throws:
java.io.IOException

getWord

public java.lang.String getWord()

getDatabase

public java.lang.String getDatabase()

getOffset

public java.lang.Integer getOffset()

getUsername

public java.lang.String getUsername()

getAuth

public java.lang.String getAuth()

getHeaderField

public java.lang.String getHeaderField(int i)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderField in class java.net.URLConnection

getHeaderFieldKey

public java.lang.String getHeaderFieldKey(int i)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderFieldKey in class java.net.URLConnection

getHeaderFieldDate

public long getHeaderFieldDate(java.lang.String s,
                               long l)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderFieldDate in class java.net.URLConnection

getHeaderFieldInt

public int getHeaderFieldInt(java.lang.String s,
                             int i)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderFieldInt in class java.net.URLConnection

getHeaderFields

public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getHeaderFields()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderFields in class java.net.URLConnection

getHeaderField

public java.lang.String getHeaderField(java.lang.String s)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getHeaderField in class java.net.URLConnection

getLastModified

public long getLastModified()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getLastModified in class java.net.URLConnection

getDate

public long getDate()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getDate in class java.net.URLConnection

getExpiration

public long getExpiration()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getExpiration in class java.net.URLConnection

getContentEncoding

public java.lang.String getContentEncoding()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getContentEncoding in class java.net.URLConnection

getContentType

public java.lang.String getContentType()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getContentType in class java.net.URLConnection

getContentLength

public int getContentLength()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getContentLength in class java.net.URLConnection

setDoInput

public void setDoInput(boolean b)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setDoInput in class java.net.URLConnection

getDoInput

public boolean getDoInput()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getDoInput in class java.net.URLConnection

setDoOutput

public void setDoOutput(boolean b)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setDoOutput in class java.net.URLConnection

getDoOutput

public boolean getDoOutput()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getDoOutput in class java.net.URLConnection

setAllowUserInteraction

public void setAllowUserInteraction(boolean b)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setAllowUserInteraction in class java.net.URLConnection

getAllowUserInteraction

public boolean getAllowUserInteraction()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getAllowUserInteraction in class java.net.URLConnection

setIfModifiedSince

public void setIfModifiedSince(long l)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setIfModifiedSince in class java.net.URLConnection

getIfModifiedSince

public long getIfModifiedSince()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getIfModifiedSince in class java.net.URLConnection

getDefaultUseCaches

public boolean getDefaultUseCaches()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getDefaultUseCaches in class java.net.URLConnection

setDefaultUseCaches

public void setDefaultUseCaches(boolean b)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setDefaultUseCaches in class java.net.URLConnection

setRequestProperty

public void setRequestProperty(java.lang.String s,
                               java.lang.String s1)
Deprecated. This method is not used by DictURLConnection class

Overrides:
setRequestProperty in class java.net.URLConnection

addRequestProperty

public void addRequestProperty(java.lang.String s,
                               java.lang.String s1)
Deprecated. This method is not used by DictURLConnection class

Overrides:
addRequestProperty in class java.net.URLConnection

getRequestProperty

public java.lang.String getRequestProperty(java.lang.String s)
Deprecated. This method is not used by DictURLConnection class

Overrides:
getRequestProperty in class java.net.URLConnection

getRequestProperties

public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getRequestProperties()
Deprecated. This method is not used by DictURLConnection class

Overrides:
getRequestProperties in class java.net.URLConnection