package com.ffii.lioner.modules.settings.entity;

import com.ffii.core.entity.IdEntity;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Table;
import jakarta.validation.constraints.NotNull;

@Entity
@Table(name = "settings")
public class Settings extends IdEntity<Long> {
  public static String TYPE_STRING = "string";
  public static String TYPE_INT = "integer";
  public static String TYPE_FLOAT = "float";
  public static String TYPE_BOOLEAN = "boolean";
  public static String TYPE_DATE = "date";
  public static String TYPE_TIME = "time";
  public static String TYPE_DATETIME = "datetime";
  // other "A/B" value must "A" or "B"

  //lowercase
  public static String VALUE_BOOLEAN_TRUE = "true";
  public static String VALUE_BOOLEAN_FALSE = "false";

  // TODO: pattern??

  @NotNull
  @Column
  private String name;

  @NotNull
  @Column
  private String value;

  @Column
  private String category;

  @Column
  private String type;

  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public String getValue() {
    return value;
  }

  public void setValue(String value) {
    this.value = value;
  }

  public String getCategory() {
    return category;
  }

  public void setCategory(String category) {
    this.category = category;
  }

  public String getType() {
    return type;
  }

  public void setType(String type) {
    this.type = type;
  }

}
