com.groupdocs.metadata

Interfaces

Classes

Exceptions

com.groupdocs.metadata

Class PropertyValue

  • All Implemented Interfaces:
    com.aspose.ms.System.IEquatable<PropertyValue>


    public final class PropertyValue
    extends Object
    implements com.aspose.ms.System.IEquatable<PropertyValue>

    Represents a property value.

    • Constructor Detail

      • PropertyValue

        public PropertyValue(int value)

        Initializes a new instance of the PropertyValue class with an integer value.

        Parameters:
        value - An Int32 value.
      • PropertyValue

        public PropertyValue(long value)

        Initializes a new instance of the PropertyValue class with a long value.

        Parameters:
        value - An Int64 value.
      • PropertyValue

        public PropertyValue(boolean value)

        Initializes a new instance of the PropertyValue class with a boolean value.

        Parameters:
        value - A Boolean value.
      • PropertyValue

        public PropertyValue(double value)

        Initializes a new instance of the PropertyValue class with a double value.

        Parameters:
        value - A Double value.
      • PropertyValue

        public PropertyValue(String value)

        Initializes a new instance of the PropertyValue class with a string value.

        Parameters:
        value - A String value.
      • PropertyValue

        public PropertyValue(Date value)

        Initializes a new instance of the PropertyValue class with a DateTime value.

        Parameters:
        value - A DateTime value.
      • PropertyValue

        public PropertyValue(String[] values)

        Initializes a new instance of the PropertyValue class with a string array.

        Parameters:
        values - A string array.
      • PropertyValue

        public PropertyValue(byte[] values)

        Initializes a new instance of the PropertyValue class with a byte array.

        Parameters:
        values - A byte array.
    • Method Detail

      • getType

        public final int getType()

        Gets the MetadataPropertyType.

        Returns:
        The type of the property.
      • toInt

        public final Integer toInt()

        Gets the integer value.

        Returns:
        An integer value if the property has the MetadataPropertyType.Integer type; otherwise null.
      • toLong

        public final Long toLong()

        Gets the long value.

        Returns:
        A long value if the property has the MetadataPropertyType.Long type; otherwise null.
      • toBool

        public final Boolean toBool()

        Gets the boolean value.

        Returns:
        A Boolean value if the property has the MetadataPropertyType.Boolean type; otherwise null.
      • toDouble

        public final Double toDouble()

        Gets the double value.

        Returns:
        A Double value if the property has the MetadataPropertyType.Double type; otherwise null.
      • toString

        public String toString()

        Returns a string that represents the property value.

        Overrides:
        toString in class Object
        Returns:
        A string that represents the property value.
      • toDateTime

        public final Date toDateTime()

        Gets the DateTime value.

        Returns:
        A DateTime value if the property has the MetadataPropertyType.DateTime type; otherwise null.
      • toStringArray

        public final String[] toStringArray()

        Gets the String array.

        Returns:
        A string array if the property has the MetadataPropertyType.StringArray type; otherwise null.
      • toByteArray

        public final byte[] toByteArray()

        Gets the array of byte values.

        Returns:
        An array of bytes if the property has the MetadataPropertyType.ByteArray type; otherwise null.
      • toDoubleArray

        public final double[] toDoubleArray()

        Gets the array of double values.

        Returns:
        An array of doubles if the property has the MetadataPropertyType.DoubleArray type; otherwise null.
      • toIntegerArray

        public final int[] toIntegerArray()

        Gets the array of int values.

        Returns:
        An array of integers if the property has the MetadataPropertyType.IntegerArray type; otherwise null.
      • toLongArray

        public final long[] toLongArray()

        Gets the array of long values.

        Returns:
        An array of longs if the property has the MetadataPropertyType.IntegerArray type; otherwise null.
      • toMetadataArray

        public final Metadata[] toMetadataArray()

        Gets the array of Metadata values.

        Returns:
        An array of Metadata values if the property has the MetadataPropertyType.MetadataArray type; otherwise null.
      • toMetadata

        public final Metadata toMetadata()

        Gets the Metadata value.

        Returns:
        A Metadata value if the property has the MetadataPropertyType.Metadata type; otherwise null.
      • equals

        @Deprecated
        public final boolean equals(PropertyValue other,
                                boolean ignoreCase)
        Deprecated. 

        Indicates whether the current object is equal to another object of the same type.

        Parameters:
        other - An object to compare with this object.
        ignoreCase - If set to true then ignore case.
        Returns:
        true if the current object is equal to the other parameter; otherwise, false.
      • equals

        public final boolean equals(PropertyValue other)

        Indicates whether the current object is equal to another object of the same type.

        Parameters:
        other - An object to compare with this object.
        Returns:
        true if the current object is equal to the other parameter; otherwise, false.
      • equals

        public boolean equals(Object obj)

        Indicates whether the current object is equal to another object of the same type.

        Specified by:
        equals in interface com.aspose.ms.System.IEquatable<PropertyValue>
        Overrides:
        equals in class Object
        Parameters:
        obj - An object to compare with this object.
        Returns:
        true if the current object is equal to the obj parameter; otherwise, false.
      • hashCode

        public int hashCode()

        Returns a hash code for this instance.

        Overrides:
        hashCode in class Object
        Returns:
        A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.