IP*Works! SSL V6

ipworksssl
Class Nntps

java.lang.Object
  |
  +--ipworksssl.Nntps

public class Nntps
extends java.lang.Object

The NNTPS bean is used to read and post articles on Usenet news servers.

The NNTPS bean is the SSL-enabled equivalent of the IP*Works! NNTP bean. The main difference is the introduction of a set of new configuration settings, properties and events that deal with SSL security. TheSSLProviderconfiguration setting chooses a security provider subsystem. TheSSLEnabledProtocolsandSSLCipherStrengthconfiguration settings determine which protocols are enabled and at what security level. The SSLCertStore , SSLCertSubject , and SSLCertEncoded properties are used to select a client certificate if the server is requesting client authentication. TheSSLSecurityFlagsconfiguration setting, together with the SSLServerAuthentication event allow you to check the server identity and other security attributes. Finally, the SSLStatus event provides information about the SSL handshake.

The NNTPS bean implements a standard Usenet news reader as specified in RFC 977. It can be used to browse Usenet news groups and read and post articles.

The CurrentGroup property sets the current newsgroup. From then on, news articles from that group can be read by setting the article number in CurrentArticle and then calling the appropriate method. Properties such as ArticleCount , FirstArticle , LastArticle provide information about the current state.

The headers and text of the articles are received respectively through the Header and Transfer events. Additionally, up to MaxLines from the article body are provided in the ArticleText property. The GroupOverview event returns information about a range of articles ( OverviewRange ) in CurrentGroup , and the GroupList event is used when listing newsgroup names. The PITrail event provides a trace of the interaction with the server.

The bean supports posting of articles through the ArticleText and AttachedFile properties. The article text is specified in one or both of the above, and then the PostArticle method is called. Article headers are given in a series of properties like ArticleFrom , ArticleSubject , Organization , etc. that map directly to the USENET article header with the same name.


Field Summary
static int fwNone
           
static int fwSOCKS4
           
static int fwSOCKS5
           
static int fwTunnel
           
static int sslAutomatic
           
static int sslExplicit
           
static int sslImplicit
           
static int sslNone
           
static int sstMachine
           
static int sstPEMKey
           
static int sstPFXBlob
           
static int sstPFXFile
           
static int sstUser
           
 
Constructor Summary
Nntps()
           
 
Method Summary
 void addNntpsEventListener(NntpsEventListener l)
           
 java.lang.String config(java.lang.String configurationString)
          Sets or retrieves a beanconfiguration setting.
 void connect()
          Connect to the news server.
 void disconnect()
          Disconnect from the news server.
 void doEvents()
          Processes events from the internal message queue.
 void fetchArticle()
          Get the headers and body of an article specified in CurrentArticle .
 void fetchArticleBody()
          Get only the body of an article specified in CurrentArticle .
 void fetchArticleHeaders()
          Get only the headers of an article specified in CurrentArticle .
 int getArticleCount()
          The estimated number of articles in CurrentGroup .
 java.lang.String getArticleDate()
          The date of the current article.
 java.lang.String getArticleFrom()
          The email address of the author (for posting articles).
 java.lang.String getArticleHeaders()
          The full headers of the article as retrieved from the server.
 java.lang.String getArticleId()
          The message-id of the current article.
 java.lang.String getArticleReferences()
          Articles the posted article follows up to.
 java.lang.String getArticleReplyTo()
          The address to reply to (for posting articles).
 java.lang.String getArticleSubject()
          The article subject (for posted articles).
 java.lang.String getArticleText()
          The full text of the article (without the headers).
 java.lang.String getAttachedFile()
          A file name of which the contents will be appended to ArticleText when posting articles.
 java.lang.String getCheckDate()
          The date (format YYMMDD HHMMSS) to check for creation of new groups.
 java.lang.String getCurrentArticle()
          The number or message-id of the current article.
 java.lang.String getCurrentGroup()
          The name of the current group.
 java.lang.String getFirewallHost()
          Name or IP address of firewall (optional).
 java.lang.String getFirewallPassword()
          A password if authentication is to be used when connecting through the firewall.
 int getFirewallPort()
          Port of the firewall to connect to.
 int getFirewallType()
          Determines the type of firewall to connect through.
 java.lang.String getFirewallUser()
          A user name if authentication is to be used connecting through a firewall.
 int getFirstArticle()
          The number of the first article in CurrentGroup.
 int getLastArticle()
          The number of the last article in CurrentGroup .
 java.lang.String getLastReply()
          The last reply from the server.
 java.lang.String getLocalHost()
          The name of the local host or user-assigned IP interface through which connections are initiated or accepted.
 int getMaxLines()
          The maximum number of message lines besides headers to retrieve.
 java.lang.String getNewsgroups()
          A comma separated list of newsgroups in which to post the article.
 int getNewsPort()
          The server port for secure NNTP (default 563).
 java.lang.String getNewsServer()
          The name or address of a news server.
 java.lang.String getOrganization()
          The organization of the author (for posting articles).
 java.lang.String getOtherHeaders()
          An RFC850 compliant string consisting of extra headers (for posting articles).
 java.lang.String getOverviewRange()
          A range for the GroupOverview method (first-last).
 java.lang.String getPassword()
          A login password to login with in the NewsServer .
 java.lang.String getSearchHeader()
          A header for the GroupSearch method.
 java.lang.String getSearchPattern()
          A search pattern for the GroupSearch method.
 java.lang.String getSearchRange()
          A range for the GroupSearch method (first-last).
 byte[] getSSLAcceptServerCert()
          Instructs the bean to unconditionally accept the server certificate that matches the supplied certificate.
 byte[] getSSLCertEncoded()
          The SSL certificate (PEM/base64 encoded).
 byte[] getSSLCertStore()
          The name of the certificate store for the client certificate.
 java.lang.String getSSLCertStorePassword()
          The password for the certificate store (if any).
 int getSSLCertStoreType()
          The type of certificate store for the client certificate.
 java.lang.String getSSLCertSubject()
          The subject of the certificate used for client authentication.
 byte[] getSSLServerCert()
          The server certificate for the last established connection.
 java.lang.String getSSLServerCertStatus()
          The verification status of the server certificate for the last established connection.
 int getSSLStartMode()
          Determines how the bean starts the SSL negotiation.
 int getTimeout()
          A timeout for the bean.
 java.lang.String getUser()
          A user id to login as in the NewsServer .
 void groupOverview()
          Receive an overview for the articles in range OverviewRange in the CurrentGroup .
 void groupSearch()
          Receive an overview for the articles in range OverviewRange in the CurrentGroup .
 void interrupt()
          Interrupt the current method.
 boolean isConnected()
          Shows whether the bean is connected.
 boolean isIdle()
          The current status of the component.
 void listGroups()
          List all groups on the server.
 void listNewGroups()
          List all new groups on the server.
 java.lang.String localizeDate(java.lang.String dateTime)
          Converts a valid RFC 822 message date to local date and time.
 void postArticle()
          Post the current article and attached file.
 void removeNntpsEventListener(NntpsEventListener l)
           
 void resetHeaders()
          Reset all of the article headers.
 void setArticleFrom(java.lang.String articleFrom)
          The email address of the author (for posting articles).
 void setArticleReferences(java.lang.String articleReferences)
          Articles the posted article follows up to.
 void setArticleReplyTo(java.lang.String articleReplyTo)
          The address to reply to (for posting articles).
 void setArticleSubject(java.lang.String articleSubject)
          The article subject (for posted articles).
 void setArticleText(java.lang.String articleText)
          The full text of the article (without the headers).
 void setAttachedFile(java.lang.String attachedFile)
          A file name of which the contents will be appended to ArticleText when posting articles.
 void setCheckDate(java.lang.String checkDate)
          The date (format YYMMDD HHMMSS) to check for creation of new groups.
 void setCommand(java.lang.String command)
          Can be used to send additional commands directly to the server.
 void setConnected(boolean connected)
          Shows whether the bean is connected.
 void setCurrentArticle(java.lang.String currentArticle)
          The number or message-id of the current article.
 void setCurrentGroup(java.lang.String currentGroup)
          The name of the current group.
 void setFirewallHost(java.lang.String firewallHost)
          Name or IP address of firewall (optional).
 void setFirewallPassword(java.lang.String firewallPassword)
          A password if authentication is to be used when connecting through the firewall.
 void setFirewallPort(int firewallPort)
          Port of the firewall to connect to.
 void setFirewallType(int firewallType)
          Determines the type of firewall to connect through.
 void setFirewallUser(java.lang.String firewallUser)
          A user name if authentication is to be used connecting through a firewall.
 void setLocalHost(java.lang.String localHost)
          The name of the local host or user-assigned IP interface through which connections are initiated or accepted.
 void setMaxLines(int maxLines)
          The maximum number of message lines besides headers to retrieve.
 void setNewsgroups(java.lang.String newsgroups)
          A comma separated list of newsgroups in which to post the article.
 void setNewsPort(int newsPort)
          The server port for secure NNTP (default 563).
 void setNewsServer(java.lang.String newsServer)
          The name or address of a news server.
 void setOrganization(java.lang.String organization)
          The organization of the author (for posting articles).
 void setOtherHeaders(java.lang.String otherHeaders)
          An RFC850 compliant string consisting of extra headers (for posting articles).
 void setOverviewRange(java.lang.String overviewRange)
          A range for the GroupOverview method (first-last).
 void setPassword(java.lang.String password)
          A login password to login with in the NewsServer .
 void setSearchHeader(java.lang.String searchHeader)
          A header for the GroupSearch method.
 void setSearchPattern(java.lang.String searchPattern)
          A search pattern for the GroupSearch method.
 void setSearchRange(java.lang.String searchRange)
          A range for the GroupSearch method (first-last).
 void setSSLAcceptServerCert(byte[] SSLAcceptServerCert)
          Instructs the bean to unconditionally accept the server certificate that matches the supplied certificate.
 void setSSLCertEncoded(byte[] SSLCertEncoded)
          The SSL certificate (PEM/base64 encoded).
 void setSSLCertStore(byte[] SSLCertStore)
          The name of the certificate store for the client certificate.
 void setSSLCertStorePassword(java.lang.String SSLCertStorePassword)
          The password for the certificate store (if any).
 void setSSLCertStoreType(int SSLCertStoreType)
          The type of certificate store for the client certificate.
 void setSSLCertSubject(java.lang.String SSLCertSubject)
          The subject of the certificate used for client authentication.
 void setSSLStartMode(int SSLStartMode)
          Determines how the bean starts the SSL negotiation.
 void setTimeout(int timeout)
          A timeout for the bean.
 void setUser(java.lang.String user)
          A user id to login as in the NewsServer .
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fwNone

