Package org.apache.jackrabbit.spi
Interface QValue
-
- All Known Implementing Classes:
AbstractQValue,DefaultQValue,InternalValue
public interface QValueQValueis the SPI representation of ajcr value. It therefore refers toNames andPaths only and is thus isolated from session-specific namespace mappings.
-
-
Field Summary
Fields Modifier and Type Field Description static QValue[]EMPTY_ARRAY
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voiddiscard()Frees temporarily allocated resources such as temporary file, buffer, etc.BinarygetBinary()Returns aBinaryrepresentation of thisQValueobject.booleangetBoolean()Returns abooleanrepresentation of this value.CalendargetCalendar()Returns aCalendarrepresentation of this value.BigDecimalgetDecimal()Returns aBigDecimalrepresentation of this value.doublegetDouble()Returns adoublerepresentation of this value.longgetLength()Returns the length of the internal value or -1 if the implementation cannot determine the length at this time.
NOTE: forPropertyType.NAMEandPropertyType.PATHthe length of the internal value must not be used for indicating the length of a property such as retrieved by callingProperty.getLength()andProperty.getLengths().longgetLong()Returns alongrepresentation of this value.NamegetName()Returns aNamerepresentation of this value.PathgetPath()Returns aPathrepresentation of this value.InputStreamgetStream()Returns anInputStreamrepresentation of thisQValueobject.StringgetString()Returns aStringrepresentation of thisQValueobject.intgetType()Returns thePropertyTypeof thisQValueobject.URIgetURI()Returns anURIrepresentation of this value.
-
-
-
Field Detail
-
EMPTY_ARRAY
static final QValue[] EMPTY_ARRAY
-
-
Method Detail
-
getType
int getType()
Returns thePropertyTypeof thisQValueobject. It may be either of the value property types defined by the JSR 283:- Returns:
- the
PropertyTypeof thisQValueobject.
-
getLength
long getLength() throws RepositoryExceptionReturns the length of the internal value or -1 if the implementation cannot determine the length at this time.
NOTE: forPropertyType.NAMEandPropertyType.PATHthe length of the internal value must not be used for indicating the length of a property such as retrieved by callingProperty.getLength()andProperty.getLengths().- Returns:
- length of this
QValueobject. - Throws:
RepositoryException
-
getString
String getString() throws RepositoryException
Returns aStringrepresentation of thisQValueobject.- Returns:
- A
Stringrepresentation of thisQValueobject. - Throws:
RepositoryException
-
getStream
InputStream getStream() throws RepositoryException
Returns anInputStreamrepresentation of thisQValueobject. This method always returns a new stream.- Returns:
- A stream representation of this value.
- Throws:
RepositoryException
-
getBinary
Binary getBinary() throws RepositoryException
Returns aBinaryrepresentation of thisQValueobject.- Returns:
- A
Binaryrepresentation of this value. - Throws:
RepositoryException
-
getCalendar
Calendar getCalendar() throws RepositoryException
Returns aCalendarrepresentation of this value.- Returns:
- A
Calendarrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getDecimal
BigDecimal getDecimal() throws RepositoryException
Returns aBigDecimalrepresentation of this value.- Returns:
- A
BigDecimalrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getDouble
double getDouble() throws RepositoryExceptionReturns adoublerepresentation of this value.- Returns:
- A
doublerepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getLong
long getLong() throws RepositoryExceptionReturns alongrepresentation of this value.- Returns:
- A
longrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getBoolean
boolean getBoolean() throws RepositoryExceptionReturns abooleanrepresentation of this value.- Returns:
- A
booleanrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getName
Name getName() throws RepositoryException
Returns aNamerepresentation of this value.- Returns:
- A
Namerepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getPath
Path getPath() throws RepositoryException
Returns aPathrepresentation of this value.- Returns:
- A
Pathrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
getURI
URI getURI() throws RepositoryException
Returns anURIrepresentation of this value.- Returns:
- A
URIrepresentation of this value. - Throws:
RepositoryException- if an error occurs.
-
discard
void discard()
Frees temporarily allocated resources such as temporary file, buffer, etc.
-
-