fi.helsinki.dacopan.model
Class VariableDefinition

java.lang.Object
  extended by fi.helsinki.dacopan.model.VariableDefinition

public class VariableDefinition
extends java.lang.Object

Definition of a dynamic variable associated with a protocol, whose value can change from one unit to another. Each variable is categorized to a specific scope.

Version:
$Id: VariableDefinition.java,v 1.12 2004/05/11 09:21:05 aarniala-dacopan Exp $
See Also:
StaticVariable

Nested Class Summary
static class VariableDefinition.Scope
          The scope of a variable.
 
Field Summary
static VariableDefinition.Scope FLOW
          scope of a flow -specific variable (e.g.
protected  java.lang.String name
          name of the variable
protected  Protocol protocol
          the protocol that this variables is associated with
protected  VariableDefinition.Scope scope
          scope of the variable
static VariableDefinition.Scope UNIT
          scope of a unit -specific variable (e.g. transition time)
static VariableDefinition.Scope UNIT_FIELD
          scope of a protocol field (e.g.
 
Constructor Summary
VariableDefinition(java.lang.String name, VariableDefinition.Scope scope, Protocol protocol)
          Creates a new variable definition with the given name, scope and protocol.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 java.lang.String getFullName()
           
 java.lang.String getName()
           
 Protocol getProtocol()
           
 java.lang.String getRawName()
          Returns the non-localized name of the variable.
 VariableDefinition.Scope getScope()
           
 int hashCode()
           
 boolean isFlowVariable()
           
 boolean isProtocolField()
           
 boolean isUnitVariable()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

UNIT

public static final VariableDefinition.Scope UNIT
scope of a unit -specific variable (e.g. transition time)


UNIT_FIELD

public static final VariableDefinition.Scope UNIT_FIELD
scope of a protocol field (e.g. TCP sequence number)


FLOW

public static final VariableDefinition.Scope FLOW
scope of a flow -specific variable (e.g. TCP state)


name

protected java.lang.String name
name of the variable


scope

protected VariableDefinition.Scope scope
scope of the variable


protocol

protected Protocol protocol
the protocol that this variables is associated with

Constructor Detail

VariableDefinition

public VariableDefinition(java.lang.String name,
                          VariableDefinition.Scope scope,
                          Protocol protocol)
Creates a new variable definition with the given name, scope and protocol.

Method Detail

getRawName

public java.lang.String getRawName()
Returns the non-localized name of the variable.


getName

public java.lang.String getName()

getFullName

public java.lang.String getFullName()

getScope

public VariableDefinition.Scope getScope()

getProtocol

public Protocol getProtocol()

isUnitVariable

public boolean isUnitVariable()

isFlowVariable

public boolean isFlowVariable()

isProtocolField

public boolean isProtocolField()

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


© Dacopan2 team, 2005-