org.opencyc.conversation
Class Performative

java.lang.Object
  |
  +--org.opencyc.conversation.Performative
All Implemented Interfaces:
java.lang.Comparable

public class Performative
extends java.lang.Object
implements java.lang.Comparable

Contains the attributes and behavior of a chat conversation Finite State Machine Performative.

Author:
Stephen L. Reed

Copyright 2001 Cycorp, Inc., license is open source GNU LGPL.

the license

www.opencyc.org

OpenCyc at SourceForge

THIS SOFTWARE AND KNOWLEDGE BASE CONTENT ARE PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OPENCYC ORGANIZATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE AND KNOWLEDGE BASE CONTENT, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


Field Summary
protected  java.lang.Object content
          optional content
protected  java.lang.String performativeName
          performative name
 
Constructor Summary
Performative(java.lang.String performativeName)
          Constructs a new Performative object given its name.
Performative(java.lang.String performativeName, java.lang.Object content)
          Constructs a new Performative object given its name and content
 
Method Summary
 int compareTo(java.lang.Object object)
          Compares this object with the specified object for order.
 boolean equals(java.lang.Object object)
          Returns true iff some object equals this object
 java.lang.Object getContent()
          Returns the performative content.
 java.lang.String getPerformativeName()
          Returns the performative name.
 void setContent(java.lang.Object content)
          Sets the performative content.
 java.lang.String toString()
          Returns the string representation of this perfomative
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

performativeName

protected java.lang.String performativeName
performative name

content

protected java.lang.Object content
optional content
Constructor Detail

Performative

public Performative(java.lang.String performativeName)
Constructs a new Performative object given its name.
Parameters:
performativeName - the performative name

Performative

public Performative(java.lang.String performativeName,
                    java.lang.Object content)
Constructs a new Performative object given its name and content
Parameters:
performativeName - the performative name
content - the content
Method Detail

getPerformativeName

public java.lang.String getPerformativeName()
Returns the performative name.
Returns:
the performative name

setContent

public void setContent(java.lang.Object content)
Sets the performative content.
Parameters:
the - performative content

getContent

public java.lang.Object getContent()
Returns the performative content.
Returns:
the performative content

compareTo

public int compareTo(java.lang.Object object)
Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
Specified by:
compareTo in interface java.lang.Comparable
Parameters:
object - the reference object with which to compare.
Returns:
a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object

equals

public boolean equals(java.lang.Object object)
Returns true iff some object equals this object
Overrides:
equals in class java.lang.Object
Parameters:
object - the Object for equality comparison
Returns:
equals boolean value indicating equality or non-equality.

toString

public java.lang.String toString()
Returns the string representation of this perfomative
Overrides:
toString in class java.lang.Object
Returns:
the representation of the Template as a String