wt.transfer
Class StandardTransferService

java.lang.Object
  extended bywt.services.StandardManager
      extended bywt.transfer.StandardTransferService
All Implemented Interfaces:
Manager, NetFactor, Serializable, TransferService

public class StandardTransferService
extends StandardManager
implements TransferService, Serializable

Provides the standard implementation of server-side functionality as defined by the TransferService interface. This class is the one intended to be extended to enhance functionality.

As defined by the standard transfer service's access control rules, all objects being either exported or imported must be checked to ensure that the session's principal performing the transfer has applicable permissions. For exports the session principal must be able to read the objects. For imports the session principal must be able to create and/or modify the objects.

Additionally, when object are being imported if they are not currently assigned as being owned and foldered, then the transfer service is responsible for ensuring that these objects will be correctly persisted.

If the standard implementation is not desired then a custom implementation can extend from TransferService alongside the standard implementation, and be specified as a property to be used as the default transfer service.

Use the newStandardTransferService static factory method(s), not the StandardTransferService constructor, to construct instances of this class. Instances must be constructed using the static factory(s), in order to ensure proper initialization of the instance.



Supported API: false

Extendable: false

See Also:
StandardManager, Serialized Form

Field Summary
private static String CLASSNAME
           
private static String RESOURCE
           
private static TransferService service
           
 
Fields inherited from class wt.services.StandardManager
 
Fields inherited from interface wt.services.Manager
MANAGER_SERVICE, STARTUP_AUTOMATIC, STARTUP_MANUAL, STATUS_EMERGENCY_SHUTDOWN, STATUS_EMERGENCY_SHUTTING_DOWN, STATUS_SHUTDOWN, STATUS_SHUTDOWN_ERRORS, STATUS_SHUTDOWN_FAILURE, STATUS_SHUTTING_DOWN, STATUS_STARTED, STATUS_STARTED_ERRORS, STATUS_STARTING_UP, STATUS_STARTUP_FAILURE
 
Constructor Summary
StandardTransferService()
           
 
Method Summary
private  void expandNode(ClassInfo nodeinfo, Hashtable pihash)
           
 void exportObjects(ExportSpec spec)
          

Supported API: false
 void exportObjects(ExportSpec spec, Persistable objectBasis)
          

Supported API: false
 void exportObjects(ExportSpec spec, Persistable objectBasis, ConfigSpec configBasis)
          

Supported API: false
 void exportObjects(ExportSpec spec, TransferFilter[] filters)
          

Supported API: false
 void exportObjects(ExportSpec spec, TransferFilter template, ConfigSpec configBasis)
          

Supported API: false
 void exportObjects(ExportSpec spec, TransferFilter template, Persistable objectBasis)
          

Supported API: false
 void exportObjects(ExportSpec spec, TransferFilter template, Persistable objectBasis, ConfigSpec configBasis)
          

Supported API: false
 Hashtable getAllDescendentsOf(Class target)
          

Supported API: false
 Hashtable getAllDescendentsOf(String classname)
          

Supported API: false
 String getConceptualClassname()
          Returns the conceptual (modeled) name for the class.
 Vector getDirectDescendentsOf(Class target)
          

Supported API: false
 Vector getDirectDescendentsOf(String classname)
          

Supported API: false
static TransferService getService()
           
protected  boolean hasAccess(String typename, String permission)
          

Supported API: false
 void importObjects(ImportSpec spec)
          

Supported API: false
 void importObjects(ImportSpec spec, TransferFilter[] filters)
          

Supported API: false
static StandardTransferService newStandardTransferService()
          Default factory for the class.
protected  void performStartupProcess()
          Overrides the startup process specific to the transfer service to provide custom startup for event subscription.
 void registerEvents(ManagerService manager)
          Overrides the registration of all applicable transfer service events with the service manager.
 
Methods inherited from class wt.services.StandardManager
emergencyShutdown, emergencyShutdownComplete, emergencyShuttingDown, getClassInfo, getManagerService, getManagerStatus, getName, getStartupType, init, initialize, initialize, isStarted, newStandardManager, newStandardManager, performEmergencyShutdownProcess, performShutdownProcess, setManagerService, shutdown, shutdownFailure, shutdownSuccess, shuttingDown, started, startedErrors, startingUp, startup, startupFailure, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

