package ervu_business_metrics.model.idm;

import java.util.List;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import ervu_business_metrics.model.ReferenceEntity;
import ervu_business_metrics.deserializer.ReferenceEntityDeserializer;

/**
 * @author Adel Kalimullin
 */
@JsonIgnoreProperties(ignoreUnknown = true)
public class AccountData {
  private String id;
  private int version;
  private long modified;
  private String schema;
  private String start;
  private String finish;
  private boolean enabled;
  private String position;
  private String fio;
  private String workMail;
  private boolean esiaAccount;
  @JsonProperty("user-domain")
  @JsonDeserialize(using = ReferenceEntityDeserializer.class)
  private ReferenceEntity userDomain;
  private List<String> roles;

  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public int getVersion() {
    return version;
  }

  public void setVersion(int version) {
    this.version = version;
  }

  public long getModified() {
    return modified;
  }

  public void setModified(long modified) {
    this.modified = modified;
  }

  public String getSchema() {
    return schema;
  }

  public void setSchema(String schema) {
    this.schema = schema;
  }

  public String getStart() {
    return start;
  }

  public void setStart(String start) {
    this.start = start;
  }

  public String getFinish() {
    return finish;
  }

  public void setFinish(String finish) {
    this.finish = finish;
  }

  public boolean isEnabled() {
    return enabled;
  }

  public void setEnabled(boolean enabled) {
    this.enabled = enabled;
  }

  public String getPosition() {
    return position;
  }

  public void setPosition(String position) {
    this.position = position;
  }

  public String getFio() {
    return fio;
  }

  public void setFio(String fio) {
    this.fio = fio;
  }

  public String getWorkMail() {
    return workMail;
  }

  public void setWorkMail(String workMail) {
    this.workMail = workMail;
  }

  public boolean isEsiaAccount() {
    return esiaAccount;
  }

  public void setEsiaAccount(boolean esiaAccount) {
    this.esiaAccount = esiaAccount;
  }

  public ReferenceEntity getUserDomain() {
    return userDomain;
  }

  public void setUserDomain(ReferenceEntity userDomain) {
    this.userDomain = userDomain;
  }

  public List<String> getRoles() {
    return roles;
  }

  public void setRoles(List<String> roles) {
    this.roles = roles;
  }
}

