org.apache.jackrabbit.spi.commons.value
Class QValueFactoryImpl

java.lang.Object
  extended by org.apache.jackrabbit.spi.commons.value.AbstractQValueFactory
      extended by org.apache.jackrabbit.spi.commons.value.QValueFactoryImpl
All Implemented Interfaces:
QValueFactory

public class QValueFactoryImpl
extends AbstractQValueFactory

QValueFactoryImpl...


Field Summary
 
Fields inherited from class org.apache.jackrabbit.spi.commons.value.AbstractQValueFactory
DEFAULT_ENCODING, NAME_FACTORY, PATH_FACTORY
 
Constructor Summary
protected QValueFactoryImpl()
           
 
Method Summary
 QValue create(byte[] value)
          Create a new QValue with type PropertyType.BINARY.
 QValue create(File value)
          Create a new QValue with type PropertyType.BINARY.
 QValue create(InputStream value)
          Creates a QValue that contains the given binary stream.
static QValueFactory getInstance()
           
 
Methods inherited from class org.apache.jackrabbit.spi.commons.value.AbstractQValueFactory
computeAutoValues, create, create, create, create, create, create, create, create, create, createReference, createString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QValueFactoryImpl

protected QValueFactoryImpl()
Method Detail

getInstance

public static QValueFactory getInstance()

create

public QValue create(byte[] value)
Description copied from interface: QValueFactory
Create a new QValue with type PropertyType.BINARY.

Returns:
a new QValue.
See Also:
QValueFactory.create(byte[])

create

public QValue create(InputStream value)
              throws IOException
Description copied from interface: QValueFactory
Creates a QValue that contains the given binary stream. The given stream is consumed and closed by this method. The type of the resulting QValue will be PropertyType.BINARY.

Parameters:
value - binary stream
Returns:
a new binary QValue.
Throws:
IOException - if the stream can not be consumed
See Also:
QValueFactory.create(InputStream)

create

public QValue create(File value)
              throws IOException
Description copied from interface: QValueFactory
Create a new QValue with type PropertyType.BINARY.

Returns:
a new binary QValue.
Throws:
IOException
See Also:
QValueFactory.create(File)


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.