Package org.codice.ddf.admin.core.api
Interface ConfigurationAdmin
public interface ConfigurationAdmin
This service provides extra operations that can be used with respect to ConfigurationAdmin
This code is experimental. While this interface is functional and tested, it may change or be removed in a future version of the library.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondisableManagedServiceFactoryConfiguration(String servicePid, org.osgi.service.cm.Configuration enabledConfig) Disables a currently enabled configuration.enableManagedServiceFactoryConfiguration(String servicePid, org.osgi.service.cm.Configuration disabledConfig) Enables a currently disabled configuration.findMetatypeForConfig(org.osgi.service.cm.Configuration config) Returns the complete Metatype with all available information for the providedConfigurationorg.osgi.service.cm.ConfigurationgetConfiguration(String pid) Returns theConfigurationassociated with the given PIDReturns a default filter that can be used by a client when calling listServices(...)Returns a default filter that can be used by a client when calling listServices(...)getName(org.osgi.framework.Bundle bundle) Returns the name of a bundle.org.osgi.service.metatype.ObjectClassDefinitionReturns theObjectClassDefinitionassociated with the givenConfiguration.org.osgi.service.metatype.ObjectClassDefinitiongetObjectClassDefinition(org.osgi.framework.Bundle bundle, String pid) Returns theObjectClassDefinitionassociated with the givenConfiguration.org.osgi.service.metatype.ObjectClassDefinitiongetObjectClassDefinition(org.osgi.service.cm.Configuration config) Returns theObjectClassDefinitionassociated with the givenConfiguration.booleanisPermittedToViewService(String servicePid, org.apache.shiro.subject.Subject subject) Returns true if the subject is permitted to view the service corresponding to the provided service.pid.listServices(String serviceFactoryFilter, String serviceFilter) Returns all services and managed service factories that satisfy the provided LDAP filters
-
Field Details
-
NO_MATCH_FILTER
- See Also:
-
-
Method Details
-
getConfiguration
Returns theConfigurationassociated with the given PID- Parameters:
pid- - service pid for the configuration- Returns:
- Configuration
-
getObjectClassDefinition
org.osgi.service.metatype.ObjectClassDefinition getObjectClassDefinition(org.osgi.service.cm.Configuration config) Returns theObjectClassDefinitionassociated with the givenConfiguration. The ObjectClassDefinition is the actual configuration part of the metatype that holds all of the configurable pieces.- Parameters:
config- - The configuration associated with the metatype- Returns:
- ObjectClassDefinition
-
getObjectClassDefinition
org.osgi.service.metatype.ObjectClassDefinition getObjectClassDefinition(org.osgi.framework.Bundle bundle, String pid) Returns theObjectClassDefinitionassociated with the givenConfiguration. The ObjectClassDefinition is the actual configuration part of the metatype that holds all of the configurable pieces.- Parameters:
bundle- - The bundle for which metatype information is requested.pid- - Service pid for the metatype- Returns:
- ObjectClassDefinition
-
getObjectClassDefinition
Returns theObjectClassDefinitionassociated with the givenConfiguration. The ObjectClassDefinition is the actual configuration part of the metatype that holds all of the configurable pieces.- Parameters:
pid- - Service pid for the metatype- Returns:
- ObjectClassDefinition
-
listServices
Returns all services and managed service factories that satisfy the provided LDAP filters- Parameters:
serviceFactoryFilter- - LDAP filter for managed service factoriesserviceFilter- - LDAP filter for managed services- Returns:
- List
-
isPermittedToViewService
Returns true if the subject is permitted to view the service corresponding to the provided service.pid.- Parameters:
servicePid- - PID of the service in questionsubject- - Subject to imply- Returns:
- True if the subject is allowed to view the service
-
findMetatypeForConfig
Returns the complete Metatype with all available information for the providedConfiguration- Parameters:
config- - Configuration to retrieve Metatype for- Returns:
- Metatype
-
getDefaultFactoryLdapFilter
String getDefaultFactoryLdapFilter()Returns a default filter that can be used by a client when calling listServices(...) This filter would pertain to managed service factories- Returns:
- a default filter that can be used by a client when calling listServices(...)
-
getDefaultLdapFilter
String getDefaultLdapFilter()Returns a default filter that can be used by a client when calling listServices(...) This filter would pertain to managed services- Returns:
- a default filter that can be used by a client when calling listServices(...)
-
enableManagedServiceFactoryConfiguration
ConfigurationStatus enableManagedServiceFactoryConfiguration(String servicePid, org.osgi.service.cm.Configuration disabledConfig) throws IOException Enables a currently disabled configuration.- Parameters:
servicePid- - PID corresponding to the configurationdisabledConfig- - The configuration that is disabled- Returns:
- object representing the change in state from enabled to disabled
- Throws:
IOException
-
disableManagedServiceFactoryConfiguration
ConfigurationStatus disableManagedServiceFactoryConfiguration(String servicePid, org.osgi.service.cm.Configuration enabledConfig) throws IOException Disables a currently enabled configuration.- Parameters:
servicePid- - PID corresponding to the configurationenabledConfig- - The configuration that is enabled- Returns:
- object representing the change in state from disabled to enabled
- Throws:
IOException
-
getName
Returns the name of a bundle.- Parameters:
bundle- - Bundle to get the name of- Returns:
- name of the bundle
-