public static final int fwNone
See Also:
Constant Field Values

fwTunnel

public static final int fwTunnel
See Also:
Constant Field Values

fwSOCKS4

public static final int fwSOCKS4
See Also:
Constant Field Values

fwSOCKS5

public static final int fwSOCKS5
See Also:
Constant Field Values

sstUser

public static final int sstUser
See Also:
Constant Field Values

sstMachine

public static final int sstMachine
See Also:
Constant Field Values

sstPFXFile

public static final int sstPFXFile
See Also:
Constant Field Values

sstPFXBlob

public static final int sstPFXBlob
See Also:
Constant Field Values

sstPEMKey

public static final int sstPEMKey
See Also:
Constant Field Values

sslAutomatic

public static final int sslAutomatic
See Also:
Constant Field Values

sslImplicit

public static final int sslImplicit
See Also:
Constant Field Values

sslExplicit

public static final int sslExplicit
See Also:
Constant Field Values

sslNone

public static final int sslNone
See Also:
Constant Field Values
Constructor Detail

Nntps

public Nntps()
Method Detail

getArticleCount

public int getArticleCount()
The estimated number of articles in CurrentGroup .

The value of this property is 0 if there is no current group ( CurrentGroup is ""). Otherwise, it is the number of articles in the group as shown by the news server when CurrentGroup is set. For most news servers, this is an estimated value of the number of the articles, rather than the exact value.


getArticleDate

public java.lang.String getArticleDate()
The date of the current article.

If the bean is not connected or CurrentArticle is empty, the value of this property is an empty string. Otherwise, it contains the date of the article as reported by the server. The NewsServer is asked about the headers of the article only if the CurrentArticle property has changed. If CurrentArticle has not changed, the bean returns a cached value.


getArticleFrom

public java.lang.String getArticleFrom()
The email address of the author (for posting articles).

The string in ArticleFrom is posted with a From article header to the news server.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setArticleFrom

public void setArticleFrom(java.lang.String articleFrom)
                    throws IPWorksSSLException
The email address of the author (for posting articles).

The string in ArticleFrom is posted with a From article header to the news server.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getArticleHeaders

public java.lang.String getArticleHeaders()
The full headers of the article as retrieved from the server.

If the bean is not connected or CurrentArticle is empty, the value of this property is an empty string. Otherwise, it contains the full headers of the article as reported by the server.

The NewsServer is asked about the headers of the article only if the CurrentArticle property has changed. If CurrentArticle has not changed, the bean returns a cached value.


getArticleId

