Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| The Spring Framework
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.transaction.interceptor
Class AttributesTransactionAttributeSource

    java.lang.Object
      org.springframework.transaction.interceptor.AbstractFallbackTransactionAttributeSource
          org.springframework.transaction.interceptor.AttributesTransactionAttributeSource

All Implemented Interfaces:
  InitializingBean, TransactionAttributeSource

    public class AttributesTransactionAttributeSource

extends AbstractFallbackTransactionAttributeSource
implements InitializingBean

Implementation of the `TransactionAttributeSource` interface that reads metadata via Spring's `Attributes` abstraction.

Typically used for reading in source-level attributes via Commons Attributes.

Author:
  Rod Johnson, Juergen Hoeller
See Also:
  `Attributes`, `CommonsAttributes`

Field Summary

Fields inherited from class org.springframework.transaction.interceptor.AbstractFallbackTransactionAttributeSource
`logger`

Constructor Summary
`AttributesTransactionAttributeSource()` Create a new AttributesTransactionAttributeSource.
`AttributesTransactionAttributeSource(Attributes attributes)` Create a new AttributesTransactionAttributeSource.

Method Summary
`void` | `afterPropertiesSet()` Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware).
`boolean` | `equals(Object other)`
`protected Collection` | `findAllAttributes(Class clazz)` Subclasses should implement this to return all attributes for this class.
`protected Collection` | `findAllAttributes(Method method)` Subclasses should implement this to return all attributes for this method.
`int` | `hashCode()`
`void` | `setAttributes(Attributes attributes)` Set the Attributes implementation to use.

Methods inherited from class org.springframework.transaction.interceptor.AbstractFallbackTransactionAttributeSource
`allowPublicMethodsOnly, findTransactionAttribute, getCacheKey, getTransactionAttribute`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AttributesTransactionAttributeSource

    public AttributesTransactionAttributeSource()

  Create a new AttributesTransactionAttributeSource.

  See Also:
    `setAttributes(org.springframework.metadata.Attributes)`

### AttributesTransactionAttributeSource

    public AttributesTransactionAttributeSource(Attributes attributes)

  Create a new AttributesTransactionAttributeSource.

  Parameters:
    `attributes` - the Attributes implementation to use
  See Also:
    `CommonsAttributes`

Method Detail

### setAttributes

    public void setAttributes(Attributes attributes)

  Set the Attributes implementation to use.

  See Also:
    `CommonsAttributes`

### afterPropertiesSet

    public void afterPropertiesSet()

  Description copied from interface: `InitializingBean`
  Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware).

  This method allows the bean instance to perform initialization only possible when all bean properties have been set and to throw an exception in the event of misconfiguration.

  Specified by:
    `afterPropertiesSet` in interface `InitializingBean`

### findAllAttributes

    protected Collection findAllAttributes(Class clazz)

  Description copied from class: `AbstractFallbackTransactionAttributeSource`
  Subclasses should implement this to return all attributes for this class.

  Specified by:
    `findAllAttributes` in class `AbstractFallbackTransactionAttributeSource`
  Parameters:
    `clazz` - class to retrieve attributes for
  Returns:
    all attributes associated with this class (may be `null`)

### findAllAttributes

    protected Collection findAllAttributes(Method method)

  Description copied from class: `AbstractFallbackTransactionAttributeSource`
  Subclasses should implement this to return all attributes for this method. We need all because of the need to analyze rollback rules.

  Specified by:
    `findAllAttributes` in class `AbstractFallbackTransactionAttributeSource`
  Parameters:
    `method` - the method to retrieve attributes for
  Returns:
    all attributes associated with this method (may be `null`)

### equals

    public boolean equals(Object other)

  Overrides:
    `equals` in class `Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| The Spring Framework
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002-2007 The Spring Framework.