Class BeanField

java.lang.Object
ch.autumo.beetroot.utils.bean.BeanField

public class BeanField extends Object
Bean field.
  • Field Details

    • LOG

      protected static final org.slf4j.Logger LOG
  • Constructor Details

    • BeanField

      public BeanField(String dbName, String beanName, Class<?> type, boolean isNullable, boolean unique, Method getterMethod, Method setterMethod)
      Constructor.
      Parameters:
      dbName - column name
      beanName - attribute name
      type - Java type
      isNullable - is nullable?
      unique - is unique?
      getterMethod - getter method
      setterMethod - setter method
  • Method Details

    • getGetterMethod

      public Method getGetterMethod()
    • getSetterMethod

      public Method getSetterMethod()
    • getDbName

      public String getDbName()
    • getBeanName

      public String getBeanName()
    • getType

      public Class<?> getType()
    • isUnique

      public boolean isUnique()
    • isNullable

      public boolean isNullable()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • serialize

      public String serialize(BeanField field) throws com.fasterxml.jackson.core.JsonProcessingException
      Serialize this field to JSON.
      Parameters:
      field - field
      Returns:
      JSON string
      Throws:
      com.fasterxml.jackson.core.JsonProcessingException - JSON processing exception