public class ChannelBase extends Object
| Modifier and Type | Field and Description |
|---|---|
protected Middleware |
afterAction |
protected Middleware |
beforeAction |
protected Channel |
channel |
protected ConcurrentHashMap<String,ChannelAction> |
channelActionMap |
protected Middleware |
defaultAction |
protected Middleware |
onError |
protected org.json.JSONObject |
providerIdentity |
| Constructor and Description |
|---|
ChannelBase(Channel channel,
org.json.JSONObject providerIdentity) |
| Modifier and Type | Method and Description |
|---|---|
void |
dispatch(org.json.JSONObject destinationIdentity,
String action,
org.json.JSONObject actionPayload,
AckListener ackListener) |
String |
getChannelId() |
String |
getChannelName() |
String |
getName() |
String |
getUuid() |
boolean |
hasRegisteredAction(String action) |
org.json.JSONObject |
invokeAction(String action,
org.json.JSONObject payload,
org.json.JSONObject senderIdentity) |
boolean |
register(String action,
ChannelAction listener) |
boolean |
remove(String action) |
void |
setAfterAction(Middleware middleware) |
void |
setBeforeAction(Middleware middleware) |
void |
setDefaultAction(Middleware middleware) |
void |
setOnError(Middleware middleware) |
protected Middleware defaultAction
protected Middleware onError
protected Middleware beforeAction
protected Middleware afterAction
protected ConcurrentHashMap<String,ChannelAction> channelActionMap
protected Channel channel
protected org.json.JSONObject providerIdentity
public ChannelBase(Channel channel, org.json.JSONObject providerIdentity)
public boolean register(String action, ChannelAction listener)
public boolean remove(String action)
public void setDefaultAction(Middleware middleware)
public void setOnError(Middleware middleware)
public void setBeforeAction(Middleware middleware)
public void setAfterAction(Middleware middleware)
public String getChannelName()
public String getUuid()
public String getChannelId()
public String getName()
public boolean hasRegisteredAction(String action)
public void dispatch(org.json.JSONObject destinationIdentity,
String action,
org.json.JSONObject actionPayload,
AckListener ackListener)
public org.json.JSONObject invokeAction(String action, org.json.JSONObject payload, org.json.JSONObject senderIdentity)
Copyright © 2019. All rights reserved.