Interface MethodAttribute<X,​Y>

Type Parameters:
X - The type of the declaring entity view
Y - The type of attribute
All Superinterfaces:
Attribute<X,​Y>
All Known Subinterfaces:
MethodCollectionAttribute<X,​E>, MethodListAttribute<X,​E>, MethodMapAttribute<X,​K,​V>, MethodMultiListAttribute<X,​E,​C>, MethodMultiMapAttribute<X,​K,​V,​C>, MethodPluralAttribute<X,​C,​E>, MethodSetAttribute<X,​E>, MethodSingularAttribute<X,​Y>

public interface MethodAttribute<X,​Y>
extends Attribute<X,​Y>
Represents an attribute of a view type specified by a getter.
Since:
1.0.0
Author:
Christian Beikov
  • Method Details

    • getName

      String getName()
      Returns the name of this attribute.
      Returns:
      The name of this attribute
    • getMappedBy

      String getMappedBy()
      Returns the path by which the target type is mapped by.
      Returns:
      The mapped by path or null
      Since:
      1.2.0
    • getInverseRemoveStrategy

      InverseRemoveStrategy getInverseRemoveStrategy()
      Returns the inverse remove strategy if this is an inverse mapped attribute.
      Returns:
      The inverse remove strategy
      Since:
      1.2.0
    • isUpdatable

      boolean isUpdatable()
      Returns whether the attribute is updatable.
      Returns:
      Whether the attribute is updatable
      Since:
      1.1.0
    • isMutable

      boolean isMutable()
      Returns whether the attribute is mutable. It is mutable if it is updatable or the target type is mutable.
      Returns:
      Whether the attribute is mutable
      Since:
      1.2.0
    • isOptimisticLockProtected

      boolean isOptimisticLockProtected()
      Returns whether the attribute is protected by optimistic locking.
      Returns:
      Whether the attribute is optimistic lock protected
      Since:
      1.2.0
    • isPersistCascaded

      boolean isPersistCascaded()
      Returns whether the persisting of referenced objects is allowed.
      Returns:
      Whether persisting should be done
      Since:
      1.2.0
    • isUpdateCascaded

      boolean isUpdateCascaded()
      Returns whether the updating of referenced objects is allowed.
      Returns:
      Whether updating should be done
      Since:
      1.2.0
    • isDeleteCascaded

      boolean isDeleteCascaded()
      Returns whether delete cascading for referenced objects should be done.
      Returns:
      Whether delete cascading should be done
      Since:
      1.2.0
    • isOrphanRemoval

      boolean isOrphanRemoval()
      Returns whether orphaned objects should be deleted during an update.
      Returns:
      Whether orphaned objects are deleted
      Since:
      1.2.0
    • getReadOnlyAllowedSubtypes

      Set<Type<?>> getReadOnlyAllowedSubtypes()
      Returns the read-only subtypes that are allowed to be assigned to this attribute.
      Returns:
      The allowed read-only subtypes for assigning
      Since:
      1.3.0
    • getPersistCascadeAllowedSubtypes

      Set<Type<?>> getPersistCascadeAllowedSubtypes()
      Returns the subtypes that are allowed to be used when cascading CascadeType.PERSIST events.
      Returns:
      The allowed subtypes for persist events
      Since:
      1.2.0
    • getUpdateCascadeAllowedSubtypes

      Set<Type<?>> getUpdateCascadeAllowedSubtypes()
      Returns the subtypes that are allowed to be used when cascading CascadeType.UPDATE events.
      Returns:
      The allowed subtypes for update events
      Since:
      1.2.0
    • getAllowedSubtypes

      Set<Class<?>> getAllowedSubtypes()
      Returns the subtypes that are allowed to be assigned to this attribute.
      Returns:
      The allowed subtypes for assigning
      Since:
      1.5.0
    • getParentRequiringUpdateSubtypes

      Set<Class<?>> getParentRequiringUpdateSubtypes()
      Returns the updatable subtypes that need a parent to be assignable.
      Returns:
      The updatable subtypes that need a parent to be assignable
      Since:
      1.5.0
    • getParentRequiringCreateSubtypes

      Set<Class<?>> getParentRequiringCreateSubtypes()
      Returns the creatable subtypes that need a parent to be assignable.
      Returns:
      The creatable subtypes that need a parent to be assignable
      Since:
      1.5.0
    • getJavaMethod

      Method getJavaMethod()
      Returns the getter java method of this attribute.
      Returns:
      The getter java method of this attribute
    • getFilter

      AttributeFilterMapping<X,​?> getFilter​(String filterName)
      Returns the attribute filter mapping of this attribute with the given name.
      Parameters:
      filterName - The name of the attribute filter mapping which should be returned
      Returns:
      The attribute filter mapping of this attribute with the given name
    • getFilters

      Set<AttributeFilterMapping<X,​?>> getFilters()
      Returns the attribute filter mappings of this attribute.
      Returns:
      The attribute filter mappings of this attribute