public final class ServerStreamFeaturesManager
extends java.lang.Object
Negotiates stream features from a server perspective.
Each feature which shall be advertised during stream negotiation, must be registered first.
ServerStreamFeatureNegotiator| Constructor and Description |
|---|
ServerStreamFeaturesManager() |
| Modifier and Type | Method and Description |
|---|---|
java.util.Collection<StreamFeature> |
getStreamFeatures()
Gets the stream features which shall be advertised.
|
StreamNegotiationResult |
handleElement(StreamElement element)
Handles an inbound element and tries to find a negotiator which feels responsible to negotiate the element.
|
void |
registerStreamFeatureNegotiator(ServerStreamFeatureNegotiator<? extends StreamFeature> streamFeaturesNegotiator)
Registers a stream features negotiator.
|
public final void registerStreamFeatureNegotiator(ServerStreamFeatureNegotiator<? extends StreamFeature> streamFeaturesNegotiator)
Registers a stream features negotiator.
streamFeaturesNegotiator - The negotiator.public final java.util.Collection<StreamFeature> getStreamFeatures()
Gets the stream features which shall be advertised. Different stream features may be advertised during different phases of the stream negotiation. E.g. the first and only feature should be STARTTLS, then SASL and only then Resource Binding.
public final StreamNegotiationResult handleElement(StreamElement element)
Handles an inbound element and tries to find a negotiator which feels responsible to negotiate the element.
element - The stream element.StreamNegotiationResult.IGNORECopyright © 2014–2019 XMPP.rocks. All rights reserved.