service

private static TransferService service
Constructor Detail

StandardTransferService

public StandardTransferService()
Method Detail

getConceptualClassname

public String getConceptualClassname()
Returns the conceptual (modeled) name for the class.

Supported API: true

Specified by:
getConceptualClassname in interface NetFactor
Overrides:
getConceptualClassname in class StandardManager
Returns:
String

registerEvents

public void registerEvents(ManagerService manager)
Overrides the registration of all applicable transfer service events with the service manager.

Supported API: false

Specified by:
registerEvents in interface Manager
Overrides:
registerEvents in class StandardManager
Parameters:
manager -

performStartupProcess

protected void performStartupProcess()
                              throws ManagerException
Overrides the startup process specific to the transfer service to provide custom startup for event subscription. During subscription an anonymous inner class adapter is created per subscription to handle each specific event of interest.

Supported API: false

Overrides:
performStartupProcess in class StandardManager
Throws:
ManagerException

hasAccess

protected boolean hasAccess(String typename,
                            String permission)
                     throws WTException


Supported API: false

Parameters:
typename -
permission -
Returns:
boolean
Throws:
WTException

newStandardTransferService

public static StandardTransferService newStandardTransferService()
                                                          throws WTException
Default factory for the class.

Supported API: false

Returns:
StandardTransferService
Throws:
WTException

exportObjects

public void exportObjects(ExportSpec spec)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          Persistable objectBasis)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
objectBasis -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          Persistable objectBasis,
                          ConfigSpec configBasis)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
objectBasis -
configBasis -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          TransferFilter[] filters)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
filters -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          TransferFilter template,
                          Persistable objectBasis)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
template -
objectBasis -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          TransferFilter template,
                          ConfigSpec configBasis)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
template -
configBasis -
Throws:
WTException
TransferException
WTPropertyVetoException

exportObjects

public void exportObjects(ExportSpec spec,
                          TransferFilter template,
                          Persistable objectBasis,
                          ConfigSpec configBasis)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
exportObjects in interface TransferService
Parameters:
spec -
template -
objectBasis -
configBasis -
Throws:
WTException
TransferException
WTPropertyVetoException

importObjects

public void importObjects(ImportSpec spec)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
importObjects in interface TransferService
Parameters:
spec -
Throws:
WTException
TransferException
WTPropertyVetoException

importObjects

public void importObjects(ImportSpec spec,
                          TransferFilter[] filters)
                   throws WTException,
                          TransferException,
                          WTPropertyVetoException


Supported API: false

Specified by:
importObjects in interface TransferService
Parameters:
spec -
filters -
Throws:
WTException
TransferException
WTPropertyVetoException

getAllDescendentsOf

public Hashtable getAllDescendentsOf(Class target)
                              throws WTException,
                                     TransferException,
                                     WTIntrospectionException


Supported API: false

Specified by:
getAllDescendentsOf in interface TransferService
Parameters:
target -
Returns:
Hashtable
Throws:
WTException
TransferException
WTIntrospectionException

getAllDescendentsOf

public Hashtable getAllDescendentsOf(String classname)
                              throws WTException,
                                     TransferException,
                                     WTIntrospectionException


Supported API: false

Specified by:
getAllDescendentsOf in interface TransferService
Parameters:
classname -
Returns:
Hashtable
Throws:
WTException
TransferException
WTIntrospectionException

getDirectDescendentsOf

public Vector getDirectDescendentsOf(Class target)
                              throws WTException,
                                     TransferException,
                                     WTIntrospectionException


Supported API: false

Specified by:
getDirectDescendentsOf in interface TransferService
Parameters:
target -
Returns:
Vector
Throws:
WTException
TransferException
WTIntrospectionException

getDirectDescendentsOf

public Vector getDirectDescendentsOf(String classname)
                              throws WTException,
                                     TransferException,
                                     WTIntrospectionException


Supported API: false

Specified by:
getDirectDescendentsOf in interface TransferService
Parameters:
classname -
Returns:
Vector
Throws:
WTException
TransferException
WTIntrospectionException

expandNode

private void expandNode(ClassInfo nodeinfo,
                        Hashtable pihash)

getService

public static TransferService getService()