Class ContainerTransaction
- java.lang.Object
-
- java.util.Observable
-
- org.glassfish.deployment.common.DynamicAttributesDescriptor
-
- org.glassfish.deployment.common.Descriptor
-
- org.glassfish.ejb.deployment.descriptor.ContainerTransaction
-
- All Implemented Interfaces:
Serializable
public final class ContainerTransaction extends Descriptor
This descriptor represents a specification of a transactional behavior.- Author:
- Danny Coward
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
MANDATORY
Transaction is mandatory.static String
NEVER
Never supply a transaction.static String
NOT_SUPPORTED
Transactions are not supported.static String
REQUIRED
A transaction is required.static String
REQUIRES_NEW
A new transaction must be created.static String
SUPPORTS
Transactions need support.-
Fields inherited from class org.glassfish.deployment.common.Descriptor
DESCRIPTION_CHANGED, DESCRIPTOR_CHANGED, docType, LARGE_ICON_CHANGED, NAME_CHANGED, SMALL_ICON_CHANGED
-
-
Constructor Summary
Constructors Constructor Description ContainerTransaction(String transactionAttribute, String description)
Create a new transaction descriptor with the given attribute.ContainerTransaction(ContainerTransaction other)
Copy constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object other)
Equality iff the other object is another container transaction with the same transaction attribute.String
getTransactionAttribute()
The transaction attribute that I specify.int
hashCode()
void
print(StringBuilder toStringBuilder)
Returns a formatted String representing my state.-
Methods inherited from class org.glassfish.deployment.common.Descriptor
addDescriptorExtension, addPrefixMapping, createUniqueFilenameAmongst, createUniqueNameAmongst, createUniqueNameAmongstNamedDescriptors, fillDocType, getDeploymentExtensions, getDescription, getDescriptorExtension, getDescriptorExtensions, getDisplayName, getDocType, getLargeIconUri, getLocalizedDescription, getLocalizedDescriptions, getLocalizedDisplayName, getLocalizedDisplayNames, getLocalizedLargeIconUri, getLocalizedLargeIconUris, getLocalizedSmallIconUri, getLocalizedSmallIconUris, getName, getPrefixMapping, getSmallIconUri, isBoundsChecking, setBoundsChecking, setDescription, setDisplayName, setLargeIconUri, setLocalizedDescription, setLocalizedDisplayName, setLocalizedLargeIconUri, setLocalizedSmallIconUri, setName, setSmallIconUri, visit
-
Methods inherited from class org.glassfish.deployment.common.DynamicAttributesDescriptor
addExtraAttribute, getExtraAttribute, getExtraAttributes, removeExtraAttribute, toString
-
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
-
-
-
-
Field Detail
-
NOT_SUPPORTED
public static final String NOT_SUPPORTED
Transactions are not supported.- See Also:
- Constant Field Values
-
SUPPORTS
public static final String SUPPORTS
Transactions need support.- See Also:
- Constant Field Values
-
REQUIRED
public static final String REQUIRED
A transaction is required.- See Also:
- Constant Field Values
-
REQUIRES_NEW
public static final String REQUIRES_NEW
A new transaction must be created.- See Also:
- Constant Field Values
-
MANDATORY
public static final String MANDATORY
Transaction is mandatory.- See Also:
- Constant Field Values
-
NEVER
public static final String NEVER
Never supply a transaction.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ContainerTransaction
public ContainerTransaction(ContainerTransaction other)
Copy constructor.
-
ContainerTransaction
public ContainerTransaction(String transactionAttribute, String description)
Create a new transaction descriptor with the given attribute. Throws an IllegalArgumentException if the attribute is not an allowed type. The allowed types are enumeration ny this class.- Parameters:
transactionAttribute
- .description
- .
-
-
Method Detail
-
getTransactionAttribute
public String getTransactionAttribute()
The transaction attribute that I specify.- Returns:
- the transaction attribute.
-
equals
public boolean equals(Object other)
Equality iff the other object is another container transaction with the same transaction attribute.
-
print
public void print(StringBuilder toStringBuilder)
Returns a formatted String representing my state.- Overrides:
print
in classDescriptor
-
-