org.eclipse.emf.cdo.server.protocol
Class ServerCDOProtocolImpl

java.lang.Object
  extended by org.eclipse.net4j.spring.impl.LoggableImpl
      extended by org.eclipse.net4j.spring.impl.ServiceImpl
          extended by org.eclipse.net4j.core.impl.AbstractProtocol
              extended by org.eclipse.emf.cdo.core.protocol.AbstractCDOProtocol
                  extended by org.eclipse.emf.cdo.server.protocol.ServerCDOProtocolImpl
All Implemented Interfaces:
java.util.EventListener, CDODataTypes, CDOProtocol, CDOSignals, ServerCDOProtocol, ServerCDOResProtocol.Listener, org.eclipse.net4j.core.Protocol, org.eclipse.net4j.spring.Loggable, org.eclipse.net4j.spring.Service, org.eclipse.net4j.spring.StateListener, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener

public class ServerCDOProtocolImpl
extends AbstractCDOProtocol
implements ServerCDOProtocol, ServerCDOResProtocol.Listener


Nested Class Summary
 
Nested classes/interfaces inherited from class org.eclipse.net4j.spring.impl.ServiceImpl
org.eclipse.net4j.spring.impl.ServiceImpl.ServiceStateMachine
 
Field Summary
protected  Mapper mapper
           
protected  ServerCDOResProtocol serverCDOResProtocol
           
protected  org.springframework.transaction.support.TransactionTemplate transactionTemplate
           
 
Fields inherited from class org.eclipse.net4j.spring.impl.ServiceImpl
AUTOSTART_OFF_BITS, AUTOSTART_OFF_MASK, AUTOSTART_OFF_PAD, AUTOSTART_ON_BITS, AUTOSTART_ON_MASK, AUTOSTART_ON_PAD, flags, SERVICE_BITS, SINGLETON_BITS, SINGLETON_MASK, SINGLETON_PAD, STATE_BITS, STATE_MASK, STATE_PAD, VALIDITY_CONSISTENT, VALIDITY_INCONSISTENT, VALIDITY_INVALID
 
Fields inherited from class org.eclipse.net4j.spring.impl.LoggableImpl
GUARANTEED_LOGGING
 
Fields inherited from interface org.eclipse.emf.cdo.core.CDOProtocol
FEATURE_SET, FEATURE_UNSET, GLOBAL_EXTENT, GLOBAL_XREFS, LIST_ADD, LIST_MOVE, LIST_REMOVE, NO_MORE_OBJECT_CHANGES, NO_MORE_OBJECTS, NO_MORE_REFERENCE_CHANGES, NO_MORE_SEGMENTS, PROTOCOL_NAME, PROTOCOL_SCHEME, SLASH, UNKNOWN_RID
 
Fields inherited from interface org.eclipse.net4j.core.Protocol
CLIENT, SERVER, SYMMETRIC
 
Fields inherited from interface org.eclipse.emf.cdo.core.CDODataTypes
BOOLEAN, BOOLEAN_OBJECT, BYTE, BYTE_OBJECT, CHAR, CHAR_OBJECT, DOUBLE, DOUBLE_OBJECT, FLOAT, FLOAT_OBJECT, INT, INT_OBJECT, LONG, LONG_OBJECT, MAX_PRIMITIVE, MIN_PRIMITIVE, SHORT, SHORT_OBJECT, STRING, USER_DEFINED
 
Fields inherited from interface org.eclipse.emf.cdo.core.CDOSignals
ANNOUNCE_PACKAGE, COMMIT_TRANSACTION, DESCRIBE_PACKAGE, INVALIDATION_NOTIFICATION, LOAD_OBJECT, LOAD_RESOURCE, QUERY_EXTENT, QUERY_XREFS, REMOVAL_NOTIFICATION, RESOURCE_PATH, RESOURCE_RID
 
Constructor Summary
ServerCDOProtocolImpl()
           
 
Method Summary
protected  void activate()
           
 org.eclipse.net4j.core.Indication createIndication(short signalId)
           
protected  void deactivate()
           
 void fireInvalidationNotification(org.eclipse.net4j.core.Channel initiator, java.util.Collection<java.lang.Long> changedObjectIds)
           
 void fireRemovalNotification(java.util.Collection<java.lang.Integer> rids)
           
 Mapper getMapper()
           
 ServerCDOResProtocol getServerCDOResProtocol()
           
 org.springframework.transaction.support.TransactionTemplate getTransactionTemplate()
           
 int getType()
           
 void notifyInvalidation(ServerCDOResProtocol protocol, java.util.Collection<java.lang.Long> modifiedOIDs)
          Called by the ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with to notify about invalidated objects.
 void notifyRemoval(ServerCDOResProtocol protocol, java.util.Collection<java.lang.Integer> rids)
          Called by the ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with to notify about removed resources.
 void setMapper(Mapper mapper)
           
 void setServerCDOResProtocol(ServerCDOResProtocol serverCDOResProtocol)
           
 void setTransactionTemplate(org.springframework.transaction.support.TransactionTemplate transactionTemplate)
           
protected  void validate()
           
 
Methods inherited from class org.eclipse.emf.cdo.core.protocol.AbstractCDOProtocol
assertValidChannel, getName
 
