public class ServerAdapterFactory extends Object implements RemoteAdapterFactory
RemoteAdapterFactory interface. This factory uses the server adapters
defined in this package as the default adapter implementations. Subclasses
can override or extend the default adapters by implementing the corresponding
factory methods.
The bufferSize property can be used to configure the size of the
buffer used by iterators to speed up iterator traversal over the network.
| Constructor and Description |
|---|
ServerAdapterFactory() |
public int getBufferSize()
public void setBufferSize(int bufferSize)
bufferSize - iterator buffer sizepublic int getPortNumber()
getPortNumber in interface RemoteAdapterFactorypublic void setPortNumber(int portNumber)
portNumber - port number, or 0 for the defaultpublic RemoteRepository getRemoteRepository(Repository repository) throws RemoteException
ServerRepository instance.
Returns a remote adapter for the given local repository.getRemoteRepository in interface RemoteAdapterFactoryrepository - local repositoryRemoteException - on RMI errorspublic RemoteSession getRemoteSession(Session session) throws RemoteException
ServerSession instance. In case the
underlying session is transaction enabled, the remote interface is will
be transaction enabled too through the ServerXASession.
Returns a remote adapter for the given local session.getRemoteSession in interface RemoteAdapterFactorysession - local sessionRemoteException - on RMI errorspublic RemoteWorkspace getRemoteWorkspace(Workspace workspace) throws RemoteException
ServerWorkspace instance. Returns a remote adapter for the given local workspace.getRemoteWorkspace in interface RemoteAdapterFactoryworkspace - local workspaceRemoteException - on RMI errorspublic RemoteObservationManager getRemoteObservationManager(ObservationManager observationManager) throws RemoteException
ServerObservationManager
instance. Returns a remote adapter for the given local observation manager.getRemoteObservationManager in interface RemoteAdapterFactoryobservationManager - local observation managerRemoteException - on RMI errorspublic RemoteNamespaceRegistry getRemoteNamespaceRegistry(NamespaceRegistry registry) throws RemoteException
ServerNamespaceRegistry
instance. Returns a remote adapter for the given local namespace registry.getRemoteNamespaceRegistry in interface RemoteAdapterFactoryregistry - local namespace registryRemoteException - on RMI errorspublic RemoteNodeTypeManager getRemoteNodeTypeManager(NodeTypeManager manager) throws RemoteException
ServerNodeTypeManager instance.
Returns a remote adapter for the given local node type manager.getRemoteNodeTypeManager in interface RemoteAdapterFactorymanager - local node type managerRemoteException - on RMI errorspublic RemoteItem getRemoteItem(Item item) throws RemoteException
ServerItem instance. Returns a remote adapter for the given local item. This method
will return an adapter that implements only the
Item interface. The caller may want to introspect
the local item to determine whether to use either the
getRemoteNode or the
getRemoteProperty method instead.getRemoteItem in interface RemoteAdapterFactoryitem - local itemRemoteException - on RMI errorspublic RemoteProperty getRemoteProperty(Property property) throws RemoteException
ServerProperty instance. Returns a remote adapter for the given local property.getRemoteProperty in interface RemoteAdapterFactoryproperty - local propertyRemoteException - on RMI errorspublic RemoteNode getRemoteNode(Node node) throws RemoteException
ServerNode instance. Returns a remote adapter for the given local node.getRemoteNode in interface RemoteAdapterFactorynode - local nodeRemoteException - on RMI errorspublic RemoteVersion getRemoteVersion(Version version) throws RemoteException
ServerVersion instance. Returns a remote adapter for the given local version.getRemoteVersion in interface RemoteAdapterFactoryversion - local versionRemoteException - on RMI errorspublic RemoteVersionHistory getRemoteVersionHistory(VersionHistory versionHistory) throws RemoteException
ServerVersionHistory instance.
Returns a remote adapter for the given local version history.getRemoteVersionHistory in interface RemoteAdapterFactoryversionHistory - local version historyRemoteException - on RMI errorspublic RemoteNodeType getRemoteNodeType(NodeType type) throws RemoteException
ServerNodeType instance. Returns a remote adapter for the given local node type.getRemoteNodeType in interface RemoteAdapterFactorytype - local node typeRemoteException - on RMI errorspublic RemoteItemDefinition getRemoteItemDefinition(ItemDefinition def) throws RemoteException
ServerItemDefinition instance.
Returns a remote adapter for the given local item definition.
This method will return an adapter that implements only the
ItemDefinition interface. The caller may want to introspect
the local item definition to determine whether to use either the
getRemoteNodeDef or the
getRemotePropertyDef
method instead.getRemoteItemDefinition in interface RemoteAdapterFactorydef - local item definitionRemoteException - on RMI errorspublic RemoteNodeDefinition getRemoteNodeDefinition(NodeDefinition def) throws RemoteException
ServerNodeDefinition instance.
Returns a remote adapter for the given local node definition.getRemoteNodeDefinition in interface RemoteAdapterFactorydef - local node definitionRemoteException - on RMI errorspublic RemotePropertyDefinition getRemotePropertyDefinition(PropertyDefinition def) throws RemoteException
ServerPropertyDefinition
instance. Returns a remote adapter for the given local property definition.getRemotePropertyDefinition in interface RemoteAdapterFactorydef - local property definitionRemoteException - on RMI errorspublic RemoteLock getRemoteLock(Lock lock) throws RemoteException
ServerLock instance. Returns a remote adapter for the given local lock.getRemoteLock in interface RemoteAdapterFactorylock - local lockRemoteException - on RMI errorspublic RemoteQueryManager getRemoteQueryManager(Session session, QueryManager manager) throws RemoteException
ServerQueryManager instance.
Returns a remote adapter for the given local query manager.getRemoteQueryManager in interface RemoteAdapterFactorysession - current sessionmanager - local query managerRemoteException - on RMI errorspublic RemoteQuery getRemoteQuery(Query query) throws RemoteException
ServerQuery instance. Returns a remote adapter for the given local query.getRemoteQuery in interface RemoteAdapterFactoryquery - local queryRemoteException - on RMI errorspublic RemoteQueryResult getRemoteQueryResult(QueryResult result) throws RemoteException
ServerQueryResult instance.
Returns a remote adapter for the given local query result.getRemoteQueryResult in interface RemoteAdapterFactoryresult - local query resultRemoteException - on RMI errorspublic RemoteRow getRemoteRow(Row row) throws RemoteException
ServerQueryResult instance.
Returns a remote adapter for the given local query row.getRemoteRow in interface RemoteAdapterFactoryrow - local query rowRemoteException - on RMI errorspublic RemoteEventCollection getRemoteEvent(long listenerId, EventIterator events) throws RemoteException
ServerEventCollection instances.
Returns a remote adapter for the given local events.getRemoteEvent in interface RemoteAdapterFactorylistenerId - The listener identifier to which the events are to be
dispatched.events - the local eventsRemoteException - on RMI errorsprotected RemoteIterator optimizeIterator(RemoteIterator remote) throws RemoteException
RemoteIterator.nextObjects() and then asks for the total
size of the iterator. If the size is unkown or greater than the length of
the retrieved array, then the elements, the size, and the remote iterator
reference are wrapped into a BufferIterator instance that gets
passed over the network. If the retrieved array of elements contains all
the elements in the iterator, then the iterator instance is discarded and
just the elements are wrapped into a ArrayIterator instance to be
passed to the client.
Subclasses can override this method to provide alternative optimizations.
remote - remote iteratorRemoteException - on RMI errorspublic RemoteIterator getRemoteNodeIterator(NodeIterator iterator) throws RemoteException
ServerNodeIterator instance. Returns a remote adapter for the given local node iterator.getRemoteNodeIterator in interface RemoteAdapterFactoryiterator - local node iteratorRemoteException - on RMI errorspublic RemoteIterator getRemotePropertyIterator(PropertyIterator iterator) throws RemoteException
ServerPropertyIterator instance. Returns a remote adapter for the given local property iterator.getRemotePropertyIterator in interface RemoteAdapterFactoryiterator - local property iteratorRemoteException - on RMI errorspublic RemoteIterator getRemoteVersionIterator(VersionIterator iterator) throws RemoteException
ServerVersionIterator instance. Returns a remote adapter for the given local version iterator.getRemoteVersionIterator in interface RemoteAdapterFactoryiterator - local version iteratorRemoteException - on RMI errorspublic RemoteIterator getRemoteNodeTypeIterator(NodeTypeIterator iterator) throws RemoteException
ServerNodeTypeIterator instance. Returns a remote adapter for the given local node type iterator.getRemoteNodeTypeIterator in interface RemoteAdapterFactoryiterator - local node type iteratorRemoteException - on RMI errorspublic RemoteIterator getRemoteRowIterator(RowIterator iterator) throws RemoteException
ServerRowIterator instance. Returns a remote adapter for the given local row iterator.getRemoteRowIterator in interface RemoteAdapterFactoryiterator - local row iteratorRemoteException - on RMI errorspublic RemoteLockManager getRemoteLockManager(LockManager lockManager) throws RemoteException
getRemoteLockManager in interface RemoteAdapterFactoryRemoteExceptionpublic RemoteVersionManager getRemoteVersionManager(Session session, VersionManager versionManager) throws RemoteException
getRemoteVersionManager in interface RemoteAdapterFactoryRemoteExceptionpublic RemoteAccessControlManager getRemoteAccessControlManager(AccessControlManager acm) throws RemoteException
ServerAccessControlManager
instance. Returns a remote adapter for the given local access control manager.getRemoteAccessControlManager in interface RemoteAdapterFactoryacm - local access control managerRemoteException - on RMI errorspublic RemotePrivilege getRemotePrivilege(Privilege local) throws RemoteException
RemoteAdapterFactorygetRemotePrivilege in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemotePrivilege[] getRemotePrivilege(Privilege[] local) throws RemoteException
RemoteAdapterFactorygetRemotePrivilege in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteAccessControlPolicy getRemoteAccessControlPolicy(AccessControlPolicy local) throws RemoteException
RemoteAdapterFactorygetRemoteAccessControlPolicy in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteAccessControlPolicy[] getRemoteAccessControlPolicy(AccessControlPolicy[] local) throws RemoteException
RemoteAdapterFactorygetRemoteAccessControlPolicy in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteIterator getRemoteAccessControlPolicyIterator(AccessControlPolicyIterator iterator) throws RemoteException
ServerNodeIterator instance. Returns a remote adapter for the given local access control manager.getRemoteAccessControlPolicyIterator in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteAccessControlEntry getRemoteAccessControlEntry(AccessControlEntry local) throws RemoteException
RemoteAdapterFactorygetRemoteAccessControlEntry in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteAccessControlEntry[] getRemoteAccessControlEntry(AccessControlEntry[] local) throws RemoteException
RemoteAdapterFactorygetRemoteAccessControlEntry in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemotePrincipal getRemotePrincipal(Principal principal) throws RemoteException
RemoteAdapterFactorygetRemotePrincipal in interface RemoteAdapterFactoryRemoteException - on RMI errorspublic RemoteIterator getRemotePrincipalIterator(Iterator<Principal> principals) throws RemoteException
RemoteAdapterFactorygetRemotePrincipalIterator in interface RemoteAdapterFactoryRemoteException - on RMI errorsCopyright © 2004–2021 The Apache Software Foundation. All rights reserved.