public java.lang.String getArticleId()
The message-id of the current article.

If the bean is not connected or CurrentArticle is empty, the value of this property is an empty string. Otherwise, it contains the message-id of the article as reported by the server. The NewsServer is asked about the headers of the article only if the CurrentArticle property has changed. If CurrentArticle has not changed, the bean returns a cached value.


getArticleReferences

public java.lang.String getArticleReferences()
Articles the posted article follows up to.

If the ArticleReferences property contains a non-empty string, a References article header is created for the article. This header shows the article-ids the posted article refers to.

The references must be separated by space characters.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setArticleReferences

public void setArticleReferences(java.lang.String articleReferences)
                          throws IPWorksSSLException
Articles the posted article follows up to.

If the ArticleReferences property contains a non-empty string, a References article header is created for the article. This header shows the article-ids the posted article refers to.

The references must be separated by space characters.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getArticleReplyTo

public java.lang.String getArticleReplyTo()
The address to reply to (for posting articles).

If the ArticleReplyTo property contains a non-empty string, a Reply-To article header is created for the article. This header shows the address to use for replies (useful if this address is different from the one in ArticleFrom ).

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setArticleReplyTo

public void setArticleReplyTo(java.lang.String articleReplyTo)
                       throws IPWorksSSLException
The address to reply to (for posting articles).

If the ArticleReplyTo property contains a non-empty string, a Reply-To article header is created for the article. This header shows the address to use for replies (useful if this address is different from the one in ArticleFrom ).

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getArticleSubject

public java.lang.String getArticleSubject()
The article subject (for posted articles).

The string in ArticleSubject is posted with a Subject article header to the news server.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setArticleSubject

public void setArticleSubject(java.lang.String articleSubject)
                       throws IPWorksSSLException
The article subject (for posted articles).

The string in ArticleSubject is posted with a Subject article header to the news server.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getArticleText

public java.lang.String getArticleText()
The full text of the article (without the headers).

If the bean is not connected or CurrentArticle is empty, the value of this property is an empty string. Otherwise, it contains the full text of the article as reported by the server.

The NewsServer is asked about the text of the article only if the CurrentArticle property has changed. If CurrentArticle has not changed, the bean returns a cached value.

When posting articles, the ArticleText property contains the full text of the article to post.

It is advisable that the text contained in this property be a collection of lines with lengths less than or equal to 80 bytes separated by CRLF ("\\r\\n") . The text in the article lines must contain 7-bit characters so that the article can be successfully transferred through the various Usenet news servers on the Internet.

The bean automatically escapes lines that start with a "." by adding another "." as specified in RFC 977. The article text is unescaped by the news server, so the process is fully transparent.


setArticleText

public void setArticleText(java.lang.String articleText)
                    throws IPWorksSSLException
The full text of the article (without the headers).

If the bean is not connected or CurrentArticle is empty, the value of this property is an empty string. Otherwise, it contains the full text of the article as reported by the server.

The NewsServer is asked about the text of the article only if the CurrentArticle property has changed. If CurrentArticle has not changed, the bean returns a cached value.

When posting articles, the ArticleText property contains the full text of the article to post.

It is advisable that the text contained in this property be a collection of lines with lengths less than or equal to 80 bytes separated by CRLF ("\\r\\n") . The text in the article lines must contain 7-bit characters so that the article can be successfully transferred through the various Usenet news servers on the Internet.

The bean automatically escapes lines that start with a "." by adding another "." as specified in RFC 977. The article text is unescaped by the news server, so the process is fully transparent.

IPWorksSSLException

getAttachedFile

public java.lang.String getAttachedFile()
A file name of which the contents will be appended to ArticleText when posting articles.

The content of AttachedFile is appended to the text in ArticleText (if any) and sent to the news server. This property is useful for posting arbitrarily large articles and/or sending MIME attachments.

It is advisable that the text contained in the file be a collection of lines with lengths less than or equal to 80 bytes separated by CRLF ("\\r\\n") . The text in the message lines must contain only 7-bit characters so that the message may be successfully sent through the various Usenet news servers on the Internet.

The bean automatically escapes lines that start with a "." by adding another as specified in RFC 822. The article text is unescaped by the news server, so the process is fully transparent.


setAttachedFile

public void setAttachedFile(java.lang.String attachedFile)
                     throws IPWorksSSLException
A file name of which the contents will be appended to ArticleText when posting articles.

The content of AttachedFile is appended to the text in ArticleText (if any) and sent to the news server. This property is useful for posting arbitrarily large articles and/or sending MIME attachments.

It is advisable that the text contained in the file be a collection of lines with lengths less than or equal to 80 bytes separated by CRLF ("\\r\\n") . The text in the message lines must contain only 7-bit characters so that the message may be successfully sent through the various Usenet news servers on the Internet.

The bean automatically escapes lines that start with a "." by adding another as specified in RFC 822. The article text is unescaped by the news server, so the process is fully transparent.

IPWorksSSLException

getCheckDate

public java.lang.String getCheckDate()
The date (format YYMMDD HHMMSS) to check for creation of new groups. If the group was created after the date specified, it is considered new.

The value of this property is used as an argument for the ListNewGroups method.


setCheckDate

public void setCheckDate(java.lang.String checkDate)
                  throws IPWorksSSLException
The date (format YYMMDD HHMMSS) to check for creation of new groups. If the group was created after the date specified, it is considered new.

The value of this property is used as an argument for the ListNewGroups method.

IPWorksSSLException

setCommand

public void setCommand(java.lang.String command)
                throws IPWorksSSLException
Can be used to send additional commands directly to the server.

Check the LastReply property and/or trap the PITrail events coming from the server to get the response.

IPWorksSSLException

isConnected

public boolean isConnected()
Shows whether the bean is connected.

Use this property to determine whether the bean is connected to the remote host or not.


setConnected

public void setConnected(boolean connected)
                  throws IPWorksSSLException
Shows whether the bean is connected.

Use this property to determine whether the bean is connected to the remote host or not.

IPWorksSSLException

getCurrentArticle

public java.lang.String getCurrentArticle()
The number or message-id of the current article.

The CurrentArticle property specifies either a message id or an article number uniquely identifying a particular article. It is then used as an argument to methods such as FetchArticle .


setCurrentArticle

public void setCurrentArticle(java.lang.String currentArticle)
                       throws IPWorksSSLException
The number or message-id of the current article.

The CurrentArticle property specifies either a message id or an article number uniquely identifying a particular article. It is then used as an argument to methods such as FetchArticle .

IPWorksSSLException

getCurrentGroup

public java.lang.String getCurrentGroup()
The name of the current group.

