Class ComponentsInfo
- java.lang.Object
-
- org.apache.sling.testing.clients.osgi.ComponentsInfo
-
public class ComponentsInfo extends java.lang.Object
Thin wrapper around the list of components
-
-
Constructor Summary
Constructors Constructor Description ComponentsInfo(org.codehaus.jackson.JsonNode rootNode)
The only constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ComponentInfo
forId(java.lang.String id)
ComponentInfo
forName(java.lang.String name)
ComponentInfo
forPid(java.lang.String pid)
int
getNumberOfInstalledComponents()
-
-
-
Constructor Detail
-
ComponentsInfo
public ComponentsInfo(org.codehaus.jackson.JsonNode rootNode) throws ClientException
The only constructor.- Parameters:
rootNode
- the root JSON node of the components info.- Throws:
ClientException
- if the info cannot be retrieved
-
-
Method Detail
-
getNumberOfInstalledComponents
public int getNumberOfInstalledComponents() throws ClientException
- Returns:
- the number of installed components
- Throws:
ClientException
- if the info cannot be retrieved
-
forId
public ComponentInfo forId(java.lang.String id) throws ClientException
- Parameters:
id
- the id of the component- Returns:
- the ComponentInfo for a component with the identifier
id
- Throws:
ClientException
- if the info cannot be retrieved
-
forName
public ComponentInfo forName(java.lang.String name) throws ClientException
- Parameters:
name
- the name of the component- Returns:
- the ComponentInfo for a component with the name
name
- Throws:
ClientException
- if the info cannot be retrieved
-
forPid
public ComponentInfo forPid(java.lang.String pid) throws ClientException
- Parameters:
pid
- the pid of the component- Returns:
- the ComponentInfo for a component with the pid
pid
- Throws:
ClientException
- if the info cannot be retrieved
-
-