Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-03


oracle.irm.engine.content.sealing
Class ContentSizeMismatchException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.io.IOException
              extended by oracle.irm.engine.content.sealing.ContentSizeMismatchException

All Implemented Interfaces:
Serializable

public class ContentSizeMismatchException
extends IOException

Unsealed content size mismatch. When unsealed content is sealed the size of the unsealed data can be explicitly specified or inferred from the input data (e.g. file size or byte array length). This exception is thrown when the unsealed content size provided during sealing does not match the amount of data read from the unsealed data stream.

The error message associated with this exception is:

IRM-01081: The expected size of the unsealed content was {0} bytes in length. The actual number of bytes read from the input stream was {1}.
See Also:
Serialized Form

Constructor Summary
ContentSizeMismatchException(long expected, long actual)
          Constructor.
ContentSizeMismatchException(long expected, long actual, Throwable cause)
          Constructor.

 

Method Summary
 long getActual()
          Actual size of the data read from the stream.
 long getExpected()
          The expected size of the unsealed data.

 

Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString

 

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

 

Constructor Detail

ContentSizeMismatchException

public ContentSizeMismatchException(long expected,
                                    long actual)
Constructor.
Parameters:
expected - The expected size of the unsealed data.
actual - Actual size of the data read from the stream.

ContentSizeMismatchException

public ContentSizeMismatchException(long expected,
                                    long actual,
                                    Throwable cause)
Constructor.
Parameters:
expected - The expected size of the unsealed data.
actual - Actual size of the data read from the stream.
cause - Cause of the exception.

Method Detail

getExpected

public final long getExpected()
The expected size of the unsealed data.
Returns:
the value of the property.

getActual

public final long getActual()
Actual size of the data read from the stream.
Returns:
the value of the property.

Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-03


Copyright © 2011, Oracle. All rights reserved.