JBoss AS7 Deployment Plugin 7.9.Final

org.jboss.as.plugin.deployment.resource
Class Resource

java.lang.Object
  extended by org.jboss.as.plugin.deployment.resource.Resource

public class Resource
extends Object

Defines a resource.

Author:
James R. Perkins

Constructor Summary
Resource()
          Default constructor.
 
Method Summary
 String getAddress()
          The address for the resource.
 Commands getAfterAdd()
          Returns the commands that should be executed after the resource is deployed.
 Commands getBeforeAdd()
          Returns the commands that should be executed before the resource is deployed.
 Map<String,String> getProperties()
          The properties for the resource.
 Resource[] getResources()
          Returns an array of resources that depend on this resource.
 boolean hasAfterAddCommands()
          Checks if there are commands that should be executed after the deployment.
 boolean hasBeforeAddCommands()
          Checks if there are commands that should be executed before the deployment.
 boolean isAddIfAbsent()
          Whether or not we should add only if the resource is absent.
 boolean isEnableResource()
          Whether or not the enable operation should be performed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Resource

public Resource()
Default constructor.

Method Detail

getAddress

public String getAddress()
The address for the resource.

Returns:
the address.

isAddIfAbsent

public boolean isAddIfAbsent()
Whether or not we should add only if the resource is absent.

Returns:
true if the resource should only be added if it does not already exist, otherwise false.

getProperties

public Map<String,String> getProperties()
The properties for the resource. If no properties were defined an empty map is returned.

Returns:
the properties.

isEnableResource

public boolean isEnableResource()
Whether or not the enable operation should be performed.

Returns:
true if the enable operation should be performed, otherwise false.

getResources

public Resource[] getResources()
Returns an array of resources that depend on this resource.

Note all sub-resources will be ignored if the isAddIfAbsent() is defined and his resource is already defined.

Returns:
an array of resources that depend on this resource or null if there are no child resources.

hasBeforeAddCommands

public boolean hasBeforeAddCommands()
Checks if there are commands that should be executed before the deployment.

Returns:
true if there are commands that need to be executed before the deployment, otherwise false

getBeforeAdd

public Commands getBeforeAdd()
Returns the commands that should be executed before the resource is deployed.

Returns:
the commands to execute

hasAfterAddCommands

public boolean hasAfterAddCommands()
Checks if there are commands that should be executed after the deployment.

Returns:
true if there are commands that need to be executed after the deployment, otherwise false

getAfterAdd

public Commands getAfterAdd()
Returns the commands that should be executed after the resource is deployed.

Returns:
the commands to execute

JBoss AS7 Deployment Plugin 7.9.Final

Copyright © 2016 JBoss by Red Hat. All Rights Reserved.