Component

public abstract class Component

Component represents a module component. Subclasses should override the init() method for their own initializations.

Author:Hugo Y. K. Lam

See also: Module

Methods

getId

public String getId()

Gets the component ID.

Returns:the component ID.

getModule

public Module getModule()

Gets the parent module of this component.

Returns:the parent module of this component.

getName

public String getName()

Gets the name of this component.

Returns:the name of this component.

getParameters

public Properties getParameters()

Gets the parameters of this component.

Returns:the parameters of this component.

init

protected void init()

Invoked for initialization.

Throws:
  • Exception – if there is any error in the initialization.

setId

public void setId(String id)

Sets the component ID.

Parameters:
  • id – the component ID.

setModule

protected void setModule(Module module)

Sets the parent module of this component.

Parameters:
  • module – the parent module of this component.

setName

protected void setName(String name)

Sets the name of this component.

Parameters:
  • name – the name of this component.

setParameters

protected void setParameters(Properties parameters)

Sets the parameters of this component.

Parameters:
  • parameters – the parameters of this component.