Class PropertyDefinition
- java.lang.Object
-
- microsoft.exchange.webservices.data.property.definition.PropertyDefinitionBase
-
- microsoft.exchange.webservices.data.property.definition.ServiceObjectPropertyDefinition
-
- microsoft.exchange.webservices.data.property.definition.PropertyDefinition
-
- Direct Known Subclasses:
ByteArrayPropertyDefinition,ComplexPropertyDefinitionBase,DateTimePropertyDefinition,EffectiveRightsPropertyDefinition,GenericPropertyDefinition,MeetingTimeZonePropertyDefinition,RecurrencePropertyDefinition,ResponseObjectsPropertyDefinition,StringPropertyDefinition,TimeZonePropertyDefinition
public abstract class PropertyDefinition extends ServiceObjectPropertyDefinition
Represents the definition of a folder or item property.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedPropertyDefinition(String xmlElementName, String uri, EnumSet<PropertyDefinitionFlags> flags, ExchangeVersion version)Initializes a new instance.protectedPropertyDefinition(String xmlElementName, String uri, ExchangeVersion version)Initializes a new instance.protectedPropertyDefinition(String xmlElementName, EnumSet<PropertyDefinitionFlags> flags, ExchangeVersion version)Initializes a new instance.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description List<PropertyDefinition>getAssociatedInternalProperties()Gets a list of associated internal property.StringgetName()Gets the name of the property.StringgetPrintableName()Gets the property definition's printable name.ExchangeVersiongetVersion()Gets the minimum Exchange version that supports this property.StringgetXmlElement()Gets the name of the XML element.booleanhasFlag(PropertyDefinitionFlags flag)Determines whether the specified flag is set.booleanhasFlag(PropertyDefinitionFlags flag, ExchangeVersion version)Determines whether the specified flag is set.booleanisNullable()Gets a value indicating whether this property definition is for a nullable type.abstract voidloadPropertyValueFromXml(EwsServiceXmlReader reader, PropertyBag propertyBag)Loads from XML.protected voidregisterAssociatedInternalProperties(List<PropertyDefinition> properties)Registers associated internal property.voidsetName(String name)Sets the name of the property.abstract voidwritePropertyValueToXml(EwsServiceXmlWriter writer, PropertyBag propertyBag, boolean isUpdateOperation)Writes the property value to XML.-
Methods inherited from class microsoft.exchange.webservices.data.property.definition.ServiceObjectPropertyDefinition
getUri, getXmlElementName, writeAttributesToXml
-
Methods inherited from class microsoft.exchange.webservices.data.property.definition.PropertyDefinitionBase
getType, toString, tryLoadFromXml, writeToXml
-
-
-
-
Constructor Detail
-
PropertyDefinition
protected PropertyDefinition(String xmlElementName, String uri, ExchangeVersion version)
Initializes a new instance.- Parameters:
xmlElementName- Name of the XML element.uri- The URI.version- The version.
-
PropertyDefinition
protected PropertyDefinition(String xmlElementName, EnumSet<PropertyDefinitionFlags> flags, ExchangeVersion version)
Initializes a new instance.- Parameters:
xmlElementName- Name of the XML element.flags- The flags.version- The version.
-
PropertyDefinition
protected PropertyDefinition(String xmlElementName, String uri, EnumSet<PropertyDefinitionFlags> flags, ExchangeVersion version)
Initializes a new instance.- Parameters:
xmlElementName- Name of the XML element.uri- The URI.flags- The flags.version- The version.
-
-
Method Detail
-
hasFlag
public boolean hasFlag(PropertyDefinitionFlags flag)
Determines whether the specified flag is set.- Parameters:
flag- The flag.- Returns:
- true if the specified flag is set; otherwise, false.
-
hasFlag
public boolean hasFlag(PropertyDefinitionFlags flag, ExchangeVersion version)
Determines whether the specified flag is set.- Parameters:
flag- The flag.- Returns:
- true if the specified flag is set; otherwise, false.
-
registerAssociatedInternalProperties
protected void registerAssociatedInternalProperties(List<PropertyDefinition> properties)
Registers associated internal property.- Parameters:
properties- The list in which to add the associated property.
-
getAssociatedInternalProperties
public List<PropertyDefinition> getAssociatedInternalProperties()
Gets a list of associated internal property.- Returns:
- A list of PropertyDefinition objects. This is a hack. It is here (currently) solely to help the API register the MeetingTimeZone property definition that is internal.
-
getVersion
public ExchangeVersion getVersion()
Gets the minimum Exchange version that supports this property.- Overrides:
getVersionin classServiceObjectPropertyDefinition- Returns:
- The version.
-
isNullable
public boolean isNullable()
Gets a value indicating whether this property definition is for a nullable type.- Returns:
- always true
-
loadPropertyValueFromXml
public abstract void loadPropertyValueFromXml(EwsServiceXmlReader reader, PropertyBag propertyBag) throws Exception
Loads from XML.- Parameters:
reader- The reader.propertyBag- The property bag.- Throws:
Exception- the exception
-
writePropertyValueToXml
public abstract void writePropertyValueToXml(EwsServiceXmlWriter writer, PropertyBag propertyBag, boolean isUpdateOperation) throws Exception
Writes the property value to XML.- Parameters:
writer- the writerpropertyBag- the property bagisUpdateOperation- indicates whether the context is an update operation- Throws:
Exception- the exception
-
getXmlElement
public String getXmlElement()
Gets the name of the XML element.- Returns:
- The name of the XML element.
-
setName
public void setName(String name)
Sets the name of the property.- Parameters:
name- name of the property
-
getPrintableName
public String getPrintableName()
Gets the property definition's printable name.- Specified by:
getPrintableNamein classPropertyDefinitionBase- Returns:
- The property definition's printable name.
-
-