info.magnolia.commands
Class CommandsManager

java.lang.Object
  extended by info.magnolia.cms.beans.config.ObservedManager
      extended by info.magnolia.commands.CommandsManager

@Singleton
public class CommandsManager
extends ObservedManager

Manages the Commands and Catalogs.

Version:
$Revision$ ($Author$)
Author:
Philipp Bracher

Field Summary
static String COMMAND_DELIM
           
static String DEFAULT_CATALOG
           
 
Fields inherited from class info.magnolia.cms.beans.config.ObservedManager
log, registeredUUIDs
 
Constructor Summary
CommandsManager()
           
 
Method Summary
 org.apache.commons.chain.Command getCommand(String commandName)
          Use a delimiter to separate the catalog and command name.
 org.apache.commons.chain.Command getCommand(String catalogName, String commandName)
          Get the command.
static CommandsManager getInstance()
          Deprecated. since 4.5, use IoC !
protected  void onClear()
          Clear all catalogs.
protected  void onRegister(Content node)
          Register observation for command catalogs.
protected  void registerCatalog(Content node)
           
 
Methods inherited from class info.magnolia.cms.beans.config.ObservedManager
clear, getNodeByIdentifierOrPath, register, reload, reload
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_CATALOG

public static final String DEFAULT_CATALOG
See Also:
Constant Field Values

COMMAND_DELIM

public static final String COMMAND_DELIM
See Also:
Constant Field Values
Constructor Detail

CommandsManager

public CommandsManager()
Method Detail

onRegister

protected void onRegister(Content node)
Register observation for command catalogs.

Specified by:
onRegister in class ObservedManager

registerCatalog

protected void registerCatalog(Content node)

onClear

protected void onClear()
Clear all catalogs.

Specified by:
onClear in class ObservedManager

getCommand

public org.apache.commons.chain.Command getCommand(String catalogName,
                                                   String commandName)
Get the command.

Parameters:
catalogName - the catalog containing the command
commandName - the name of the command
Returns:
the command to execute

getCommand

public org.apache.commons.chain.Command getCommand(String commandName)
Use a delimiter to separate the catalog and command name.

Parameters:
commandName -
Returns:
the command

getInstance

public static CommandsManager getInstance()
Deprecated. since 4.5, use IoC !

Returns:
Returns the instance.


Copyright © 2003–2014 Magnolia International Ltd.. All rights reserved.