com.aspose.tasks

Interfaces

Classes

Exceptions

com.aspose.tasks

Class ExtendedAttribute



  • public class ExtendedAttribute
    extends Object

    Represents extended attributes.


    Currently supported all types of Extended attributes reading from MSP Xml 2003/2007 and mpp 2003. For MSP mpp 2007 all Extended attributes reading supported except durations and flags.
    • Method Detail

      • getAttributeDefinition

        public final ExtendedAttributeDefinition getAttributeDefinition()

        Gets sets the attribute definition

        Returns:
        sets the attribute definition
      • setAttributeDefinition

        public final void setAttributeDefinition(ExtendedAttributeDefinition value)

        Sets the attribute definition.

        Parameters:
        value - the attribute definition.
      • getDateValue

        public final Date getDateValue()

        Gets a value for attributes with date types (Date, Start, Finish).

        Returns:
        a value for attributes with date types (Date, Start, Finish).
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or current attribute is not an date attribute.
      • setDateValue

        public final void setDateValue(Date value)

        Sets a value for attributes with date types (Date, Start, Finish).

        Parameters:
        value - a value for attributes with date types (Date, Start, Finish).
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or current attribute is not an date attribute.
      • setDurationValue

        public final void setDurationValue(Duration value)

        Sets value for attributes with 'Duration' type.

        Parameters:
        value - value for attributes with 'Duration' type.
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or CfType of AttributeDefinition is not 'Duration'.
      • getFieldId

        public final String getFieldId()

        Gets the id of a field. Read/write String.

        Returns:
        the id of a field.
      • setFieldId

        public final void setFieldId(String value)

        Sets the id of a field. Read/write String.

        Parameters:
        value - the id of a field.
      • getFlagValue

        public final boolean getFlagValue()

        Gets a value indicating whether a flag is set for an attribute with 'Flag' type.

        Returns:
        a value indicating whether a flag is set for an attribute with 'Flag' type.
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or current attribute is not a flag attribute.
      • setFlagValue

        public final void setFlagValue(boolean value)

        Sets a value indicating whether a flag is set for an attribute with 'Flag' type.

        Parameters:
        value - a value indicating whether a flag is set for an attribute with 'Flag' type.
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or current attribute is not a flag attribute.
      • getNumericValue

        public final BigDecimal getNumericValue()

        Gets a value for attributes with numeric types (Cost, Number).

        Returns:
        a value for attributes with numeric types (Cost, Number).
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or CfType of AttributeDefinition is not 'Cost' or 'Number'.
      • setNumericValue

        public final void setNumericValue(BigDecimal value)

        Sets a value for attributes with numeric types (Cost, Number).

        Parameters:
        value - a value for attributes with numeric types (Cost, Number).
        Throws:
        com.aspose.ms.System.InvalidOperationException - AttributeDefinition(getAttributeDefinition()/setAttributeDefinition(ExtendedAttributeDefinition)) property is not initialized or CfType of AttributeDefinition is not 'Cost' or 'Number'.
      • getValueGuid

        public final String getValueGuid()

        Gets the guid of a lookup value.


        Should not be set directly, instead use ExtendedAttributeDefinition.CreateExtendedAttribute(Value lookupValue) to create an extended attribute with a lookup value.
        Returns:
        the guid of a lookup value.
      • getValueReadOnly

        public final boolean getValueReadOnly()

        Gets a value indicating whether a value of this ExtendedAttribute instance is read-only.

        Value: returns true if a formula or rollup is defined in the ExtendedAttributeDefinition for this object.
        Returns:
        a value indicating whether a value of this ExtendedAttribute instance is read-only.
      • toString

        public String toString()

        Returns short string representation of an extended attribute.

        Overrides:
        toString in class Object
        Returns:
        The string representation of the extended attribute.