Class Mailbox
- java.lang.Object
-
- microsoft.exchange.webservices.data.property.complex.ComplexProperty
-
- microsoft.exchange.webservices.data.property.complex.Mailbox
-
- All Implemented Interfaces:
ISelfValidate,ComplexFunctionDelegate<EwsServiceXmlReader>,ISearchStringProvider
public class Mailbox extends ComplexProperty implements ISearchStringProvider
Represents a mailbox reference.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)Determines whether the specified Object is equal to the current Object.StringgetAddress()Gets the address.static MailboxgetMailboxFromString(String smtpAddress)Defines an implicit conversion between a string representing an SMTP address and Mailbox.StringgetRoutingType()Gets the routing type of the address used to refer to the user mailbox.StringgetSearchString()Get a string representation for using this instance in a search filter.inthashCode()Serves as a hash function for a particular type.protected voidinternalValidate()Validates this instance.booleanisValid()True if this instance is valid, false otherthise.voidsetAddress(String address)Sets the address.voidsetRoutingType(String routingType)Sets the routing type.StringtoString()Returns a String that represents the current Object.booleantryReadElementFromXml(EwsServiceXmlReader reader)Tries to read element from XML.voidwriteElementsToXml(EwsServiceXmlWriter writer)Writes elements to XML.-
Methods inherited from class microsoft.exchange.webservices.data.property.complex.ComplexProperty
addOnChangeEvent, canSetFieldValue, changed, clearChangeEvents, clearChangeLog, func, getNamespace, loadFromXml, loadFromXml, readAttributesFromXml, readTextValueFromXml, removeChangeEvent, setNamespace, tryReadElementFromXmlToPatch, updateFromXml, updateFromXml, validate, writeAttributesToXml, writeToXml, writeToXml
-
-
-
-
Method Detail
-
getAddress
public String getAddress()
Gets the address.- Returns:
- the address
-
setAddress
public void setAddress(String address)
Sets the address.- Parameters:
address- the new address
-
isValid
public boolean isValid()
True if this instance is valid, false otherthise.- Returns:
- true if this instance is valid; otherwise false
-
getRoutingType
public String getRoutingType()
Gets the routing type of the address used to refer to the user mailbox.- Returns:
- the routing type
-
setRoutingType
public void setRoutingType(String routingType)
Sets the routing type.- Parameters:
routingType- the new routing type
-
getMailboxFromString
public static Mailbox getMailboxFromString(String smtpAddress)
Defines an implicit conversion between a string representing an SMTP address and Mailbox.- Parameters:
smtpAddress- the smtp address- Returns:
- A Mailbox initialized with the specified SMTP address.
-
tryReadElementFromXml
public boolean tryReadElementFromXml(EwsServiceXmlReader reader) throws Exception
Tries to read element from XML.- Overrides:
tryReadElementFromXmlin classComplexProperty- Parameters:
reader- the reader- Returns:
- True if element was read.
- Throws:
Exception- the exception
-
writeElementsToXml
public void writeElementsToXml(EwsServiceXmlWriter writer) throws XMLStreamException, ServiceXmlSerializationException
Writes elements to XML.- Overrides:
writeElementsToXmlin classComplexProperty- Parameters:
writer- the writer- Throws:
XMLStreamException- the XML stream exceptionServiceXmlSerializationException- the service xml serialization exception
-
getSearchString
public String getSearchString()
Get a string representation for using this instance in a search filter.- Specified by:
getSearchStringin interfaceISearchStringProvider- Returns:
- String representation of instance.
-
internalValidate
protected void internalValidate() throws ServiceValidationException, Exception
Validates this instance.- Overrides:
internalValidatein classComplexProperty- Throws:
ExceptionServiceValidationException
-
equals
public boolean equals(Object obj)
Determines whether the specified Object is equal to the current Object.
-
hashCode
public int hashCode()
Serves as a hash function for a particular type.
-
-