/**
* This file is auto generated from JavaDoc. Do not modify it manually.
*/
import type { InputStream } from "../../../java/io/InputStream";
/**
* A Binary object holds a JCR property value of type
* BINARY. The Binary interface and the related
* methods in {@link Property}, {@link Value} and {@link ValueFactory} replace
* the deprecated {@link Value#getStream} and {@link Property#getStream}
* methods.
* @since JCR 2.0
* @since Sitevision 3.5
*/
export type Binary = {
/**
* Returns an {@link InputStream} representation of this value. Each call to
* getStream() returns a new stream. The API consumer is
* responsible for calling close() on the returned stream.
*
* If {@link #dispose()} has been called on this Binary
* object, then this method will throw the runtime exception
* {@link java.lang.IllegalStateException}.
* @return A stream representation of this value.
* @throws RepositoryException if an error occurs.
*/
getStream(): InputStream;
/**
* Returns the size of this Binary value in bytes.
*
* If {@link #dispose()} has been called on this Binary
* object, then this method will throw the runtime exception
* {@link java.lang.IllegalStateException}.
* @return the size of this value in bytes.
* @throws RepositoryException if an error occurs.
*/
getSize(): number;
/**
* Releases all resources associated with this Binary object
* and informs the repository that these resources may now be reclaimed.
* An application should call this method when it is finished with the
* Binary object.
*/
dispose(): void;
};