Record Class CreateUpdatePositionTransactionDTO

java.lang.Object
java.lang.Record
com.bluebell.greenhouse.platform.models.api.dto.position.CreateUpdatePositionTransactionDTO
Record Components:
transactionType - transaction type
transactionDate - transaction date
amount - transaction amount
externalTransactionId - optional stable external transaction identity
sourceReference - optional raw upstream reference
description - transaction description

public record CreateUpdatePositionTransactionDTO(@NotBlank @Size(max=255) String transactionType, @NotBlank @Size(max=255) String transactionDate, @NotNull @Positive @DecimalMax("999999999") Double amount, @Size(max=255) String externalTransactionId, @Size(max=255) String sourceReference, String description) extends Record
Request object for creating and updating PositionTransactions.
Version:
3.0.1
Author:
Stephen Prizio
  • Constructor Details

    • CreateUpdatePositionTransactionDTO

      public CreateUpdatePositionTransactionDTO(@NotBlank @Size(max=255) @NotBlank @Size(max=255) String transactionType, @NotBlank @Size(max=255) @NotBlank @Size(max=255) String transactionDate, @NotNull @Positive @DecimalMax("999999999") @NotNull @Positive @DecimalMax("999999999") Double amount, @Size(max=255) @Size(max=255) String externalTransactionId, @Size(max=255) @Size(max=255) String sourceReference, String description)
      Creates an instance of a CreateUpdatePositionTransactionDTO record class.
      Parameters:
      transactionType - the value for the transactionType record component
      transactionDate - the value for the transactionDate record component
      amount - the value for the amount record component
      externalTransactionId - the value for the externalTransactionId record component
      sourceReference - the value for the sourceReference record component
      description - the value for the description record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • transactionType

      @NotBlank @Size(max=255) public @NotBlank @Size(max=255) String transactionType()
      Returns the value of the transactionType record component.
      Returns:
      the value of the transactionType record component
    • transactionDate

      @NotBlank @Size(max=255) public @NotBlank @Size(max=255) String transactionDate()
      Returns the value of the transactionDate record component.
      Returns:
      the value of the transactionDate record component
    • amount

      @NotNull @Positive @DecimalMax("999999999") public @NotNull @Positive @DecimalMax("999999999") Double amount()
      Returns the value of the amount record component.
      Returns:
      the value of the amount record component
    • externalTransactionId

      @Size(max=255) public @Size(max=255) String externalTransactionId()
      Returns the value of the externalTransactionId record component.
      Returns:
      the value of the externalTransactionId record component
    • sourceReference

      @Size(max=255) public @Size(max=255) String sourceReference()
      Returns the value of the sourceReference record component.
      Returns:
      the value of the sourceReference record component
    • description

      public String description()
      Returns the value of the description record component.
      Returns:
      the value of the description record component