When the CurrentGroup property is set to a valid group name, the bean sends an NNTP GROUP command to the NewsServer and enters the specified group. If the command is successful, FirstArticle , LastArticle , and ArticleCount are set to the reported values for the group. CurrentGroup is then used for all references to articles (until changed to another group).


setCurrentGroup

public void setCurrentGroup(java.lang.String currentGroup)
                     throws IPWorksSSLException
The name of the current group.

When the CurrentGroup property is set to a valid group name, the bean sends an NNTP GROUP command to the NewsServer and enters the specified group. If the command is successful, FirstArticle , LastArticle , and ArticleCount are set to the reported values for the group. CurrentGroup is then used for all references to articles (until changed to another group).

IPWorksSSLException

getFirewallHost

public java.lang.String getFirewallHost()
Name or IP address of firewall (optional).

If a FirewallHost is given, requested connections will be authenticated through the specified firewall when connecting.

If the FirewallHost property is set to a Domain Name, a DNS request is initiated. Upon successful termination of the request, the FirewallHost property is set to the corresponding address. If the search is not successful, an error is returned.


setFirewallHost

public void setFirewallHost(java.lang.String firewallHost)
                     throws IPWorksSSLException
Name or IP address of firewall (optional).

If a FirewallHost is given, requested connections will be authenticated through the specified firewall when connecting.

If the FirewallHost property is set to a Domain Name, a DNS request is initiated. Upon successful termination of the request, the FirewallHost property is set to the corresponding address. If the search is not successful, an error is returned.

IPWorksSSLException

getFirewallPassword

public java.lang.String getFirewallPassword()
A password if authentication is to be used when connecting through the firewall.

if FirewallHost is specified, the FirewallUser and FirewallPassword properties are used to connect and authenticate to the given firewall. If the authentication fails, a trappable error is fired.


setFirewallPassword

public void setFirewallPassword(java.lang.String firewallPassword)
                         throws IPWorksSSLException
A password if authentication is to be used when connecting through the firewall.

if FirewallHost is specified, the FirewallUser and FirewallPassword properties are used to connect and authenticate to the given firewall. If the authentication fails, a trappable error is fired.

IPWorksSSLException

getFirewallPort

public int getFirewallPort()
Port of the firewall to connect to.

The TCP port for the FirewallHost . See the description of the FirewallHost property for details.

Note that the FirewallPort is set automatically when FirewallType is set to a valid value. See the description of the FirewallType property for details.


setFirewallPort

public void setFirewallPort(int firewallPort)
                     throws IPWorksSSLException
Port of the firewall to connect to.

The TCP port for the FirewallHost . See the description of the FirewallHost property for details.

Note that the FirewallPort is set automatically when FirewallType is set to a valid value. See the description of the FirewallType property for details.

IPWorksSSLException

getFirewallType

public int getFirewallType()
Determines the type of firewall to connect through.

The applicable values are the following:

fwNone (0)
No firewall (default setting).
fwTunnel (1)
Connect through a tunneling proxy. FirewallPort is set to 80.
fwSOCKS4 (2)
Connect through a SOCKS4 Proxy. FirewallPort is set to 1080.
fwSOCKS5 (3)
Connect through a SOCKS5 Proxy. FirewallPort is set to 1080.


setFirewallType

public void setFirewallType(int firewallType)
                     throws IPWorksSSLException
Determines the type of firewall to connect through.

The applicable values are the following:

fwNone (0)
No firewall (default setting).
fwTunnel (1)
Connect through a tunneling proxy. FirewallPort is set to 80.
fwSOCKS4 (2)
Connect through a SOCKS4 Proxy. FirewallPort is set to 1080.
fwSOCKS5 (3)
Connect through a SOCKS5 Proxy. FirewallPort is set to 1080.

IPWorksSSLException

getFirewallUser

public java.lang.String getFirewallUser()
A user name if authentication is to be used connecting through a firewall.

if FirewallHost is specified, the FirewallUser and FirewallPassword properties are used to connect and authenticate to the given firewall. If the authentication fails, a trappable error is fired.


setFirewallUser

public void setFirewallUser(java.lang.String firewallUser)
                     throws IPWorksSSLException
A user name if authentication is to be used connecting through a firewall.

if FirewallHost is specified, the FirewallUser and FirewallPassword properties are used to connect and authenticate to the given firewall. If the authentication fails, a trappable error is fired.

IPWorksSSLException

getFirstArticle

public int getFirstArticle()
The number of the first article in CurrentGroup.

The value of this property is 0 if there is no current group ( CurrentGroup is "").


isIdle

public boolean isIdle()
The current status of the component.

Idle will be False if the component is currently busy (communicating and/or waiting for an answer), and True at all other times.


getLastArticle

public int getLastArticle()
The number of the last article in CurrentGroup .

The value of this property is 0 if there is no current group ( CurrentGroup is "").


getLastReply

public java.lang.String getLastReply()
The last reply from the server.

This is the last reply received from the server. It can be used for information purposes. The same information and more can also be retrieved through the PITrail event.


getLocalHost

public java.lang.String getLocalHost()
The name of the local host or user-assigned IP interface through which connections are initiated or accepted.

The LocalHost property contains the name of the local host as obtained by the gethostname() system call, or if the user has assigned an IP address, the value of that address.

In multihomed hosts (machines with more than one IP interface) setting LocalHost to the value of an interface will make the bean initiate connections (or accept in the case of server beans) only through that interface.

If the bean is connected, the LocalHost property shows the IP address of the interface through which the connection is made in internet dotted format (aaa.bbb.ccc.ddd). In most cases, this is the address of the local host, except for multihomed hosts (machines with more than one IP interface).

NOTE: LocalHost is not persistent. You must always set it in code, and never in the property window.


setLocalHost

public void setLocalHost(java.lang.String localHost)
                  throws IPWorksSSLException
The name of the local host or user-assigned IP interface through which connections are initiated or accepted.

The LocalHost property contains the name of the local host as obtained by the gethostname() system call, or if the user has assigned an IP address, the value of that address.

In multihomed hosts (machines with more than one IP interface) setting LocalHost to the value of an interface will make the bean initiate connections (or accept in the case of server beans) only through that interface.

If the bean is connected, the LocalHost property shows the IP address of the interface through which the connection is made in internet dotted format (aaa.bbb.ccc.ddd). In most cases, this is the address of the local host, except for multihomed hosts (machines with more than one IP interface).

NOTE: LocalHost is not persistent. You must always set it in code, and never in the property window.

IPWorksSSLException

getMaxLines

public int getMaxLines()
The maximum number of message lines besides headers to retrieve.

