org.ops4j.pax.coin.service.internal.target
Interface ConfigTarget

All Known Implementing Classes:
AbstractConfigTarget, ManagedServiceConfigTarget, ManagedServiceFactoryConfigTarget

public interface ConfigTarget

Abstracts a ManagedService/ManageServiceFactory.

Since:
0.3.0, March 03, 2008
Author:
Alin Dreghiciu

Method Summary
 void delete(String itemId)
          Removes a configuration item.
 String getGroupId()
          Configuration group identifier.
 String getLocation()
          Bundle location of the bundle that published the managed service / managed service factory.
 void update(String itemId, Map<String,Object> properties)
          Updates managed service configuration properties.
If the targeted service is a managed service the item id must be equal with group id (so equal with the pid).
 

Method Detail

getGroupId

String getGroupId()
Configuration group identifier. Cannot be null.
/ If the configuration target is a managed service, the id must be equal with the persistent identifier (pid) of targeted managed service.
If the configuration target is a managed service factory, the id must be equal with the factory persistent identifier (factory pid) of targeted managed service factory.

Returns:
identifier

getLocation

String getLocation()
Bundle location of the bundle that published the managed service / managed service factory. Canot be null.

Returns:
bundle location

update

void update(String itemId,
            Map<String,Object> properties)
Updates managed service configuration properties.
If the targeted service is a managed service the item id must be equal with group id (so equal with the pid).
If the targeted service is a managed service factory the item id must be equal with the pid of the configuration to be updated.

Parameters:
itemId - configuration item id; cannot be null
properties - configuration properties; cannot be null
Throws:
IllegalArgumentException - - If item id is null or empty - If properties is null

delete

void delete(String itemId)
Removes a configuration item. If the targeted service is a managed service the item id must be equal with group id (so equal with the pid).
If the targeted service is a managed service factory the item id must be equal with the pid of the configuration to be deleted.

Parameters:
itemId - configuration item identifier; cannot be null
Throws:
IllegalArgumentException - - If id is null or empty


Copyright © 2006-2012 OPS4J - Open Participation Software for Java. All Rights Reserved.