org.jboss.profileservice.spi
Interface ProfileService


public interface ProfileService

The entry point service for accessing/administering server profiles

Version:
$Revision$
Author:
Scott.Stark@jboss.org, Emanuel Muckenhuber

Method Summary
 void activateProfile(ProfileKey key)
          Activate a registered profile.
 void deactivateProfile(ProfileKey key)
          Deactivate the profile.
 Profile getActiveProfile(ProfileKey key)
          Obtain a activated profile for the key.
 Collection<ProfileKey> getActiveProfileKeys()
          Get the keys for all active profiles.
 DeploymentManager getDeploymentManager()
          Obtain the DeploymentManager plugin.
 String[] getDomains()
          Get the unique domains for which profiles exist.
 Profile getProfile(ProfileKey key)
          Obtain the registered profile for the key.
 Collection<ProfileKey> getProfileKeys()
          Get the keys for all registered profiles.
 ManagementView getViewManager()
          Obtain the ManagementView plugin.
 void registerProfile(Profile profile)
          Register a Profile.
 void unregisterProfile(ProfileKey key)
          Unregister a profile.
 void validateProfile(ProfileKey key)
          Validate a registered profile.
 

Method Detail

getDomains

String[] getDomains()
Get the unique domains for which profiles exist.

Returns:
array of profile domains

getProfileKeys

Collection<ProfileKey> getProfileKeys()
Get the keys for all registered profiles.

Returns:
keys for all registered profiles

getProfile

Profile getProfile(ProfileKey key)
                   throws NoSuchProfileException
Obtain the registered profile for the key.

Parameters:
key - - the key for the profile
Returns:
the matching profile
Throws:
NoSuchProfileException

getActiveProfileKeys

Collection<ProfileKey> getActiveProfileKeys()
Get the keys for all active profiles.

Returns:
keys for all active profiles

getActiveProfile

Profile getActiveProfile(ProfileKey key)
                         throws NoSuchProfileException
Obtain a activated profile for the key.

Parameters:
key - - the key for the profile
Returns:
the active profile
Throws:
NoSuchProfileException - thrown if there is no active profile

getViewManager

ManagementView getViewManager()
Obtain the ManagementView plugin.

Returns:
the ManagementView plugin if supported

getDeploymentManager

DeploymentManager getDeploymentManager()
Obtain the DeploymentManager plugin.

Returns:
the DeploymentManager plugin if supported

registerProfile

void registerProfile(Profile profile)
                     throws Exception
Register a Profile.

Parameters:
profile - the profile
Throws:
Exception - for any error

activateProfile

void activateProfile(ProfileKey key)
                     throws NoSuchProfileException,
                            Exception
Activate a registered profile.

Parameters:
key - the profile key
Throws:
NoSuchProfileException - if the profile is not registered
Exception - for any error

deactivateProfile

void deactivateProfile(ProfileKey key)
                       throws NoSuchProfileException
Deactivate the profile.

Parameters:
key - the profile key
Throws:
NoSuchProfileException - if the profile is not active

unregisterProfile

void unregisterProfile(ProfileKey key)
                       throws NoSuchProfileException
Unregister a profile.

Parameters:
key - the profile key
Throws:
NoSuchProfileException - if the profile is not registered

validateProfile

void validateProfile(ProfileKey key)
                     throws Exception
Validate a registered profile.

Parameters:
key - the profile key
Throws:
NoSuchProfileException - if the profile is not registered
Exception - if the profile is not installed correctly


Copyright © 2010 JBoss, a division of Red Hat, Inc.. All Rights Reserved.