|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
javax.mail Class Address
java.lang.Object javax.mail.Address
- All Implemented Interfaces:
- Serializable
- Direct Known Subclasses:
- InternetAddress, NewsAddress
public abstract class Address
- extends Object
- implements Serializable
Implements:
java.io.Serializable
Extended by:
InternetAddress, NewsAddress
此抽象类模拟消息中的地址。子类提供特定实现。子类通常将是可序列化的,这样,(例如)搜索项中的 Address 对象的使用可以随搜索项一起被序列化。
This abstract class models the addresses in a message. Subclasses provide specific implementations. Subclasses will typically be serializable so that (for example) the use of Address objects in search terms can be serialized along with the search terms.
- Author:
- John Mani, Bill Shannon
- See Also:
- Serialized Form
Constructor Summary | |
---|---|
Address()
|
Method Summary | |
---|---|
abstract boolean |
equals(Object address)
The equality operator. |
abstract String |
getType()
Return a type string that identifies this address type. |
abstract String |
toString()
Return a String representation of this address object. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public
Address()
英文文档:
Address
public Address()
Method Detail |
---|
abstract public String
getType()
返回标识此地址类型的类型字符串。
return | 地址类型 |
See also | javax.mail.internet.InternetAddress |
getType
public abstract String getType()
- Return a type string that identifies this address type.
- Returns:
- address type
- See Also:
InternetAddress
abstract public String
toString()
返回此 Address 对象的 String 表示形式。
return | 此地址的字符串表示形式 |
toString
public abstract String toString()
- Return a String representation of this address object.
- Returns:
- string representation of this address
abstract public boolean
equals(Object address)
等号运算符。子类应该提供此方法的实现,该方法支持值相等性(这两个 Address 对象表示相同的目标吗?),而不支持对象引用相等性。子类还必须提供相应的 hashCode
方法的实现,该方法保留 equals
和 hashCode
的常规协定 - 比较起来相等的对象必须具有相同的 hashCode。
address | Address 对象 |
equals
public abstract boolean equals(Object address)
- The equality operator. Subclasses should provide an
implementation of this method that supports value equality
(do the two Address objects represent the same destination?),
not object reference equality. A subclass must also provide
a corresponding implementation of the
hashCode
method that preserves the general contract ofequals
andhashCode
- objects that compare as equal must have the same hashCode. - Parameters:
address
- Address object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Submit a bug or feature
Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.
PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!