Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package app.helper.pojo.api.csb.deck;
- import app.utils.CommonOperations;
- import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
- import com.fasterxml.jackson.annotation.JsonProperty;
- import java.util.UUID;
- import static app.helper.model.BaseTest.vesselId;
- import static app.utils.Enums.TextFields.AUTODECK;
- import static app.utils.Enums.TextFields.AUTOTESTDECKNAME;
- @JsonIgnoreProperties(ignoreUnknown = true)
- public class Deck{
- @JsonProperty("IsPassive")
- private boolean isPassive;
- @JsonProperty("VesselId")
- private int id;
- @JsonProperty("Code")
- private String code;
- @JsonProperty("Name")
- private String name;
- public Deck() {
- CommonOperations co = new CommonOperations();
- this.isPassive = false;
- this.id = vesselId;
- this.code = AUTODECK.gV()+co.getRandomNumber(6);
- this.name = AUTOTESTDECKNAME.gV( )+ UUID.randomUUID().toString().toUpperCase();
- }
- public Deck(Deck deck) {
- this.id = deck.getVesselId();
- this.isPassive = deck.getIsPassive();
- this.code = deck.getCode();
- this.name = deck.getName();
- }
- @Override
- public String toString(){
- return
- "Deck { isPassive = '" + isPassive + '\'' +
- ",id = '" + id + '\'' +
- ",code = '" + code + '\'' +
- ",name = '" + name + "}";
- }
- public int getVesselId( ) { return id; }
- public String getName( ) { return name; }
- public String getCode( ) { return code; }
- public boolean getIsPassive( ) { return isPassive; }
- }
Advertisement
Add Comment
Please, Sign In to add comment