microsoft.exchange.webservices.data
Class ExtendedPropertyDefinition

java.lang.Object
  extended by microsoft.exchange.webservices.data.PropertyDefinitionBase
      extended by microsoft.exchange.webservices.data.ExtendedPropertyDefinition

public final class ExtendedPropertyDefinition
extends PropertyDefinitionBase

Represents the definition of an extended property.


Constructor Summary
protected ExtendedPropertyDefinition()
          * Initializes a new instance.
  ExtendedPropertyDefinition(DefaultExtendedPropertySet propertySet, int id, MapiPropertyType mapiType)
          * Initializes a new instance.
  ExtendedPropertyDefinition(DefaultExtendedPropertySet propertySet, java.lang.String name, MapiPropertyType mapiType)
          * Initializes a new instance.
  ExtendedPropertyDefinition(int tag, MapiPropertyType mapiType)
          * Initializes a new instance.
protected ExtendedPropertyDefinition(MapiPropertyType mapiType)
          * Initializes a new instance.
  ExtendedPropertyDefinition(java.util.UUID propertySetId, int id, MapiPropertyType mapiType)
          * Initializes a new instance.
  ExtendedPropertyDefinition(java.util.UUID propertySetId, java.lang.String name, MapiPropertyType mapiType)
          * Initializes a new instance.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Determines whether two specified instances of ExtendedPropertyDefinition are equal.
protected
<T> java.lang.String
formatField(java.lang.String name, T fieldValue)
          * Formats the field.
 java.lang.Integer getId()
          Gets the Id of the extended property.
 MapiPropertyType getMapiType()
          Gets the MAPI type of the extended property.
 java.lang.String getName()
          Gets the name of the extended property.
protected  java.lang.String getPrintableName()
          Gets the property definition's printable name.
 DefaultExtendedPropertySet getPropertySet()
          Gets the property set of the extended property.
 java.util.UUID getPropertySetId()
          Gets the property set Id or the extended property.
 java.lang.Integer getTag()
          Gets the extended property's tag.
 java.lang.Class getType()
          Gets the property type.
 ExchangeVersion getVersion()
          Gets the minimum Exchange version that supports this extended property.
protected  java.lang.String getXmlElementName()
          Gets the name of the XML element.
 int hashCode()
           
protected static boolean isEqualTo(ExtendedPropertyDefinition extPropDef1, ExtendedPropertyDefinition extPropDef2)
          Determines whether two specified instances of ExtendedPropertyDefinition are equal.
protected  void loadFromXml(microsoft.exchange.webservices.data.EwsServiceXmlReader reader)
          * Loads from XML.
protected  void writeAttributesToXml(microsoft.exchange.webservices.data.EwsServiceXmlWriter writer)
          * Writes the attributes to XML.
 
Methods inherited from class microsoft.exchange.webservices.data.PropertyDefinitionBase
toString, tryLoadFromXml, writeToXml
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ExtendedPropertyDefinition

protected ExtendedPropertyDefinition()
* Initializes a new instance.


ExtendedPropertyDefinition

protected ExtendedPropertyDefinition(MapiPropertyType mapiType)
* Initializes a new instance.

Parameters:
mapiType - The MAPI type of the extended property.

ExtendedPropertyDefinition

public ExtendedPropertyDefinition(int tag,
                                  MapiPropertyType mapiType)
* Initializes a new instance.

Parameters:
tag - The tag of the extended property.
mapiType - The MAPI type of the extended property.

ExtendedPropertyDefinition

public ExtendedPropertyDefinition(DefaultExtendedPropertySet propertySet,
                                  java.lang.String name,
                                  MapiPropertyType mapiType)
                           throws java.lang.Exception
* Initializes a new instance.

Parameters:
propertySet - The extended property set of the extended property.
name - The name of the extended property.
mapiType - The MAPI type of the extended property.
Throws:
java.lang.Exception - the exception

ExtendedPropertyDefinition

