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

## org.apache.cayenne.remote
Interface ClientConnection

All Known Implementing Classes:
  BaseConnection, HessianConnection, LocalConnection

    public interface ClientConnection

A connection object used to interact with a remote Cayenne server. Connection supports synchronous interaction via `sendMessage(ClientMessage)` and asynchronous listening for server events.

Since:
  1.2
Author:
  Andrus Adamchik

Method Summary
`EventBridge` | `getServerEventBridge()` Returns an EventBridge that receives remote server events.
`Object` | `sendMessage(ClientMessage message)` Sends a synchronous ClientMessage to the server, returning a reply.

Method Detail

### getServerEventBridge

    EventBridge getServerEventBridge()
                                     throws CayenneRuntimeException

  Returns an EventBridge that receives remote server events. Caller would normally register returned bridge with a local EventManager, thus allowing local listeners to receive server events.

  Returns:
    An EventBridge or null if server events are not supported.
  Throws:
    `CayenneRuntimeException`

### sendMessage

    Object sendMessage(ClientMessage message)
                       throws CayenneRuntimeException

  Sends a synchronous ClientMessage to the server, returning a reply.

  Throws:
    `CayenneRuntimeException`

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

Copyright © 2001-2007 Apache Cayenne. All Rights Reserved.