All Packages Class Hierarchy This Package Previous Next Index
Class COM.ibm.beans.net.INetProtocolHdrParser
java.lang.Object
|
+----COM.ibm.beans.net.INetProtocolHdrParser
- public class INetProtocolHdrParser
- extends Object
A parser for the Net clients that parses the header and body fields of the
header of an NetProtocol reply.
Copyright (c) Taligent, Inc. 1996 - 1997.
Copyright (c) IBM Corporation 1996 - 1997.
All Rights Reserved.
-
INetProtocolHdrParser()
-
-
isNewSubject(String)
- Return true if this subject line indicates that the article refers
to a new topic, false if it is a response to an existing topic.
-
parseAuthor(String)
- Parse the Author's name and address from the article's "From:" header line
The From: line in the header can be in 4 possible formats (3 as per RFC-850,
and one more that seems to be common)
Return both, the name and the address of the author in a Vector.
-
parseAuthorAddress(String)
- Parse the Author's Electronic address from the article's "From:" header line
This method uses parseAuthor() to parse out both parts of the
author, and returns the author name only.
-
parseAuthorName(String)
- Parse the Author's Name from the article's "From:" header line
This method uses parseAuthor() to parse out both parts of the
author, and returns the author name only.
-
parseDate(String)
- TODO: This and the next are temporarily used functions, and
will be removed.
-
parseFirstReference(String)
- Parse the referenced articles' identification from the
article's "References: " header line, and return the first
reference, if any.
-
parseNextReference(String, int)
- Parse the referenced articles' identification from the
article's "References: " header line, and return the reference
specified by index, if any.
-
parseOrganization(String)
- Parse the Organization of the article's "Organization:" header line
-
parseSubject(String)
- Parse the Subject of the article's "Subject:" header line
The Subject line in the header can be either a new subject, or
a response to an existing article's subject.
INetProtocolHdrParser
public INetProtocolHdrParser()
parseAuthorName
public static String parseAuthorName(String fromLine)
- Parse the Author's Name from the article's "From:" header line
This method uses parseAuthor() to parse out both parts of the
author, and returns the author name only.
parseAuthorAddress
public static String parseAuthorAddress(String fromLine)
- Parse the Author's Electronic address from the article's "From:" header line
This method uses parseAuthor() to parse out both parts of the
author, and returns the author name only.
parseAuthor
public static Vector parseAuthor(String fromLine)
- Parse the Author's name and address from the article's "From:" header line
The From: line in the header can be in 4 possible formats (3 as per RFC-850,
and one more that seems to be common)
Return both, the name and the address of the author in a Vector.
1. From: pratima@taligent.com
2. From: pratima@taligent.com (Pratima Gupta)
3. From: Pratima Gupta
4. From: "Pratima Gupta"
5. From: "PratimaGupta"
- Parameters:
- fromLine - the "From:" line in the article's header
parseSubject
public static String parseSubject(String subjectLine)
- Parse the Subject of the article's "Subject:" header line
The Subject line in the header can be either a new subject, or
a response to an existing article's subject. In the latter case,
the Subject text will begin with the string "Re:".
- Parameters:
- subjectLine - the "Subject:" line in the article's header
isNewSubject
public static boolean isNewSubject(String subjectLine)
- Return true if this subject line indicates that the article refers
to a new topic, false if it is a response to an existing topic.
The Subject line in the header can be either a new subject, or
a response to an existing article's subject. In the latter case,
the Subject text will begin with the string "Re:".
- Parameters:
- subjectLine - the "Subject:" line in the article's header
parseOrganization
public static String parseOrganization(String orgLine)
- Parse the Organization of the article's "Organization:" header line
- Parameters:
- orgLine - the "Organization:" line in the article's header
parseDate
public static String parseDate(String dateLine)
- TODO: This and the next are temporarily used functions, and
will be removed.
It parses the Date line of the header and converts it to
a format understood by DB2.
Parse the Date from the article's "Date:" header line
and return it in the form: YYYY-MM-DD-HH.MM.SS
The Date line in the header can be in either of 2 formats:
1. 29 Apr 97 03:30:38 GMT
2. Tue,29 Apr 97 03:30:38 GMT
- Parameters:
- dateLine - the "Date:" line in the article's header
parseFirstReference
public String parseFirstReference(String refLine)
- Parse the referenced articles' identification from the
article's "References: " header line, and return the first
reference, if any.
The identification of each of the referenced articles is in
the form : <5l12ra$o28$1@news01a.micron.net>
There may be zero or more such references in any article's
header.
- Parameters:
- refLine - the "References:" line in the article's header
parseNextReference
public String parseNextReference(String refLine,
int refAt)
- Parse the referenced articles' identification from the
article's "References: " header line, and return the reference
specified by index, if any.
The identification of each of the referenced articles is in
the form : <5l12ra$o28$1@news01a.micron.net>
There may be zero or more such references in any article's
header.
- Parameters:
- refLine - the "References:" line in the article's header
All Packages Class Hierarchy This Package Previous Next Index