Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.wlrt.adapter.defaultprovider.impl
Class SocketAdapterImpl

    java.lang.Object
      |
      +--com.bea.wlrt.ede.impl.AbstractStreamingEventSource
            |
            +--com.bea.wlrt.ede.impl.AbstractStage
                  |
                  +--com.bea.wlrt.ede.impl.AbstractAdapter
                        |
                        +--com.bea.wlrt.adapter.defaultprovider.impl.SocketAdapterImpl

Direct Known Subclasses:
  PacketAdapterImpl

public abstract class SocketAdapterImpl
extends AbstractAdapter
implements SocketAdapter

Creates a server connection and waits for incoming client connections. Inherited classes must provide a listener to handle read/write for the connection.

See Also:
  `CSVAdapterImpl`, `PacketAdapterImpl`

Constructor Summary
`protected` | `SocketAdapterImpl(String id)`
`protected` | `SocketAdapterImpl(String id, int port)`

Method Summary
`void` | `connectionCreated(Connection conn)` This method is called each time a new client connection is established.
`int` | `getPort()`
`protected abstract Connection.Listener` | `getReadListener(Connection conn)` Returns a listener which will handle reading and writing for this connection
`protected ServerConnection` | `getServerConnection()`
`void` | `onEvent(List newEvents)`
`void` | `setPort(int port)`
`protected void` | `setupServerConnection(int port)`

Methods inherited from class com.bea.wlrt.ede.impl.AbstractAdapter
`getEventGenerator`

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

Constructor Detail

### SocketAdapterImpl

    protected SocketAdapterImpl(String id)

### SocketAdapterImpl

    protected SocketAdapterImpl(String id,
                                int port)

Method Detail

### setupServerConnection

    protected void setupServerConnection(int port)

### onEvent

    public void onEvent(List newEvents)
                 throws RejectStreamingEventException

  Overrides:
    onEvent in class com.bea.wlrt.ede.impl.AbstractStage

### getServerConnection

    protected ServerConnection getServerConnection()

### getPort

    public int getPort()

  Specified by:
    getPort in interface SocketAdapter

### setPort

    public void setPort(int port)

  Specified by:
    setPort in interface SocketAdapter

### connectionCreated

    public void connectionCreated(Connection conn)

  This method is called each time a new client connection is established.

### getReadListener

    protected abstract Connection.Listener getReadListener(Connection conn)

  Returns a listener which will handle reading and writing for this connection

  Returns:
    a connection listener

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD