Class Tool
- java.lang.Object
-
- org.silverpeas.core.admin.component.model.AbstractSilverpeasComponent
-
- org.silverpeas.core.admin.component.model.Tool
-
- All Implemented Interfaces:
SilverpeasComponent
public class Tool extends AbstractSilverpeasComponent
A tool represents an application that is available in Silverpeas personal space.
The tools available in Silverpeas are loaded by the
org.silverpeas.core.admin.component .ToolRegistry
registry. They can be the accessed either by the registry itself or by the Tool class (it delegates the access to the registry).
-
-
Field Summary
Fields Modifier and Type Field Description protected String
id
-
Fields inherited from class org.silverpeas.core.admin.component.model.AbstractSilverpeasComponent
indexedParametersByName
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Collection<Tool>
getAll()
Gets all the available Tool instances.static Optional<Tool>
getById(String toolId)
Gets the Tool instance with the specified id.Map<String,String>
getDescription()
Gets the value of the description property.List<GroupOfParameters>
getGroupsOfParameters()
Gets groups of parameters.Map<String,String>
getLabel()
Gets the value of the label property.String
getName()
Gets the type of the component.List<Parameter>
getParameters()
Gets the value of the parameters property.List<GroupOfParameters>
getSortedGroupsOfParameters()
List<Parameter>
getSortedParameters()
Gets same parameters asSilverpeasComponent.getParameters()
, sorted by order and name.boolean
hasParameterDefined(String parameterName)
Indicates if a parameter is defined which name is equal to the given method parameter.boolean
isPersonal()
Indicates if the component instance is a personal one.
A personal component instance is linked to a user.boolean
isVisible()
Gets the value of the visible property.-
Methods inherited from class org.silverpeas.core.admin.component.model.AbstractSilverpeasComponent
getIndexedParametersByName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.silverpeas.core.admin.component.model.SilverpeasComponent
getAllParameters, getDescription, getLabel, isTopicTracker, isWorkflow
-
-
-
-
Field Detail
-
id
protected final String id
-
-
Constructor Detail
-
Tool
public Tool(String id)
-
-
Method Detail
-
getById
public static Optional<Tool> getById(String toolId)
Gets the Tool instance with the specified id.- Parameters:
toolId
- the unique id (or unique id) of the Tool to return.- Returns:
- optionally a Tool instance with the given id.
-
getAll
public static Collection<Tool> getAll()
Gets all the available Tool instances.- Returns:
- a collection of Tool instance.
-
getName
public String getName()
Description copied from interface:SilverpeasComponent
Gets the type of the component.- Returns:
- the application name.
-
getLabel
public Map<String,String> getLabel()
Description copied from interface:SilverpeasComponent
Gets the value of the label property.- Returns:
- possible object is
Multilang
-
isVisible
public boolean isVisible()
Description copied from interface:SilverpeasComponent
Gets the value of the visible property.
-
isPersonal
public boolean isPersonal()
Description copied from interface:SilverpeasComponent
Indicates if the component instance is a personal one.
A personal component instance is linked to a user.- Returns:
- true if it is a personal one, false otherwise.
-
getDescription
public Map<String,String> getDescription()
Description copied from interface:SilverpeasComponent
Gets the value of the description property.- Returns:
- possible object is
Multilang
-
getParameters
public List<Parameter> getParameters()
Description copied from interface:SilverpeasComponent
Gets the value of the parameters property.- Returns:
- list of
Parameter
-
hasParameterDefined
public boolean hasParameterDefined(String parameterName)
Description copied from interface:SilverpeasComponent
Indicates if a parameter is defined which name is equal to the given method parameter.- Parameters:
parameterName
- the parameter name to perform.- Returns:
- true if a parameter is defined behind the specified method parameter, false otherwise.
-
getSortedParameters
public List<Parameter> getSortedParameters()
Description copied from interface:SilverpeasComponent
Gets same parameters asSilverpeasComponent.getParameters()
, sorted by order and name.- Returns:
- sorted parameters.
-
getGroupsOfParameters
public List<GroupOfParameters> getGroupsOfParameters()
Description copied from interface:SilverpeasComponent
Gets groups of parameters.- Returns:
- the list of groups of parameters.
-
getSortedGroupsOfParameters
public List<GroupOfParameters> getSortedGroupsOfParameters()
-
-