com.sun.grizzly.cometd.bayeux
Class VerbBase
java.lang.Object
com.sun.grizzly.cometd.bayeux.VerbBase
- All Implemented Interfaces:
- Verb
- Direct Known Subclasses:
- Advice, ConnectRequest, ConnectResponse, Data, DeliverResponse, DisconnectRequest, DisconnectResponse, Ext, HandshakeRequest, HandshakeResponse, Ping, PublishRequest, PublishResponse, ReconnectRequest, ReconnectResponse, Status, SubscribeRequest, SubscribeResponse, UnsubscribeRequest, UnsubscribeResponse
public abstract class VerbBase
- extends Object
- implements Verb
Abstract Verb implementation shared by all meta channel verb.
All cometd /meta/ channel messages contain a protocol version number and all
messages generated from (or routed through) an event router contain a message
ID which is unique to the router. No randomness is required in these
identifiers although routers are expected to drop messages which they have
previously "seen".
- Author:
- Jeanfrancois Arcand
Nested classes/interfaces inherited from interface com.sun.grizzly.cometd.bayeux.Verb |
Verb.Type |
Methods inherited from interface com.sun.grizzly.cometd.bayeux.Verb |
toJSON |
id
protected String id
dataId
protected String dataId
advice
protected Advice advice
channel
protected String channel
data
protected Data data
type
protected Verb.Type type
authToken
protected String authToken
successful
protected Boolean successful
error
protected String error
ext
protected Ext ext
first
protected boolean first
follow
protected boolean follow
last
protected boolean last
VerbBase
public VerbBase()
getChannel
public String getChannel()
setChannel
public void setChannel(String channel)
getAuthToken
public String getAuthToken()
setAuthToken
public void setAuthToken(String autheToken)
getType
public Verb.Type getType()
- Description copied from interface:
Verb
- Return the Verb's type.
- Specified by:
getType
in interface Verb
getExt
public Ext getExt()
setExt
public void setExt(Ext ext)
toString
public String toString()
- Overrides:
toString
in class Object
getAdvice
public Advice getAdvice()
setAdvice
public void setAdvice(Advice advice)
hasValidAdvice
public boolean hasValidAdvice()
- Since advice is optional, null advice is valid.
setId
public void setId(String id)
getId
public String getId()
setData
public void setData(Data data)
getData
public Data getData()
getDataId
public String getDataId()
setDataId
public void setDataId(String dataId)
isFirst
public boolean isFirst()
setFirst
public void setFirst(boolean first)
isFollow
public boolean isFollow()
setFollow
public void setFollow(boolean follow)
isLast
public boolean isLast()
setLast
public void setLast(boolean last)
isValid
public boolean isValid()
- Description copied from interface:
Verb
- Check whether the Verb is valid.
- Specified by:
isValid
in interface Verb
getJSONPrefix
protected String getJSONPrefix()
getJSONPostfix
protected String getJSONPostfix()
Copyright © 2011 SUN Microsystems. All Rights Reserved.