RemoteInputStream (Hyperic HQ Plugin API)
Keywords: org.hyperic.hq.transport.util.RemoteInputStream class

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hyperic.hq.transport.util
Class RemoteInputStream

    java.lang.Object
      java.io.InputStream
          org.hyperic.hq.transport.util.RemoteInputStream

All Implemented Interfaces:
  java.io.Closeable, java.io.Externalizable, java.io.Serializable

    public class RemoteInputStream

extends java.io.InputStream
implements java.io.Externalizable

An input stream that maintains a local byte buffer replenished via calls to a remote source. The stream id is used to maintain the stream state on the remote source. This class is not thread safe. The invoker locator to the remote source must be set before reading from this stream.

See Also:
  Serialized Form

Constructor Summary
`RemoteInputStream()` Default constructor for externalization only.
`RemoteInputStream(java.lang.String streamId)` Creates an instance on the remote source to be serialized and sent to the remote client reading from this stream.

Method Summary
`int` | `available()`
`void` | `close()`
`java.lang.String` | `getStreamId()`
`int` | `read()`
`int` | `read(byte[] b, int off, int len)`
`void` | `readExternal(java.io.ObjectInput in)`
`void` | `setRemoteSourceInvokerLocator(org.jboss.remoting.InvokerLocator invokerLocator)` Set the invoker locator to the remote source.
`void` | `writeExternal(java.io.ObjectOutput out)`

Methods inherited from class java.io.InputStream
`mark, markSupported, read, reset, skip`

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

Constructor Detail

### RemoteInputStream

    public RemoteInputStream()

  Default constructor for externalization only.

### RemoteInputStream

    public RemoteInputStream(java.lang.String streamId)

  Creates an instance on the remote source to be serialized and sent to the remote client reading from this stream.

  Parameters:
    `streamId` - The stream id that uniquely identifies this stream on the remote source.
  Throws:
    `java.lang.NullPointerException` - if the stream id is `null`.

Method Detail

### setRemoteSourceInvokerLocator

    public void setRemoteSourceInvokerLocator(org.jboss.remoting.InvokerLocator invokerLocator)

  Set the invoker locator to the remote source.

  Parameters:
    `invokerLocator` - The invoker locator to the remote source.
  Throws:
    `java.lang.NullPointerException` - if the invoker locator is `null`.

### available

    public int available()
                  throws java.io.IOException

  Overrides:
    `available` in class `java.io.InputStream`
  Throws:
    `java.io.IOException`
  See Also:
    `InputStream.available()`

### read

    public int read(byte[] b,
                    int off,
                    int len)
             throws java.io.IOException

  Overrides:
    `read` in class `java.io.InputStream`
  Throws:
    `java.io.IOException`
  See Also:
    `InputStream.read(byte[], int, int)`

### read

    public int read()
             throws java.io.IOException

  Specified by:
    `read` in class `java.io.InputStream`
  Throws:
    `java.io.IOException`
  See Also:
    `InputStream.read()`

### close

    public void close()
               throws java.io.IOException

  Specified by:
    `close` in interface `java.io.Closeable`
  Overrides:
    `close` in class `java.io.InputStream`
  Throws:
    `java.io.IOException`
  See Also:
    `InputStream.close()`

### getStreamId

    public java.lang.String getStreamId()

  Returns:
    The uniquely identifying stream id.

### readExternal

    public void readExternal(java.io.ObjectInput in)
                      throws java.io.IOException,
                             java.lang.ClassNotFoundException

  Specified by:
    `readExternal` in interface `java.io.Externalizable`
  Throws:
    `java.io.IOException`
    `java.lang.ClassNotFoundException`

### writeExternal

    public void writeExternal(java.io.ObjectOutput out)
                       throws java.io.IOException

  Specified by:
    `writeExternal` in interface `java.io.Externalizable`
  Throws:
    `java.io.IOException`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.