com.sun.jini.discovery.kerberos
Class Server
java.lang.Object
com.sun.jini.discovery.kerberos.Server
- All Implemented Interfaces:
- DiscoveryFormatProvider, UnicastDiscoveryServer
public class Server
- extends Object
- implements UnicastDiscoveryServer
Implements the server side of the net.jini.discovery.kerberos
unicast discovery format.
- Since:
- 2.0
- Author:
- Sun Microsystems, Inc.
Constructor Summary |
Server()
Creates a new instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
impl
private final Server.ServerImpl impl
Server
public Server()
- Creates a new instance.
getFormatName
public String getFormatName()
- Description copied from interface:
DiscoveryFormatProvider
- Returns the name of the format implemented by this provider.
- Specified by:
getFormatName
in interface DiscoveryFormatProvider
- Returns:
- the name of the format implemented by this provider
checkUnicastDiscoveryConstraints
public void checkUnicastDiscoveryConstraints(InvocationConstraints constraints)
throws UnsupportedConstraintException
- Description copied from interface:
UnicastDiscoveryServer
- Checks and returns normally if this server is capable of fulfilling the
given absolute constraints.
null
constraints are
considered equivalent to empty constraints.
- Specified by:
checkUnicastDiscoveryConstraints
in interface UnicastDiscoveryServer
- Parameters:
constraints
- the constraints to check, or null
- Throws:
UnsupportedConstraintException
- if unable to satisfy the
specified constraints
handleUnicastDiscovery
public void handleUnicastDiscovery(UnicastResponse response,
Socket socket,
InvocationConstraints constraints,
ClientSubjectChecker checker,
Collection context,
ByteBuffer received,
ByteBuffer sent)
throws IOException
- Description copied from interface:
UnicastDiscoveryServer
- Handles the server side of unicast discovery, transmitting the given
response data over the provided socket using the given collection of
object stream context objects in a manner that satisfies the specified
absolute constraints and client subject checker (if any). Byte buffers
containing the data received and sent so far over the given socket (for
the unicast discovery protocol 2 handshake) are provided for use by
formats which integrity protect or otherwise incorporate the handshake
data.
null
constraints are considered equivalent to empty
constraints.
- Specified by:
handleUnicastDiscovery
in interface UnicastDiscoveryServer
- Parameters:
response
- the unicast response data to transmitsocket
- the socket on which to handle unicast discoveryconstraints
- the constraints to apply to unicast discovery, or
null
checker
- the object to use to check the client subject, or
null
context
- the collection of context information objects to use when
marshalling the registrar proxyreceived
- a buffer containing the data already receivedsent
- a buffer containing the data already sent
- Throws:
IOException
- if an error occurs in interpreting received data or
in formatting data to send
UnsupportedConstraintException
- if unable to satisfy the
specified constraints
Copyright 2007-2010, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.