Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.javahispano.canyamo.core.command
Class AbstractCommand  view AbstractCommand download AbstractCommand.java

java.lang.Object
  extended byorg.javahispano.canyamo.core.command.AbstractCommand
All Implemented Interfaces:
org.javahispano.canyamo.core.action.ActionListener, Command

public abstract class AbstractCommand
extends java.lang.Object
implements Command

Description of the Class


Field Summary
protected  org.javahispano.canyamo.core.application.Application app
          Description of the Field
protected  java.lang.String name
          Description of the Field
 
Constructor Summary
AbstractCommand()
           
 
Method Summary
 void addProperty(java.lang.String name, java.lang.String value)
          Adds a feature to the Property attribute of the AbstractDisplayer object
protected  void debug(java.lang.String message)
          Logs a message in log tool only if in "debug mode"

This mode can be set in CanyamoLog

TO DO
Actually this "debug mode" is hard-coded, it should be usefull to make it configurable
protected  void error(java.lang.String message)
          Logs a message in log tool with "error" priority
 org.javahispano.canyamo.core.application.Application getApplication()
          Gets the Application to which this displayer belong to
 java.lang.String getDescription()
          Returns a description of this command
 java.lang.String getName()
          Returns the name of this command
 void init()
          Initialites this command
protected  void log(java.lang.String message)
          Logs a message in log tool with "normal" priority
abstract  void run()
          Main processing method for the AbstractCommand object
 void setApplication(org.javahispano.canyamo.core.application.Application app)
          Sets the Application to which this displayer belong to
 void setName(java.lang.String name)
          Sets the name of this command
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

app

protected org.javahispano.canyamo.core.application.Application app
Description of the Field


name

protected java.lang.String name
Description of the Field

Constructor Detail

AbstractCommand

public AbstractCommand()
Method Detail

setName

public void setName(java.lang.String name)
Sets the name of this command

Specified by:
setName in interface Command

setApplication

public void setApplication(org.javahispano.canyamo.core.application.Application app)
Sets the Application to which this displayer belong to

Specified by:
setApplication in interface Command

getName

public java.lang.String getName()
Returns the name of this command

Specified by:
getName in interface Command

getDescription

public java.lang.String getDescription()
Returns a description of this command

Specified by:
getDescription in interface Command

getApplication

public org.javahispano.canyamo.core.application.Application getApplication()
Gets the Application to which this displayer belong to

Specified by:
getApplication in interface Command

init

public void init()
Initialites this command

Specified by:
init in interface Command

run

public abstract void run()
Main processing method for the AbstractCommand object

Specified by:
run in interface org.javahispano.canyamo.core.action.ActionListener

addProperty

public void addProperty(java.lang.String name,
                        java.lang.String value)
Adds a feature to the Property attribute of the AbstractDisplayer object

Specified by:
addProperty in interface Command
Since:

log

protected void log(java.lang.String message)
Logs a message in log tool with "normal" priority


error

protected void error(java.lang.String message)
Logs a message in log tool with "error" priority


debug

protected void debug(java.lang.String message)
Logs a message in log tool only if in "debug mode"

This mode can be set in CanyamoLog

TO DO
Actually this "debug mode" is hard-coded, it should be usefull to make it configurable