GemFire 5.5

com.gemstone.gemfire.cache.util
Class BridgeEventCallbackArgument

java.lang.Object
  extended by com.gemstone.gemfire.cache.util.BridgeEventCallbackArgument
All Implemented Interfaces:
DataSerializable, Serializable

public class BridgeEventCallbackArgument
extends Object
implements DataSerializable

Class BridgeEventCallbackArgument is a wrapper on a callback arg plus the host and port of the client originating the event containing this BridgeEventCallbackArgument. It is created by the server when it receives an update request from a client and used to determine the originator of the event by the CacheClientNotifier. The original callback argument is wrapped by this one and replaced in the event sent to CacheListener, CacheWriter and CacheLoader.

Since:
5.0
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface com.gemstone.gemfire.DataSerializable
DataSerializable.Replaceable
 
Constructor Summary
BridgeEventCallbackArgument()
          No arg constructor for DataSerializable.
BridgeEventCallbackArgument(Object originalCallbackArg, DistributedMember clientMember)
          Constructor.
BridgeEventCallbackArgument(Object originalCallbackArg, String clientHost, int clientPort, DistributedMember clientMember)
          Constructor.
 
Method Summary
 void fromData(DataInput in)
          Reads the state of this object as primitive data from the given DataInput.
 DistributedMember getClientMember()
          Returns the DistributedMember of the client originating the event containing this BridgeEventCallbackArgument.
 Object getOriginalCallbackArg()
          Returns the original callback argument.
 void toData(DataOutput out)
          Writes the state of this object as primitive data to the given DataOutput.
 String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BridgeEventCallbackArgument

public BridgeEventCallbackArgument()
No arg constructor for DataSerializable.


BridgeEventCallbackArgument

public BridgeEventCallbackArgument(Object originalCallbackArg,
                                   String clientHost,
                                   int clientPort,
                                   DistributedMember clientMember)
Constructor.

Parameters:
originalCallbackArg - The original callback argument set by the caller or null if there was not callback arg
clientHost - The host of the client originating the event containing this BridgeEventCallbackArgument
clientPort - The port of the client originating the event containing this BridgeEventCallbackArgument
clientMember - the DistributedMember ID of the client

BridgeEventCallbackArgument

public BridgeEventCallbackArgument(Object originalCallbackArg,
                                   DistributedMember clientMember)
Constructor.

Parameters:
originalCallbackArg - The original callback argument set by the caller or null if there was not callback arg
clientMember - the DistributedMember ID of the client
Method Detail

getOriginalCallbackArg

public Object getOriginalCallbackArg()
Returns the original callback argument.

Returns:
the original callback argument

getClientMember

public DistributedMember getClientMember()
Returns the DistributedMember of the client originating the event containing this BridgeEventCallbackArgument.

Returns:
the DistributedMember of the client originating the event containing this BridgeEventCallbackArgument

toData

public void toData(DataOutput out)
            throws IOException
Description copied from interface: DataSerializable
Writes the state of this object as primitive data to the given DataOutput.

Specified by:
toData in interface DataSerializable
Throws:
IOException - A problem occurs while writing to out

fromData

public void fromData(DataInput in)
              throws IOException,
                     ClassNotFoundException
Description copied from interface: DataSerializable
Reads the state of this object as primitive data from the given DataInput.

Specified by:
fromData in interface DataSerializable
Throws:
IOException - A problem occurs while reading from in
ClassNotFoundException - A class could not be loaded while reading from in

toString

public String toString()
Overrides:
toString in class Object

GemFire 5.5

Copyright © 2002-2008 GemStone Systems, Inc. All Rights Reserved.