- 
- All Superinterfaces:
- java.lang.AutoCloseable,- java.io.Closeable
 - Enclosing class:
- Network
 
 public static interface Network.Server extends java.io.CloseableThis class represents a listening server connection ready to accept clients.The onAccept()callback will be called for each new accepted connection.Once and if the listening connection is closed, the onClose()callback will be called.You may call the Closeable.close()method to close the connection yourself.
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanisSecure()Returns whether or not future accepted connections will be secure (typically using TLS or some other encryption mechanism)Callback<Network.Connection,Network.Server>onAccept()Gets the callback object that will be called with newly established connectionsCallback<java.lang.Void,Network.Server>onClose()Gets the callback object that will be called once the connection is closed.
 
- 
- 
- 
Method Detail- 
onAcceptCallback<Network.Connection,Network.Server> onAccept() Gets the callback object that will be called with newly established connections- Returns:
- the onAccept callback
 
 - 
onCloseCallback<java.lang.Void,Network.Server> onClose() Gets the callback object that will be called once the connection is closed.- Returns:
- the onClose callback
 
 - 
isSecureboolean isSecure() Returns whether or not future accepted connections will be secure (typically using TLS or some other encryption mechanism)- Returns:
- whether or not future accepted connections will be secure
 
 
- 
 
-