|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.mucommander.ui.action.ActionDescriptor
public class ActionDescriptor
A descriptor class for MuAction instances. An ActionDescriptor is the combination of a MuAction
class (a class extending MuAction and following its conventions) and a set of properties used for instanciation.
Thus, it not only identifies an action class but also the way it is instanciated.
Two ActionDescriptor instances are equal only if:
This class is used by ActionManager to instance MuAction and allow several instances to live in memory only if they have different initialization properties, which translated into action speak means a different appearance and/or behavior.
ActionManager,
MuAction| Constructor Summary | |
|---|---|
ActionDescriptor(java.lang.Class actionClass)
Convenience constructor which has the same effect as calling ActionDescriptor(Class, Hashtable)
with a null value for the properties parameter. |
|
ActionDescriptor(java.lang.Class muActionClass,
java.util.Hashtable initProperties)
Creates a new ActionDescriptor which identifies the specified combination of MuAction class and initialization properties. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object o)
Returns true if the given object is an ActionDescriptor that is equal to this one. |
java.lang.Class |
getActionClass()
Returns a Class instance referring to a class that extends MuAction. |
java.util.Hashtable |
getInitProperties()
Returns the list of properties that are to be used to instanciate the MuAction class, or null if
there are none. |
int |
hashCode()
Returns a hash code value for this ActionDescriptor, making this class suitable for use as a key in a Hashtable. |
java.lang.String |
toString()
Returns a String representation of this ActionDescriptor. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ActionDescriptor(java.lang.Class actionClass)
ActionDescriptor(Class, Hashtable)
with a null value for the properties parameter.
actionClass - a MuAction Class descriptor
public ActionDescriptor(java.lang.Class muActionClass,
java.util.Hashtable initProperties)
properties parameter may be null if the action class is to be
instanciated without any initialization properties.
The specified Class *must* denote a class that extends MuAction and follows its conventions
(provide the proper constructor), otherwise ActionManager will fail to instanciate it. However,
ActionDescriptor does not check if the specified Class is valid or not.
muActionClass - a MuAction Class descriptorinitProperties - a Hashtable containing the properties that will be used to instanciate the specified MuAction class| Method Detail |
|---|
public java.lang.Class getActionClass()
public java.util.Hashtable getInitProperties()
null if
there are none.
public boolean equals(java.lang.Object o)
true if the given object is an ActionDescriptor that is equal to this one.
ActionDescriptor instances are considered equal if they refer to the same MuAction class and
set of initialization properties.
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
This file is part of muCommander - Copyright (C) 2002-2008 Maxence Bernard