Name

NewsAddress

Synopsis

This class models an NNTP URL, such as news://newserver/news.group.name.

                  
public class NewsAddress extends Address {
// Public Constructors
   public NewsAddress();  
   public NewsAddress( String newsgroup);  
   public NewsAddress( String newsgroup, String host);  
// Public Class Methods
   public static NewsAddress[] parse(
        String newsgroups) throws AddressException;  
   public static String toString(
        Address[] addresses);  
// Public Instance Methods
   public String getHost();                                      // default:null
   public String getNewsgroup();                                 // default:null
   public void setHost( String host);  
   public void setNewsgroup( String newsgroup);  
// Public Methods Overriding Address
   public boolean equals( Object a);  
   public String getType();                                      // default:"news”
   public String toString();  
// Public Methods Overriding Object
   public int hashCode();  
// Protected Instance Fields
   protected String host;  
   protected String newsgroup;  
}

Returned By

NewsAddress.parse()

Get Java Enterprise in a Nutshell, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.