org.jboss.system.server.profile.repository
Class AbstractProfile

java.lang.Object
  extended by org.jboss.system.server.profile.repository.AbstractProfile
All Implemented Interfaces:
org.jboss.profileservice.spi.MutableProfile, org.jboss.profileservice.spi.Profile

public class AbstractProfile
extends Object
implements org.jboss.profileservice.spi.MutableProfile

A basic profile implementation, which delegates all the deployment actions the a DeploymentRepository.

Version:
$Revision: 86174 $
Author:
Emanuel Muckenhuber

Constructor Summary
AbstractProfile(org.jboss.profileservice.spi.DeploymentRepository repository, org.jboss.profileservice.spi.ProfileKey key)
           
AbstractProfile(org.jboss.profileservice.spi.DeploymentRepository repository, org.jboss.profileservice.spi.ProfileKey key, List<org.jboss.profileservice.spi.ProfileKey> subProfiles)
           
 
Method Summary
 void addDeployment(org.jboss.profileservice.spi.ProfileDeployment d)
           
 void create()
           
 void destroy()
           
 void enableModifiedDeploymentChecks(boolean flag)
           
 org.jboss.profileservice.spi.ProfileDeployment getDeployment(String name)
           
 Set<String> getDeploymentNames()
           
 Collection<org.jboss.profileservice.spi.ProfileDeployment> getDeployments()
           
 org.jboss.profileservice.spi.ProfileKey getKey()
           
 long getLastModified()
           
 Collection<org.jboss.profileservice.spi.ModificationInfo> getModifiedDeployments()
           
 Collection<org.jboss.profileservice.spi.ProfileKey> getSubProfiles()
           
 boolean hasDeployment(String name)
           
 boolean isMutable()
           
 org.jboss.profileservice.spi.ProfileDeployment removeDeployment(String name)
           
 void setSubProfiles(List<org.jboss.profileservice.spi.ProfileKey> subProfiles)
           
 String toString()
           
protected  void toString(StringBuilder builder)
          Additional information for toString().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractProfile

public AbstractProfile(org.jboss.profileservice.spi.DeploymentRepository repository,
                       org.jboss.profileservice.spi.ProfileKey key)

AbstractProfile

public AbstractProfile(org.jboss.profileservice.spi.DeploymentRepository repository,
                       org.jboss.profileservice.spi.ProfileKey key,
                       List<org.jboss.profileservice.spi.ProfileKey> subProfiles)
Method Detail

addDeployment

public void addDeployment(org.jboss.profileservice.spi.ProfileDeployment d)
                   throws Exception
Specified by:
addDeployment in interface org.jboss.profileservice.spi.MutableProfile
Throws:
Exception

enableModifiedDeploymentChecks

public void enableModifiedDeploymentChecks(boolean flag)
Specified by:
enableModifiedDeploymentChecks in interface org.jboss.profileservice.spi.MutableProfile

getDeployment

public org.jboss.profileservice.spi.ProfileDeployment getDeployment(String name)
                                                             throws org.jboss.profileservice.spi.NoSuchDeploymentException
Specified by:
getDeployment in interface org.jboss.profileservice.spi.Profile
Throws:
org.jboss.profileservice.spi.NoSuchDeploymentException

getDeploymentNames

public Set<String> getDeploymentNames()
Specified by:
getDeploymentNames in interface org.jboss.profileservice.spi.Profile

getDeployments

public Collection<org.jboss.profileservice.spi.ProfileDeployment> getDeployments()
Specified by:
getDeployments in interface org.jboss.profileservice.spi.Profile

getKey

public org.jboss.profileservice.spi.ProfileKey getKey()
Specified by:
getKey in interface org.jboss.profileservice.spi.Profile

getSubProfiles

public Collection<org.jboss.profileservice.spi.ProfileKey> getSubProfiles()
Specified by:
getSubProfiles in interface org.jboss.profileservice.spi.Profile

setSubProfiles

public void setSubProfiles(List<org.jboss.profileservice.spi.ProfileKey> subProfiles)

getLastModified

public long getLastModified()
Specified by:
getLastModified in interface org.jboss.profileservice.spi.Profile

getModifiedDeployments

public Collection<org.jboss.profileservice.spi.ModificationInfo> getModifiedDeployments()
                                                                                 throws Exception
Specified by:
getModifiedDeployments in interface org.jboss.profileservice.spi.MutableProfile
Throws:
Exception

hasDeployment

public boolean hasDeployment(String name)
Specified by:
hasDeployment in interface org.jboss.profileservice.spi.Profile

removeDeployment

public org.jboss.profileservice.spi.ProfileDeployment removeDeployment(String name)
                                                                throws Exception
Specified by:
removeDeployment in interface org.jboss.profileservice.spi.MutableProfile
Throws:
Exception

create

public void create()
            throws Exception
Throws:
Exception

destroy

public void destroy()

toString

public String toString()
Overrides:
toString in class Object

toString

protected void toString(StringBuilder builder)
Additional information for toString().

Parameters:
builder - the builder.

isMutable

public boolean isMutable()
Specified by:
isMutable in interface org.jboss.profileservice.spi.Profile


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