Package com.sun.star.comp.connections
Class Acceptor
java.lang.Object
com.sun.star.comp.connections.Acceptor
- All Implemented Interfaces:
com.sun.star.connection.XAcceptor
,com.sun.star.uno.XInterface
A component that implements the
XAcceptor
interface.
The Acceptor
is a general component, that uses less general
components (like com.sun.star.connection.socketAcceptor
) to
implement its functionality.
- Since:
- UDK 1.0
- See Also:
-
XAcceptor
XConnection
XConnector
JavaLoader
-
Field Summary
FieldsFields inherited from interface com.sun.star.connection.XAcceptor
UNOTYPEINFO
-
Constructor Summary
ConstructorsConstructorDescriptionAcceptor
(com.sun.star.lang.XMultiServiceFactory serviceFactory) Constructs a newAcceptor
that uses the given service factory to create a specificXAcceptor
. -
Method Summary
Modifier and TypeMethodDescriptionstatic com.sun.star.lang.XSingleServiceFactory
__getServiceFactory
(String implName, com.sun.star.lang.XMultiServiceFactory multiFactory, com.sun.star.registry.XRegistryKey regKey) Returns a factory for creating the service.com.sun.star.connection.XConnection
Accepts a connection request via the given connection type.void
-
Field Details
-
__serviceName
The name of the service.The
JavaLoader
accesses this through reflection.- See Also:
-
-
Constructor Details
-
Acceptor
public Acceptor(com.sun.star.lang.XMultiServiceFactory serviceFactory) Constructs a newAcceptor
that uses the given service factory to create a specificXAcceptor
.- Parameters:
serviceFactory
- the service factory to use.
-
-
Method Details
-
__getServiceFactory
public static com.sun.star.lang.XSingleServiceFactory __getServiceFactory(String implName, com.sun.star.lang.XMultiServiceFactory multiFactory, com.sun.star.registry.XRegistryKey regKey) Returns a factory for creating the service.This method is called by the
JavaLoader
.- Parameters:
implName
- the name of the implementation for which a service is requested.multiFactory
- the service manager to be used (if needed).regKey
- the registry key.- Returns:
- an
XSingleServiceFactory
for creating the component. - See Also:
-
accept
public com.sun.star.connection.XConnection accept(String connectionDescription) throws com.sun.star.connection.AlreadyAcceptingException, com.sun.star.connection.ConnectionSetupException, com.sun.star.lang.IllegalArgumentException Accepts a connection request via the given connection type.This call blocks until a connection has been established.
The connection description has the following format:
type
*(key=value
). The specificXAcceptor
implementation is instantiated through the service factory ascom.sun.star.connection.typeAcceptor
(withtype
in lower case).- Specified by:
accept
in interfacecom.sun.star.connection.XAcceptor
- Parameters:
connectionDescription
- the description of the connection.- Returns:
- an
XConnection
to the client. - Throws:
com.sun.star.connection.AlreadyAcceptingException
com.sun.star.connection.ConnectionSetupException
com.sun.star.lang.IllegalArgumentException
- See Also:
-
XConnection
XConnector
-
stopAccepting
public void stopAccepting()- Specified by:
stopAccepting
in interfacecom.sun.star.connection.XAcceptor
- See Also:
-
XAcceptor.stopAccepting()
-