Skip navigation links

Oracle Fusion Middleware interMedia Domains Java API Reference for Oracle ADF Business Components
11g Release 2 (11.1.2.3.0)

E17485-04


oracle.ord.im
Class OrdByteArraySource

java.lang.Object
  extended by oracle.ord.im.OrdByteArraySource

All Implemented Interfaces:
OrdContentSource

public class OrdByteArraySource
extends java.lang.Object
implements OrdContentSource

An implementation class of OrdContentSource to support using a byte array as the content source for deferred loading.


Constructor Summary
OrdByteArraySource(byte[] bytes)
          Constructs an OrdByteArraySource instance.

 

Method Summary
 byte[] getByteArray()
          Gets a byte array containing the content to be loaded.
 int getContentLength()
          Gets the length of the content.
 java.io.InputStream getInputStream()
          Gets an InputStream object from the byte array.
 java.lang.String getMimeType()
          Gets the MIME type information for the content.
 void release()
          Releases the resources used by the content source.
 void setByteArray(byte[] bytes)
          Sets a byte array containing the content to be loaded.
 void setMimeType(java.lang.String mimeType)
          Sets the MIME type information for the content.

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

OrdByteArraySource

public OrdByteArraySource(byte[] bytes)
Constructs an OrdByteArraySource instance.
Parameters:
bytes - a byte array containing the content to be loaded

Method Detail

setByteArray

public void setByteArray(byte[] bytes)
Sets a byte array containing the content to be loaded.
Parameters:
bytes - a byte array containing the content to be loaded

getByteArray

public byte[] getByteArray()
Gets a byte array containing the content to be loaded.
Returns:
a byte array containing the content to be loaded

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Gets an InputStream object from the byte array.
Specified by:
getInputStream in interface OrdContentSource
Returns:
a ByteArrayInputStream object
Throws:
java.io.IOException

getContentLength

public int getContentLength()
                     throws java.io.IOException
Gets the length of the content. The length is the size of the byte array.
Specified by:
getContentLength in interface OrdContentSource
Returns:
the length of the content.
Throws:
java.io.IOException

setMimeType

public void setMimeType(java.lang.String mimeType)
Sets the MIME type information for the content.
Parameters:
mimeType - the MIME type information

getMimeType

public java.lang.String getMimeType()
Gets the MIME type information for the content. Returns null if this information was not set by a previous setMimeType(String) call.
Specified by:
getMimeType in interface OrdContentSource
Returns:
the MIME type information

release

public void release()
Description copied from interface: OrdContentSource
Releases the resources used by the content source.
Specified by:
release in interface OrdContentSource

Skip navigation links

Oracle Fusion Middleware interMedia Domains Java API Reference for Oracle ADF Business Components
11g Release 2 (11.1.2.3.0)

E17485-04


Copyright © 1997, 2012, Oracle. All rights reserved.