public ExtendedPropertyDefinition(DefaultExtendedPropertySet propertySet,
                                  int id,
                                  MapiPropertyType mapiType)
* Initializes a new instance.

Parameters:
propertySet - The property set of the extended property.
id - The Id of the extended property.
mapiType - The MAPI type of the extended property.

ExtendedPropertyDefinition

public ExtendedPropertyDefinition(java.util.UUID propertySetId,
                                  java.lang.String name,
                                  MapiPropertyType mapiType)
                           throws java.lang.Exception
* Initializes a new instance.

Parameters:
propertySetId - The property set Id of the extended property.
name - The name of the extended property.
mapiType - The MAPI type of the extended property.
Throws:
java.lang.Exception - the exception

ExtendedPropertyDefinition

public ExtendedPropertyDefinition(java.util.UUID propertySetId,
                                  int id,
                                  MapiPropertyType mapiType)
* Initializes a new instance.

Parameters:
propertySetId - The property set Id of the extended property.
id - The Id of the extended property.
mapiType - The MAPI type of the extended property.
Method Detail

isEqualTo

protected static boolean isEqualTo(ExtendedPropertyDefinition extPropDef1,
                                   ExtendedPropertyDefinition extPropDef2)
Determines whether two specified instances of ExtendedPropertyDefinition are equal.

Parameters:
extPropDef1 - First extended property definition.
extPropDef2 - Second extended property definition.
Returns:
True if extended property definitions are equal.

getXmlElementName

protected java.lang.String getXmlElementName()
Gets the name of the XML element.

Specified by:
getXmlElementName in class PropertyDefinitionBase
Returns:
XML element name.

getVersion

public ExchangeVersion getVersion()
Gets the minimum Exchange version that supports this extended property.

Specified by:
getVersion in class PropertyDefinitionBase
Returns:
The version.

writeAttributesToXml

protected void writeAttributesToXml(microsoft.exchange.webservices.data.EwsServiceXmlWriter writer)
                             throws ServiceXmlSerializationException
* Writes the attributes to XML.

Specified by:
writeAttributesToXml in class PropertyDefinitionBase
Parameters:
writer - The writer.
Throws:
ServiceXmlSerializationException - the service xml serialization exception

loadFromXml

protected void loadFromXml(microsoft.exchange.webservices.data.EwsServiceXmlReader reader)
                    throws java.lang.Exception
* Loads from XML.

Parameters:
reader - The reader.
Throws:
java.lang.Exception - the exception

equals

public boolean equals(java.lang.Object obj)
Determines whether two specified instances of ExtendedPropertyDefinition are equal.

Overrides:
equals in class java.lang.Object
Parameters:
obj - the obj
Returns:
True if extended property definitions are equal.

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

getPrintableName

protected java.lang.String getPrintableName()
Gets the property definition's printable name.

Specified by:
getPrintableName in class PropertyDefinitionBase
Returns:
The property definition's printable name.

formatField

protected <T> java.lang.String formatField(java.lang.String name,
                                           T fieldValue)
* Formats the field.

Type Parameters:
T - Type of the field.
Parameters:
name - The name.
fieldValue - The field value.
Returns:
the string

getPropertySet

public DefaultExtendedPropertySet getPropertySet()
Gets the property set of the extended property.

Returns:
property set of the extended property.

getPropertySetId

public java.util.UUID getPropertySetId()
Gets the property set Id or the extended property.

Returns:
property set Id or the extended property.

getTag

public java.lang.Integer getTag()
Gets the extended property's tag.

Returns:
The extended property's tag.

getName

public java.lang.String getName()
Gets the name of the extended property.

Returns:
The name of the extended property.

getId

public java.lang.Integer getId()
Gets the Id of the extended property.

Returns:
The Id of the extended property.

getMapiType

public MapiPropertyType getMapiType()
Gets the MAPI type of the extended property.

Returns:
The MAPI type of the extended property.

getType

public java.lang.Class getType()
Gets the property type.

Specified by:
getType in class PropertyDefinitionBase