Interface ReturningProperties

All Known Implementing Classes:
ReturningPropertyNames

public interface ReturningProperties
An interface that represents properties to be returned from database operations.

This interface is used to specify which entity properties should be returned from database operations that support returning clauses, such as INSERT, UPDATE, or DELETE with RETURNING. It provides a way to select specific properties or all properties to be included in the returning clause.

The interface includes predefined instances for common cases:

  • NONE - represents no properties to be returned
  • ALL - represents all properties to be returned

Custom implementations can be created to return specific subsets of properties.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final ReturningProperties
    A predefined instance of ReturningProperties that represents all properties.
    static final ReturningProperties
    A predefined instance of ReturningProperties that represents no properties.
  • Method Summary

    Modifier and Type
    Method
    Description
    default boolean
    Checks if the current ReturningProperties instance represents all properties.
    default boolean
    Checks if the current ReturningProperties instance represents no properties.
    List<? extends EntityPropertyType<?,?>>
    resolve(EntityType<?> entityType)
    Resolves a list of entity property types for the given entity type.
  • Field Details

  • Method Details

    • isNone

      default boolean isNone()
      Checks if the current ReturningProperties instance represents no properties.
      Returns:
      true if this instance is equal to NONE, otherwise false
    • isAll

      default boolean isAll()
      Checks if the current ReturningProperties instance represents all properties.
      Returns:
      true if this instance is equal to ALL, otherwise false
    • resolve

      List<? extends EntityPropertyType<?,?>> resolve(EntityType<?> entityType)
      Resolves a list of entity property types for the given entity type.
      Parameters:
      entityType - the entity type for which to resolve property types
      Returns:
      a list of entity property types associated with the given entity type