public class ServerPortRegistry extends Object
ServerPort
object and register it with ServerPortRegistry.addPort
.
The physical port number can then be assigned with ServerPort#assignPort()
.Modifier and Type | Method and Description |
---|---|
static void |
addPort(ServerPort serverPort)
Add a port to the Server's port registry.
|
static void |
addService(Service service)
Adds a
ServicePortService to the ServerPortRegistry . |
static void |
clear()
Clear the service port registry.
|
static ServerPort |
getPort(String portId)
Returns the
ServerPort associated with the given portId or null, none exist. |
static Set<ServerPort> |
getPorts()
Returns all registered
ServerPort s. |
static Service |
getService(String serviceName)
Returns the
Service associated with the given service name or null, if none exist. |
static Set<Service> |
getServices()
Returns all registered
Service s. |
static void |
removePort(ServerPort serverPort)
Removes a port from the ServerPortRegistry and any Service it belongs to.
|
public static void addPort(ServerPort serverPort)
serverPort
- public static void addService(Service service)
ServicePortService
to the ServerPortRegistry
. ServerPorts can be grouped by
Serviceservice
- The Service to register. Once registered, ServerPorts can be associated with this
Service.public static void removePort(ServerPort serverPort)
serverPort
- public static void clear()
public static Service getService(String serviceName)
Service
associated with the given service name or null, if none exist.serviceName
- The service name.public static ServerPort getPort(String portId)
ServerPort
associated with the given portId or null, none exist.portId
- The id of the server port.public static Set<ServerPort> getPorts()
ServerPort
s.Copyright © 2021 Hitachi Vantara. All rights reserved.