org.hd.d.pg2k.test.dev
Class SystemVariablesTest.LocalTunnelSource

java.lang.Object
  extended by org.hd.d.pg2k.svrCore.datasource.ExhibitDataTunnelSource
      extended by org.hd.d.pg2k.test.dev.SystemVariablesTest.LocalTunnelSource
All Implemented Interfaces:
SimpleExhibitPipelineIF, BasicVarMgrInterface, SimpleVariablePipelineIF
Enclosing class:
SystemVariablesTest

static class SystemVariablesTest.LocalTunnelSource
extends ExhibitDataTunnelSource

Local tunnel client/source, for connecting to LocalTunnelServer. This simulates a real tunnel, but all done locally.

Can be configured to force (de)serialisation of the RPC data as if sent on the wire, which will test the serialisation code and ensure no accidental data sharing "by reference" is going on.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.hd.d.pg2k.svrCore.datasource.ExhibitDataTunnelSource
ExhibitDataTunnelSource.HIRPCCache, ExhibitDataTunnelSource.PacketProtector, ExhibitDataTunnelSource.RawPacket
 
Nested classes/interfaces inherited from interface org.hd.d.pg2k.svrCore.datasource.SimpleExhibitPipelineIF
SimpleExhibitPipelineIF.PropsKey
 
Field Summary
private  boolean forceSerialization
          If true, force (de)serialisation as if on the wire.
private  SystemVariablesTest.LocalTunnelServer master
          Master server connection; never null.
 
Fields inherited from class org.hd.d.pg2k.svrCore.datasource.ExhibitDataTunnelSource
_protocolDebug, EMPTY_PAYLOAD, FAIL_RETRY_WAIT_MAX_MS, FAIL_RETRY_WAIT_MIN_MS, KEEP_SERVER_CONNECTION_ALIVE, logger, MAX_AEP_DIFF_COMP_LEVEL, TSNAME_RPCIOEX, TSNAME_RPCREQUEST, TSNAME_SHORTREAD, TSNAMEPR_RPCTYPE, uniqueClientID
 
Fields inherited from interface org.hd.d.pg2k.svrCore.datasource.SimpleExhibitPipelineIF
MAX_USER_READ_SIZE
 
Constructor Summary
SystemVariablesTest.LocalTunnelSource(SystemVariablesTest.LocalTunnelServer master, boolean forceSerialization, SimpleLoggerIF logger)
          Construct local tunnel source.
 
Method Summary
 void destroy()
          Does nothing in this implementation.
protected  ExhibitDataTunnelSource.RawPacket doRPCRaw(ExhibitDataTunnelSource.RawPacket request)
          Provide the implementation of the data transport.
 
Methods inherited from class org.hd.d.pg2k.svrCore.datasource.ExhibitDataTunnelSource
doNOOP, doRPC, doRPCRawWithStreamResponse, doRPCUnguarded, getAllExhibitImmutableData, getAllExhibitProperties, getAllExhibitProperties, getEventValue, getEventValues, getGenProps, getGenSecProps, getLastSuccessfulConnectionTime, getProperties, getRawFile, getStaticAttr, getThumbnails, getVariable, getVariables, handleInboundRPC, intSer, isBroken, longSer, poll, setVariable, setVariables, syncVariables
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

master

private final SystemVariablesTest.LocalTunnelServer master
Master server connection; never null.


forceSerialization

private final boolean forceSerialization
If true, force (de)serialisation as if on the wire.

Constructor Detail

SystemVariablesTest.LocalTunnelSource

SystemVariablesTest.LocalTunnelSource(SystemVariablesTest.LocalTunnelServer master,
                                      boolean forceSerialization,
                                      SimpleLoggerIF logger)
Construct local tunnel source. Sequesters reference to the LocalTunnelServer (the master), and notes whether all RPC packets should be (de)serialised.

Method Detail

doRPCRaw

protected ExhibitDataTunnelSource.RawPacket doRPCRaw(ExhibitDataTunnelSource.RawPacket request)
                                              throws java.io.IOException
Provide the implementation of the data transport.

Specified by:
doRPCRaw in class ExhibitDataTunnelSource
Parameters:
request - request packet; never null
Returns:
response packet; never null
Throws:
java.io.IOException - in case of I/O difficulties

destroy

public void destroy()
Does nothing in this implementation.

Specified by:
destroy in interface SimpleExhibitPipelineIF
Overrides:
destroy in class ExhibitDataTunnelSource

DHD Multimedia Gallery V1.53.0

Copyright (c) 1996-2009, Damon Hart-Davis. All rights reserved.