Methods inherited from class org.eclipse.net4j.core.impl.AbstractProtocol
deregisterChannel, getChannels, getProtocolManager, getTypeString, isClient, isServer, registerChannel, setProtocolManager, typeString
 
Methods inherited from class org.eclipse.net4j.spring.impl.ServiceImpl
addStateListener, adjustPrototypeBeanName, afterPropertiesSet, assertActive, assertNotNull, assertNull, assertStopped, destroy, dispose, doSet, doSet, doSet, doSet, doSet, doSet, doSet, doSet, doSet, dump, dump, dump, getPrototypeCounter, getState, isActive, isAutoStart, isSingleton, isStarted, notifyDependencyActivated, notifyDependencyDeactivating, onApplicationEvent, removeStateListener, searchInconsistency, setApplicationContext, setAutoStart, setState, start, stop, testSetState
 
Methods inherited from class org.eclipse.net4j.spring.impl.LoggableImpl
debug, debug, error, error, fatal, fatal, formatLogMessage, getBeanName, getChild, getContainer, getFullBeanName, getLogger, info, info, isDebugEnabled, isErrorEnabled, isFatalEnabled, isInfoEnabled, isWarnEnabled, setBeanName, toString, warn, warn
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.net4j.core.Protocol
deregisterChannel, getChannels, getName, isClient, isServer, registerChannel
 
Methods inherited from interface org.eclipse.net4j.spring.Service
addStateListener, dump, getState, isActive, isAutoStart, isStarted, removeStateListener, start, stop, testSetState
 
Methods inherited from interface org.eclipse.net4j.spring.Loggable
debug, debug, error, error, fatal, fatal, getBeanName, getChild, getContainer, getFullBeanName, getLogger, info, info, isDebugEnabled, isErrorEnabled, isFatalEnabled, isInfoEnabled, isWarnEnabled, warn, warn
 

Field Detail

mapper

protected Mapper mapper

transactionTemplate

protected org.springframework.transaction.support.TransactionTemplate transactionTemplate

serverCDOResProtocol

protected ServerCDOResProtocol serverCDOResProtocol
Constructor Detail

ServerCDOProtocolImpl

public ServerCDOProtocolImpl()
Method Detail

getType

public int getType()
Specified by:
getType in interface org.eclipse.net4j.core.Protocol

createIndication

public org.eclipse.net4j.core.Indication createIndication(short signalId)
Specified by:
createIndication in interface org.eclipse.net4j.core.Protocol

getMapper

public Mapper getMapper()
Specified by:
getMapper in interface ServerCDOProtocol

setMapper

public void setMapper(Mapper mapper)

getTransactionTemplate

public org.springframework.transaction.support.TransactionTemplate getTransactionTemplate()
Specified by:
getTransactionTemplate in interface ServerCDOProtocol

setTransactionTemplate

public void setTransactionTemplate(org.springframework.transaction.support.TransactionTemplate transactionTemplate)

getServerCDOResProtocol

public ServerCDOResProtocol getServerCDOResProtocol()
Specified by:
getServerCDOResProtocol in interface ServerCDOProtocol

setServerCDOResProtocol

public void setServerCDOResProtocol(ServerCDOResProtocol serverCDOResProtocol)

notifyRemoval

public void notifyRemoval(ServerCDOResProtocol protocol,
                          java.util.Collection<java.lang.Integer> rids)
Description copied from interface: ServerCDOResProtocol.Listener
Called by the ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with to notify about removed resources.

Specified by:
notifyRemoval in interface ServerCDOResProtocol.Listener
Parameters:
protocol - The ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with.

rids - A Collection of RIDs which have been removed.


notifyInvalidation

public void notifyInvalidation(ServerCDOResProtocol protocol,
                               java.util.Collection<java.lang.Long> modifiedOIDs)
Description copied from interface: ServerCDOResProtocol.Listener
Called by the ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with to notify about invalidated objects.

Specified by:
notifyInvalidation in interface ServerCDOResProtocol.Listener
Parameters:
protocol - The ServerCDOResProtocol this ServerCDOResProtocol.Listener is registered with.

modifiedOIDs - A Collection of OIDs which have been invalidated.


fireRemovalNotification

public void fireRemovalNotification(java.util.Collection<java.lang.Integer> rids)
Specified by:
fireRemovalNotification in interface ServerCDOProtocol

fireInvalidationNotification

public void fireInvalidationNotification(org.eclipse.net4j.core.Channel initiator,
                                         java.util.Collection<java.lang.Long> changedObjectIds)
Specified by:
fireInvalidationNotification in interface ServerCDOProtocol

validate

protected void validate()
                 throws org.eclipse.net4j.spring.ValidationException
Overrides:
validate in class org.eclipse.net4j.core.impl.AbstractProtocol
Throws:
org.eclipse.net4j.spring.ValidationException

activate

protected void activate()
                 throws java.lang.Exception
Overrides:
activate in class org.eclipse.net4j.core.impl.AbstractProtocol
Throws:
java.lang.Exception

deactivate

protected void deactivate()
                   throws java.lang.Exception
Overrides:
deactivate in class org.eclipse.net4j.core.impl.AbstractProtocol
Throws:
java.lang.Exception

Copyright (c) 2004, 2005, 2006 Eike Stepper, Germany.
All Rights Reserved.