Package org.glassfish.kernel.embedded
Class PortsImpl
- java.lang.Object
-
- org.glassfish.kernel.embedded.PortsImpl
-
-
Constructor Summary
Constructors Constructor Description PortsImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Port
createPort(int number)
Creates a port, binds it to a port number and returns itCollection<Port>
getPorts()
Returns the list of allocated portsvoid
remove(Port port)
-
-
-
Method Detail
-
createPort
public Port createPort(int number) throws IOException
Description copied from interface:Ports
Creates a port, binds it to a port number and returns it- Specified by:
createPort
in interfacePorts
- Parameters:
number
- the port number- Returns:
- the bound port to the port number
- Throws:
IOException
- if the port is already taken or another network exception occurs
-
getPorts
public Collection<Port> getPorts()
Description copied from interface:Ports
Returns the list of allocated ports
-
remove
public void remove(Port port)
-
-