com.sun.grizzly.cometd.bayeux
Class VerbBase
java.lang.Object
com.sun.grizzly.cometd.bayeux.VerbBase
- All Implemented Interfaces:
- Verb
- Direct Known Subclasses:
- Advice, Connect, Data, DeliverResponse, Ext, HandshakeRequest, HandshakeResponse, Ping, Publish, Status, Subscribe
public abstract class VerbBase
- extends java.lang.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 class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.sun.grizzly.cometd.bayeux.Verb |
toJSON |
id
protected java.lang.String id
dataId
protected java.lang.String dataId
advice
protected Advice advice
channel
protected java.lang.String channel
data
protected Data data
type
protected Verb.Type type
authToken
protected java.lang.String authToken
successful
protected java.lang.Boolean successful
error
protected java.lang.String error
ext
protected Ext ext
first
protected boolean first
follow
protected boolean follow
last
protected boolean last
clientId
protected java.lang.String clientId
metaChannel
protected java.lang.String metaChannel
VerbBase
public VerbBase()
getChannel
public java.lang.String getChannel()
setChannel
public void setChannel(java.lang.String channel)
getAuthToken
public java.lang.String getAuthToken()
setAuthToken
public void setAuthToken(java.lang.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 java.lang.String toString()
- Overrides:
toString in class java.lang.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(java.lang.String id)
getId
public java.lang.String getId()
setData
public void setData(Data data)
getData
public Data getData()
getDataId
public java.lang.String getDataId()
setDataId
public void setDataId(java.lang.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 java.lang.String getJSONPrefix()
getJSONPostfix
protected java.lang.String getJSONPostfix()
getClientId
public java.lang.String getClientId()
setClientId
public void setClientId(java.lang.String clientId)
getMetaChannel
public java.lang.String getMetaChannel()
- To be overriden by subclass used in isValid().
Copyright © 2005-2011 Oracle Corporation. All Rights Reserved.