JACK 5.4 Application Interface

aos.jack.jak.agent
Class Capability

java.lang.Object
  extended byaos.jack.jak.agent.Capability
Direct Known Subclasses:
DefaultTeamStarting, ModelManaging, SimulationTiming, TimeDispatching, TimeStepping

public abstract class Capability
extends java.lang.Object

This is the base class for JACK Capability types.


Constructor Summary
Capability()
          Constructor.
 
Method Summary
protected  void autorun()
          Can be overridden in order to provide some initialisation when the capability is actually brought into being.
 Agent getAgent()
          Returns the enclosing agent.
 boolean isEnabled()
          Returns true if this capability is enabled.
 void postEvent(Event e)
          Posts an event.
 void setEnabled(boolean t)
          Sets whether this capability is enabled.
 java.lang.String toString()
          Returns the runtime name of the capability instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Capability

public Capability()
Constructor. Not generally used.

Method Detail

isEnabled

public boolean isEnabled()
Returns true if this capability is enabled.


setEnabled

public void setEnabled(boolean t)
Sets whether this capability is enabled. This needs to be overidden for capabilities with nested capabilities and needs to propagate the call to its subcapabilities.


autorun

protected void autorun()
Can be overridden in order to provide some initialisation when the capability is actually brought into being.


getAgent

public Agent getAgent()
Returns the enclosing agent.


toString

public java.lang.String toString()
Returns the runtime name of the capability instance. This name consists of the enclosing agent's name(), followed by the member path down to this capability instance (using ":" as separator).


postEvent

public void postEvent(Event e)
Posts an event. This is a convenience method which merely invokes getAgent().postEvent(e).


JACK 5.4 Application Interface

Copyright (C) 1999-2008, Agent Oriented Software Pty. Ltd.

US Government Restricted Rights
The JACK Modules and relevant Software Material have been developed entirely at private expense and are accordingly provided with RESTRICTED RIGHTS. Use, duplication, or disclosure by Government is subject to restrictions as set forth in subparagraph (c)(1)(ii) of DFARS 252.227-7013 or subparagraph (c)(1) and (2) of the Commercial Computer Software Restricted Rights and 48 CFR 52.2270-19, as applicable.


Agent Oriented Software Pty. Ltd.     http://www.aosgrp.com
PO Box 639, Carlton South, Victoria 3053, Australia
Phone: +61 3 9349 5055, Fax: +61 3 9349 5088