Package org.restlet.util
Class ServerList
Modifiable list of server connectors.
- Author:
- Jerome Louvel
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdds a new server connector in the map supporting the given protocol.Adds a new server connector in the map supporting the given protocol on the specified port.Adds a new server connector in the map supporting the given protocol on the specified IP address and port.booleanAdds a server at the end of the list.Returns the context.getNext()Returns the next Restlet.voidsetContext(Context context) Sets the context.voidSets the next Restlet.Methods inherited from class org.restlet.util.WrapperList
add, addAll, addAll, clear, contains, containsAll, equals, get, getDelegate, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
replaceAll, sort, spliterator
-
Constructor Details
-
ServerList
Constructor.- Parameters:
context- The context.next- The next Restlet of added servers.
-
-
Method Details
-
add
Adds a new server connector in the map supporting the given protocol.- Parameters:
protocol- The connector protocol.- Returns:
- The added server.
-
add
Adds a new server connector in the map supporting the given protocol on the specified port.- Parameters:
protocol- The connector protocol.port- The listening port.- Returns:
- The added server.
-
add
Adds a new server connector in the map supporting the given protocol on the specified IP address and port.- Parameters:
protocol- The connector protocol.address- The optional listening IP address (useful if multiple IP addresses available).port- The listening port.- Returns:
- The added server.
-
add
Adds a server at the end of the list.- Specified by:
addin interfaceCollection<Server>- Specified by:
addin interfaceList<Server>- Overrides:
addin classWrapperList<Server>- Returns:
- True (as per the general contract of the Collection.add method).
-
getContext
Returns the context.- Returns:
- The context.
-
getNext
Returns the next Restlet.- Returns:
- The next Restlet.
-
setContext
Sets the context.- Parameters:
context- The context.
-
setNext
Sets the next Restlet.- Parameters:
next- The next Restlet.
-