Package org.apache.jackrabbit.value
Class StringValue
- java.lang.Object
-
- org.apache.jackrabbit.value.BaseValue
-
- org.apache.jackrabbit.value.StringValue
-
-
Field Summary
Fields Modifier and Type Field Description static int
TYPE
-
Fields inherited from class org.apache.jackrabbit.value.BaseValue
DEFAULT_ENCODING, stream, type
-
-
Constructor Summary
Constructors Constructor Description StringValue(String text)
Constructs aStringValue
object representing a string.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
Indicates whether some other object is "equal to" this one.protected String
getInternalString()
Returns the internal string representation of this value without modifying the value state.int
hashCode()
Returns zero to satisfy the Object equals/hashCode contract.-
Methods inherited from class org.apache.jackrabbit.value.BaseValue
getBinary, getBoolean, getDate, getDecimal, getDouble, getLong, getStream, getString, getType
-
-
-
-
Field Detail
-
TYPE
public static final int TYPE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
StringValue
public StringValue(String text)
Constructs aStringValue
object representing a string.- Parameters:
text
- the string thisStringValue
should represent
-
-
Method Detail
-
equals
public boolean equals(Object obj)
Indicates whether some other object is "equal to" this one.The result is
true
if and only if the argument is notnull
and is aStringValue
object that represents the same value as this object.
-
hashCode
public int hashCode()
Returns zero to satisfy the Object equals/hashCode contract. This class is mutable and not meant to be used as a hash key.- Overrides:
hashCode
in classObject
- Returns:
- always zero
- See Also:
Object.hashCode()
-
getInternalString
protected String getInternalString() throws ValueFormatException
Returns the internal string representation of this value without modifying the value state.- Specified by:
getInternalString
in classBaseValue
- Returns:
- the internal string representation
- Throws:
ValueFormatException
- if the value can not be represented as aString
or if the value isnull
.
-
-