The MaxLines property is used to limit the number of text lines besides headers retrieved for messages. This property is used in conjunction with the ArticleText property. Please note that due to NNTP protocol limitations, the full text of the article is always retrieved from the server, but only MaxLines will be stored in ArticleText .

The default value of the property is 0. In this case the entire message will be retrieved, without interruptions.


setMaxLines

public void setMaxLines(int maxLines)
                 throws IPWorksSSLException
The maximum number of message lines besides headers to retrieve.

The MaxLines property is used to limit the number of text lines besides headers retrieved for messages. This property is used in conjunction with the ArticleText property. Please note that due to NNTP protocol limitations, the full text of the article is always retrieved from the server, but only MaxLines will be stored in ArticleText .

The default value of the property is 0. In this case the entire message will be retrieved, without interruptions.

IPWorksSSLException

getNewsgroups

public java.lang.String getNewsgroups()
A comma separated list of newsgroups in which to post the article.

The string in Newsgroups is posted with a Newsgroups article header to the news server. It specifies the list of groups where the article is posted (comma separated).

If the Newsgroups property contains "" (empty string), then the value of the CurrentGroup property is used to specify the target newsgroup for the posted article.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setNewsgroups

public void setNewsgroups(java.lang.String newsgroups)
                   throws IPWorksSSLException
A comma separated list of newsgroups in which to post the article.

The string in Newsgroups is posted with a Newsgroups article header to the news server. It specifies the list of groups where the article is posted (comma separated).

If the Newsgroups property contains "" (empty string), then the value of the CurrentGroup property is used to specify the target newsgroup for the posted article.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getNewsPort

public int getNewsPort()
The server port for secure NNTP (default 563).

A valid port number (a value between 1 and 65535) is required for the connection to take place. The property must be set before a connection is attempted and cannot be changed once a connection is established. Any attempt to change this property while connected will fail with an error.


setNewsPort

public void setNewsPort(int newsPort)
                 throws IPWorksSSLException
The server port for secure NNTP (default 563).

A valid port number (a value between 1 and 65535) is required for the connection to take place. The property must be set before a connection is attempted and cannot be changed once a connection is established. Any attempt to change this property while connected will fail with an error.

IPWorksSSLException

getNewsServer

public java.lang.String getNewsServer()
The name or address of a news server.

The NewsServer property specifies the IP address (IP number in dotted internet format) or Domain Name for the news server. It is set before a connection is attempted and cannot be changed once a connection is in progress.

If the NewsServer property is set to a Domain Name, a DNS request is initiated and upon successful termination of the request, the NewsServer property is set to the corresponding address. If the search is not successful, an error is returned.

If the bean is configured to use a SOCKS firewall, the value assigned to this property may be preceded with a "*". If this is the case, the host name is passed to the firewall unresolved and the firewall performs the DNS resolution.


setNewsServer

public void setNewsServer(java.lang.String newsServer)
                   throws IPWorksSSLException
The name or address of a news server.

The NewsServer property specifies the IP address (IP number in dotted internet format) or Domain Name for the news server. It is set before a connection is attempted and cannot be changed once a connection is in progress.

If the NewsServer property is set to a Domain Name, a DNS request is initiated and upon successful termination of the request, the NewsServer property is set to the corresponding address. If the search is not successful, an error is returned.

If the bean is configured to use a SOCKS firewall, the value assigned to this property may be preceded with a "*". If this is the case, the host name is passed to the firewall unresolved and the firewall performs the DNS resolution.

IPWorksSSLException

getOrganization

public java.lang.String getOrganization()
The organization of the author (for posting articles).

If the Organization property contains a non-empty string, an Organization article header is created for the article. This header shows the organization of the author and is used for information purposes only.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.


setOrganization

public void setOrganization(java.lang.String organization)
                     throws IPWorksSSLException
The organization of the author (for posting articles).

If the Organization property contains a non-empty string, an Organization article header is created for the article. This header shows the organization of the author and is used for information purposes only.

If the resulting header is longer thanMaxHeaderLength, then it is folded according to RFC 850 specifications.

IPWorksSSLException

getOtherHeaders

public java.lang.String getOtherHeaders()
An RFC850 compliant string consisting of extra headers (for posting articles).

The OtherHeaders property contains a string of headers to be appended to the message headers created from other properties like From , Subject , etc.

