public interface Muxer<T>
Modifier and Type | Method and Description |
---|---|
void |
add(short id,
T handler)
Registers the specified handler to handle messages containing a mux header with the specified mux identifier.
|
T |
get(short id)
Gets the handler registered under the specified id
|
T |
getDefaultHandler()
Gets the handler for messages that have no mux header.
|
void |
remove(short id)
Unregisters the handler associated with the specifed mux identifier
|
void |
setDefaultHandler(T handler)
Sets the handler for messages that have no mux header.
|
void add(short id, T handler)
id
- a mux idhandler
- a handler for the specified idT get(short id)
id
- a mux idnull
if no handler is registered under
id
void remove(short id)
id
- a mux idT getDefaultHandler()
null
if no default handler
has been setvoid setDefaultHandler(T handler)
handler
- a handler for messages that have no mux headerCopyright © 1998-2020 Red Hat. All Rights Reserved.