Class Assignment

java.lang.Object
com.plannaplan.entities.Assignment

@Entity
public class Assignment
extends java.lang.Object
Entity of Assignment grouping of state associated about group_id and commision_id
  • Constructor Details

    • Assignment

      public Assignment​(Groups group, Commision commision, boolean isPastAssignment)
      Assignment
      Parameters:
      group - group we would like to assign
      commision - commision that assignment belongs to
      isPastAssignment - is assignment past or no
    • Assignment

      public Assignment​(Groups group, Commision commision)
      Assignment
      Parameters:
      group - group we would like to assign
      commision - commision that assignment belongs to
    • Assignment

      public Assignment()
  • Method Details

    • getNewFromAssignment

      public static Assignment getNewFromAssignment​(Assignment oldAssignment, Commision newCommision)
      Parameters:
      oldAssignment - old assignment that we want to move to new commision
      newCommision - commsion to move assiongment
    • isAccepted

      public boolean isAccepted()
      If it returns trues it mesans u are assigned to group accepted by algorythm
      Returns:
      boolean isAccepted
    • getCommision

      public Commision getCommision()
      Getter of commision
      Returns:
      Commision Commision of given assignments
    • setCommision

      public void setCommision​(Commision commision)
      Parameters:
      commision - commision to set
    • getId

      public java.lang.Long getId()
      Id getter
      Returns:
      id id of assignment
    • getGroup

      public Groups getGroup()
      getGroup
      Returns:
      group
    • isPastAssignment

      public boolean isPastAssignment()
      isPastAssignment getter
      Returns:
      isPastAssignment
    • setPastAssignment

      public void setPastAssignment​(boolean isPastAssignment)
      setter isPastAssignment
      Parameters:
      isPastAssignment - is assignment past or not