The headers must be of the format "header: value" as specified in RFC 850. [Header lines should be separated by CRLF ("\\r\\n") .

Use this property with caution. If OtherHeaders contains invalid headers, article posting might not be successful.

The OtherHeaders property is useful for extending the functionality of the bean. A good example is posting of MIME attachments.

SPECIAL CASE: if OtherHeaders starts with an empty line (CRLF), then the value of OtherHeaders is used instead of the normally computed article headers.


setOtherHeaders

public void setOtherHeaders(java.lang.String otherHeaders)
                     throws IPWorksSSLException
An RFC850 compliant string consisting of extra headers (for posting articles).

The OtherHeaders property contains a string of headers to be appended to the message headers created from other properties like From , Subject , etc.

The headers must be of the format "header: value" as specified in RFC 850. [Header lines should be separated by CRLF ("\\r\\n") .

Use this property with caution. If OtherHeaders contains invalid headers, article posting might not be successful.

The OtherHeaders property is useful for extending the functionality of the bean. A good example is posting of MIME attachments.

SPECIAL CASE: if OtherHeaders starts with an empty line (CRLF), then the value of OtherHeaders is used instead of the normally computed article headers.

IPWorksSSLException

getOverviewRange

public java.lang.String getOverviewRange()
A range for the GroupOverview method (first-last).

The OverviewRange specifies a range of articles for which to retrieve article overviews from the server. The format is 'first-last' where first is "" (empty string) or a positive number, and last is "" (empty string), a positive number, or the token end .

The default value of the property is '-', meaning 'all articles in the group' .


setOverviewRange

public void setOverviewRange(java.lang.String overviewRange)
                      throws IPWorksSSLException
A range for the GroupOverview method (first-last).

The OverviewRange specifies a range of articles for which to retrieve article overviews from the server. The format is 'first-last' where first is "" (empty string) or a positive number, and last is "" (empty string), a positive number, or the token end .

The default value of the property is '-', meaning 'all articles in the group' .

IPWorksSSLException

getPassword

public java.lang.String getPassword()
A login password to login with in the NewsServer .

If the Password property is set to a non-empty string, then when connecting to the NewsServer an AUTHINFO PASS command is sent in order to provide authentication information for the user. This command is not part of the NNTP protocol, but it is widely used by popular news servers.


setPassword

public void setPassword(java.lang.String password)
                 throws IPWorksSSLException
A login password to login with in the NewsServer .

If the Password property is set to a non-empty string, then when connecting to the NewsServer an AUTHINFO PASS command is sent in order to provide authentication information for the user. This command is not part of the NNTP protocol, but it is widely used by popular news servers.

IPWorksSSLException

getSearchHeader

public java.lang.String getSearchHeader()
A header for the GroupSearch method.

The SearchHeader property specifies the header to search for SearchPattern (e.g. "Subject").


setSearchHeader

public void setSearchHeader(java.lang.String searchHeader)
                     throws IPWorksSSLException
A header for the GroupSearch method.

The SearchHeader property specifies the header to search for SearchPattern (e.g. "Subject").

IPWorksSSLException

getSearchPattern

public java.lang.String getSearchPattern()
A search pattern for the GroupSearch method.

The format of the pattern is the same as the patterns used by the UNIX 'find' command.

As an example, "* new *" will match all headers that contain the word "new".


setSearchPattern

public void setSearchPattern(java.lang.String searchPattern)
                      throws IPWorksSSLException
A search pattern for the GroupSearch method.

The format of the pattern is the same as the patterns used by the UNIX 'find' command.

As an example, "* new *" will match all headers that contain the word "new".

IPWorksSSLException

getSearchRange

public java.lang.String getSearchRange()
A range for the GroupSearch method (first-last).

The SearchRange specifies a range of articles for which to do a search on the server. The format is 'first-last' where first is "" (empty string) or a positive number, and last is "" (empty string), a positive number, or the token end .

The default value of the property is '-', meaning 'search all articles in the group' .


setSearchRange

public void setSearchRange(java.lang.String searchRange)
                    throws IPWorksSSLException
A range for the GroupSearch method (first-last).

The SearchRange specifies a range of articles for which to do a search on the server. The format is 'first-last' where first is "" (empty string) or a positive number, and last is "" (empty string), a positive number, or the token end .

The default value of the property is '-', meaning 'search all articles in the group' .

IPWorksSSLException

getSSLAcceptServerCert

public byte[] getSSLAcceptServerCert()
Instructs the bean to unconditionally accept the server certificate that matches the supplied certificate.

If it finds any issues with the certificate presented by the server, the bean will normally terminate the connection with an error.

You may override this behavior by supplying a value for SSLAcceptServerCert . If the certificate supplied in SSLAcceptServerCert is the same as the certificate presented by the server, then the server certificate is accepted unconditionally, and the connection will continue normally.

Please note that this functionality is provided only for cases where you otherwise know that you are communicating with the right server. If used improperly, these property will create a security breach. Use it at your own risk.


setSSLAcceptServerCert

public void setSSLAcceptServerCert(byte[] SSLAcceptServerCert)
                            throws IPWorksSSLException
Instructs the bean to unconditionally accept the server certificate that matches the supplied certificate.

If it finds any issues with the certificate presented by the server, the bean will normally terminate the connection with an error.

You may override this behavior by supplying a value for SSLAcceptServerCert . If the certificate supplied in SSLAcceptServerCert is the same as the certificate presented by the server, then the server certificate is accepted unconditionally, and the connection will continue normally.

Please note that this functionality is provided only for cases where you otherwise know that you are communicating with the right server. If used improperly, these property will create a security breach. Use it at your own risk.

IPWorksSSLException

getSSLCertEncoded

public byte[] getSSLCertEncoded()
The SSL certificate (PEM/base64 encoded).

This property is used to assign a specific certificate for SSL client authentication (SSL server authentication in the case of the IPDaemonS bean). The SSLCertStore and SSLCertSubject properties may also be used to specify a certificate.

When SSLCertEncoded is set, a search is initiated in the current SSLCertStore for the private key of the certificate. If the key is found, SSLCertSubject is updated to reflect the full subject of the selected certificate, otherwise SSLCertSubject is set to empty string.


setSSLCertEncoded

public void setSSLCertEncoded(byte[] SSLCertEncoded)
                       throws IPWorksSSLException
The SSL certificate (PEM/base64 encoded).

This property is used to assign a specific certificate for SSL client authentication (SSL server authentication in the case of the IPDaemonS bean). The SSLCertStore and SSLCertSubject properties may also be used to specify a certificate.

When SSLCertEncoded is set, a search is initiated in the current SSLCertStore for the private key of the certificate. If the key is found, SSLCertSubject is updated to reflect the full subject of the selected certificate, otherwise SSLCertSubject is set to empty string.

IPWorksSSLException

getSSLCertStore

public byte[] getSSLCertStore()
The name of the certificate store for the client certificate.

The SSLCertStoreType property specifies the type of the certificate store specified by SSLCertStore . If the store is password protected, specify the password in SSLCertStorePassword .

SSLCertStore is used in conjunction with the SSLCertSubject property in order to specify client certificates. If SSLCertStore has a value, and SSLCertSubject or SSLCertEncoded is set, a search for a certificate is initiated. Please refer to the SSLCertSubject property for details.

Designations of certificate stores are platform-dependent.

The following are designations of the most common User and Machine certificate stores in Windows:

MY
A certificate store holding personal certificates with their associated private keys.
CA
Certifying authority certificates.
ROOT
Root certificates.
SPC
Software publisher certificates.

In Java, the certificate store normally is a file containing certificates and optional private keys.

When the certificate store type is PFXFile, this property must be set to the name of the file. When the type is PFXBlob, the property must be set to the binary contents of a PFX file (i.e. PKCS12 certificate store).

If the provider is OpenSSL, the certificate store is a file containing a certificate and a private key. This property must be set to the name of the file.


setSSLCertStore

public void setSSLCertStore(byte[] SSLCertStore)
                     throws IPWorksSSLException
The name of the certificate store for the client certificate.

The SSLCertStoreType property specifies the type of the certificate store specified by SSLCertStore . If the store is password protected, specify the password in SSLCertStorePassword .

SSLCertStore is used in conjunction with the SSLCertSubject property in order to specify client certificates. If SSLCertStore has a value, and SSLCertSubject or SSLCertEncoded is set, a search for a certificate is initiated. Please refer to the SSLCertSubject property for details.

Designations of certificate stores are platform-dependent.

The following are designations of the most common User and Machine certificate stores in Windows:

MY
A certificate store holding personal certificates with their associated private keys.
CA
Certifying authority certificates.
ROOT
Root certificates.
SPC
Software publisher certificates.

In Java, the certificate store normally is a file containing certificates and optional private keys.

When the certificate store type is PFXFile, this property must be set to the name of the file. When the type is PFXBlob, the property must be set to the binary contents of a PFX file (i.e. PKCS12 certificate store).

If the provider is OpenSSL, the certificate store is a file containing a certificate and a private key. This property must be set to the name of the file.

IPWorksSSLException

getSSLCertStorePassword

public java.lang.String getSSLCertStorePassword()
The password for the certificate store (if any).

If the certificate store is of a type that requires a password, the value of this property is used to open the certificate store.


setSSLCertStorePassword

public void setSSLCertStorePassword(java.lang.String SSLCertStorePassword)
                             throws IPWorksSSLException
The password for the certificate store (if any).

If the certificate store is of a type that requires a password, the value of this property is used to open the certificate store.

IPWorksSSLException

getSSLCertStoreType

public int getSSLCertStoreType()
The type of certificate store for the client certificate.

This property can take one of the following values:

0 (sstUser - default)
For Windows, this specifies that the certificate store is a certificate store owned by the current user. For Java, this specifies that the certificate store is the name of a JKS (Java Key Store) file. If the provider is OpenSSL, this specifies that the certificate store is a file that contains PEM encoded certificate and private key.
1 (sstMachine)
The certificate store is a machine store (not available in Java and when provider is OpenSSL).
2 (sstPFXFile)
The certificate store is the name of a PFX (PKCS12) file containing certificates. If the provider is OpenSSL, the file may contain only one certificate and private key.
3 (sstPFXBlob)
The certificate store is a string (binary or base64 encoded) representing a certificate store in PFX (PKCS12) format.This setting is currently not supported when the provider is OpenSSL.

4 (sstPEMKey)
The certificate store is a string or filename that contains a PEM encoded certificate and private key.This store type is currently not supported in Java.


setSSLCertStoreType

public void setSSLCertStoreType(int SSLCertStoreType)
                         throws IPWorksSSLException
The type of certificate store for the client certificate.

This property can take one of the following values:

0 (sstUser - default)
For Windows, this specifies that the certificate store is a certificate store owned by the current user. For Java, this specifies that the certificate store is the name of a JKS (Java Key Store) file. If the provider is OpenSSL, this specifies that the certificate store is a file that contains PEM encoded certificate and private key.
1 (sstMachine)
The certificate store is a machine store (not available in Java and when provider is OpenSSL).
2 (sstPFXFile)
The certificate store is the name of a PFX (PKCS12) file containing certificates. If the provider is OpenSSL, the file may contain only one certificate and private key.
3 (sstPFXBlob)
The certificate store is a string (binary or base64 encoded) representing a certificate store in PFX (PKCS12) format.This setting is currently not supported when the provider is OpenSSL.

4 (sstPEMKey)
The certificate store is a string or filename that contains a PEM encoded certificate and private key.This store type is currently not supported in Java.

IPWorksSSLException

getSSLCertSubject

public java.lang.String getSSLCertSubject()
The subject of the certificate used for client authentication.

When this property is set, a search is performed in the current certificate store certificate with matching subject.

If an exact match is not found, the store is searched for subjects containing the value of the property.

When setting the property to a partial subject, CN= should be omitted. For example, the following code would find the certificate with subject CN=Test Certificate, OU=People, C=US

Example (Searching with partial subject)

 Control.CertSubject = "Test" 

If a match is not found, the property is set to an empty string, and no certificate is selected.

The special value "*" picks a random certificate in the certificate store.

If a matching certificate is found, the SSLCertSubject property is set to the full subject of the matching certificate.


setSSLCertSubject

public void setSSLCertSubject(java.lang.String SSLCertSubject)
                       throws IPWorksSSLException
The subject of the certificate used for client authentication.

When this property is set, a search is performed in the current certificate store certificate with matching subject.

If an exact match is not found, the store is searched for subjects containing the value of the property.

When setting the property to a partial subject, CN= should be omitted. For example, the following code would find the certificate with subject CN=Test Certificate, OU=People, C=US

Example (Searching with partial subject)

 Control.CertSubject = "Test" 

If a match is not found, the property is set to an empty string, and no certificate is selected.

The special value "*" picks a random certificate in the certificate store.

If a matching certificate is found, the SSLCertSubject property is set to the full subject of the matching certificate.

IPWorksSSLException

getSSLServerCert

public byte[] getSSLServerCert()
The server certificate for the last established connection.

SSLServerCert contains the server certificate for the last established connection.

SSLServerCert is reset every time a new connection is attempted.


getSSLServerCertStatus

public java.lang.String getSSLServerCertStatus()
The verification status of the server certificate for the last established connection.

When the verification fails, SSLServerCertStatus contains a string that indicates the reason(s) why, otherwise, it contains the string "OK".

Please note that the value of SSLServerCertStatus must be considered as only a suggestion as to the validity of the certificate. Application software must use its own logic to determine whether to accept the certificate or not, by using the SSLServerCert to access other certificate properties, or other application-specific information.

SSLServerCertStatus is reset an empty string every time a new connection is attempted.


getSSLStartMode

public int getSSLStartMode()
Determines how the bean starts the SSL negotiation.

The SSLStartMode property may have one of the following values:

0 (sslAutomatic - default)
If the remote port is set to the standard plaintext port of the protocol (where applicable), the bean will behave the same as if SSLStartMode is set to sslExplicit . In all other cases, SSL negotiation will be implicit ( sslImplicit ).
1 (sslImplicit)
The SSL negotiation will start immediately after the connection is established.
2 (sslExplicit)
The bean will first connect in plaintext, and then explicitly start SSL negotiation through a protocol command such as STARTTLS.
3 (sslNone)
No SSL negotiation, no SSL security. All communication will be in plaintext mode.


setSSLStartMode

public void setSSLStartMode(int SSLStartMode)
                     throws IPWorksSSLException
Determines how the bean starts the SSL negotiation.

The SSLStartMode property may have one of the following values:

0 (sslAutomatic - default)
If the remote port is set to the standard plaintext port of the protocol (where applicable), the bean will behave the same as if SSLStartMode is set to sslExplicit . In all other cases, SSL negotiation will be implicit ( sslImplicit ).
1 (sslImplicit)
The SSL negotiation will start immediately after the connection is established.
2 (sslExplicit)
The bean will first connect in plaintext, and then explicitly start SSL negotiation through a protocol command such as STARTTLS.
3 (sslNone)
No SSL negotiation, no SSL security. All communication will be in plaintext mode.

IPWorksSSLException

getTimeout

public int getTimeout()
A timeout for the bean.

If the Timeout property is set to 0, all operations will run uninterrupted until successful completion, or an error condition is encountered.

If Timeout is set to a positive value, the bean will wait for the operation to complete before returning control.

The bean will use DoEvents to enter an efficient wait loop during any potential waiting period, making sure that all system events are processed immediately as they arrive. This ensures that the host application does not "freeze" and remains responsive.

If Timeout expires, and the operation is not yet complete, the bean throws an IPWorksException raises an IPWorksException exception .

Please note that by default, all timeouts are inactivity timeouts , i.e. the timeout period is extended by Timeout seconds when data is successfully sent or received.

Optionally, the behavior of the bean may be changed to absolute timeouts , i.e. the bean will wait for a maximum of Timeout seconds since the beginning of the operation, without extending the timeout period during communications.

This behavior is controlled by theAbsoluteTimeoutconfiguration setting.

The default value for the Timeout property is 60 (seconds).


setTimeout

public void setTimeout(int timeout)
                throws IPWorksSSLException
A timeout for the bean.

If the Timeout property is set to 0, all operations will run uninterrupted until successful completion, or an error condition is encountered.

If Timeout is set to a positive value, the bean will wait for the operation to complete before returning control.

The bean will use DoEvents to enter an efficient wait loop during any potential waiting period, making sure that all system events are processed immediately as they arrive. This ensures that the host application does not "freeze" and remains responsive.

If Timeout expires, and the operation is not yet complete, the bean throws an IPWorksException raises an IPWorksException exception .

Please note that by default, all timeouts are inactivity timeouts , i.e. the timeout period is extended by Timeout seconds when data is successfully sent or received.

Optionally, the behavior of the bean may be changed to absolute timeouts , i.e. the bean will wait for a maximum of Timeout seconds since the beginning of the operation, without extending the timeout period during communications.

This behavior is controlled by theAbsoluteTimeoutconfiguration setting.

The default value for the Timeout property is 60 (seconds).

IPWorksSSLException

getUser

public java.lang.String getUser()
A user id to login as in the NewsServer .

If the User property is set to a non-empty string, then when connecting to the NewsServer an AUTHINFO USER command is sent in order to provide authentication information for the user. Although this command is not part of the NNTP protocol, it is widely used by news servers for authentication purposes.


setUser

public void setUser(java.lang.String user)
             throws IPWorksSSLException
A user id to login as in the NewsServer .

If the User property is set to a non-empty string, then when connecting to the NewsServer an AUTHINFO USER command is sent in order to provide authentication information for the user. Although this command is not part of the NNTP protocol, it is widely used by news servers for authentication purposes.

IPWorksSSLException

config

public java.lang.String config(java.lang.String configurationString)
                        throws IPWorksSSLException
Sets or retrieves a beanconfiguration setting.

Config is a generic method available in every bean. It is used to set and retrieveconfiguration settingsfor the bean.

Configuration settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the bean, access to these internal properties is provided through the Config method.

To set a configuration setting named PROPERTY , you must call Config("PROPERTY=VALUE") , where VALUE is the value of the setting expressed as a string. For boolean values, use the strings "True", "False", "0", "1", "Yes", or "No" (case does not matter).

To read (query) the value of a configuration setting, you must call Config("PROPERTY") . The value will be returned as a string.

IPWorksSSLException

connect

public void connect()
             throws IPWorksSSLException
Connect to the news server.

Connect to the news server. If the User and/or Password are set, then corresponding AUTHINFO commands are sent to the NewsServer as well.

IPWorksSSLException

disconnect

public void disconnect()
                throws IPWorksSSLException
Disconnect from the news server.

Disconnect from the NewsServer . First the bean attempts to send a QUIT command, and if that fails, the connection is broken.

IPWorksSSLException

doEvents

public void doEvents()
              throws IPWorksSSLException
Processes events from the internal message queue.

When DoEvents is called, the bean processes any available events. If no events are available, it waits for a preset period of time, and then returns.

IPWorksSSLException

fetchArticle

public void fetchArticle()
                  throws IPWorksSSLException
Get the headers and body of an article specified in CurrentArticle .

Get the headers and body of the article specified in CurrentArticle . The headers are delivered via the Header event, and the article body via the Transfer event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

fetchArticleBody

public void fetchArticleBody()
                      throws IPWorksSSLException
Get only the body of an article specified in CurrentArticle .

Get only the body of the article specified in CurrentArticle . The body via the Transfer event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

fetchArticleHeaders

public void fetchArticleHeaders()
                         throws IPWorksSSLException
Get only the headers of an article specified in CurrentArticle .

Get only the headers of the article specified in CurrentArticle . The headers are delivered via the Header event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

groupOverview

public void groupOverview()
                   throws IPWorksSSLException
Receive an overview for the articles in range OverviewRange in the CurrentGroup .

Receive an overview for the articles in range OverviewRange in the CurrentGroup . The overview data is delivered via the GroupOverview event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

groupSearch

public void groupSearch()
                 throws IPWorksSSLException
Receive an overview for the articles in range OverviewRange in the CurrentGroup .

Searches the current newsgroup for articles in range SearchRange in the CurrentGroup , where SearchHeader matches SearchPattern . The results are delivered via the GroupSearch event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

interrupt

public void interrupt()
               throws IPWorksSSLException
Interrupt the current method.

If there is no method in progress, Interrupt simply returns doing nothing.

IPWorksSSLException

listGroups

public void listGroups()
                throws IPWorksSSLException
List all groups on the server.

Asks the server to list all its newsgroups. Use this method with caution as listing groups may take quite a long over slow links. The group names and other information are returned via the GroupList event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

listNewGroups

public void listNewGroups()
                   throws IPWorksSSLException
List all new groups on the server.

Asks the server to list all the newsgroups created since CheckDate . The group names (if any) and other information are returned via the GroupList event.

If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

localizeDate

public java.lang.String localizeDate(java.lang.String dateTime)
                              throws IPWorksSSLException
Converts a valid RFC 822 message date to local date and time.

This method can be used to convert an RFC 822 date/time string to the corresponding local date and time.

Dates will be returned in the format: "MM/dd/yyyy hh:mm:ss".

IPWorksSSLException

postArticle

public void postArticle()
                 throws IPWorksSSLException
Post the current article and attached file.

Post the current article and attached file (if any). If a connection to the NewsServer doesn't already exist, a new one is created.

IPWorksSSLException

resetHeaders

public void resetHeaders()
                  throws IPWorksSSLException
Reset all of the article headers.

Resets all the article headers to "" (empty string). Use this property before posting a new article, so that headers from the previous article are not carried over to the next one.

IPWorksSSLException

addNntpsEventListener

public void addNntpsEventListener(NntpsEventListener l)
                           throws java.util.TooManyListenersException
java.util.TooManyListenersException

removeNntpsEventListener

public void removeNntpsEventListener(NntpsEventListener l)

IP*Works! SSL V6

Copyright (c) 2004 /n software inc. - All rights reserved.