Class JKTableRecord

java.lang.Object
com.jk.core.model.table.JKTableRecord

public class JKTableRecord extends Object
The Class JKTableRecord.
  • Constructor Details

    • JKTableRecord

      public JKTableRecord()
  • Method Details

    • addEmptyValue

      public void addEmptyValue(JKTableColumn col)
      Adds the empty value.
      Parameters:
      col - the col
    • addEmptyValues

      public void addEmptyValues(Vector<JKTableColumn> tableColumns)
      Adds the empty values.
      Parameters:
      tableColumns - the table columns
    • getColumn

      public JKTableColumn getColumn(int index)
      Gets the column.
      Parameters:
      index - the index
      Returns:
      the column
    • getColumnIndex

      public int getColumnIndex(String name)
      Gets the column index.
      Parameters:
      name - the name
      Returns:
      the column index
    • getColumnsValues

      public Vector<JKTableColumnValue> getColumnsValues()
      Gets the columns values.
      Returns:
      the columns values
    • getColumnValue

      public Object getColumnValue(int col)
      Gets the column value.
      Parameters:
      col - the col
      Returns:
      the column value
    • getColumnValue

      public Object getColumnValue(String name)
      Gets the column value.
      Parameters:
      name - the name
      Returns:
      the column value
    • getColumnValueAsDate

      public Date getColumnValueAsDate(int colIndex)
      Gets the column value as date.
      Parameters:
      colIndex - the col index
      Returns:
      the column value as date
    • getColumnValueAsDate

      public Date getColumnValueAsDate(String colName)
      Gets the column value as date.
      Parameters:
      colName - the col name
      Returns:
      the column value as date
    • getColumnValueAsDouble

      public double getColumnValueAsDouble(int col)
      Gets the column value as double.
      Parameters:
      col - the col
      Returns:
      the column value as double
    • getColumnValueAsDouble

      public Double getColumnValueAsDouble(int col, double defaultValue)
      Gets the column value as double.
      Parameters:
      col - the col
      defaultValue - the default value
      Returns:
      the column value as double
    • getColumnValueAsDouble

      public double getColumnValueAsDouble(String colName)
      Gets the column value as double.
      Parameters:
      colName - the col name
      Returns:
      the column value as double
    • getColumnValueAsFloat

      public Float getColumnValueAsFloat(int col)
      Gets the column value as float.
      Parameters:
      col - the col
      Returns:
      the column value as float
    • getColumnValueAsInteger

      public int getColumnValueAsInteger(int col)
      Gets the column value as integer.
      Parameters:
      col - the col
      Returns:
      the column value as integer
    • getColumnValueAsInteger

      public int getColumnValueAsInteger(String colName)
      Gets the column value as integer.
      Parameters:
      colName - the col name
      Returns:
      the column value as integer
    • getFieldValue

      public Object getFieldValue(String name)
      Gets the field value.
      Parameters:
      name - the name
      Returns:
      the field value
    • getStatus

      public JKTableRecord.RecordStatus getStatus()
      Gets the status.
      Returns:
      the status
    • isColumnEnabled

      public boolean isColumnEnabled(int col)
      Checks if is column enabled.
      Parameters:
      col - the col
      Returns:
      true, if is column enabled
    • isModified

      public boolean isModified()
      Checks if is modified.
      Returns:
      true, if is modified
    • setColumnEnabled

      public void setColumnEnabled(int col, boolean enable)
      Sets the column enabled.
      Parameters:
      col - the col
      enable - the enable
    • setColumnsValues

      public void setColumnsValues(Vector<JKTableColumnValue> values)
      Sets the columns values.
      Parameters:
      values - the new columns values
    • setColumnValue

      public void setColumnValue(int columnIndex, Object value)
      Sets the column value.
      Parameters:
      columnIndex - the column index
      value - the value
    • setColumnValue

      public void setColumnValue(String colName, Object value)
      Sets the column value.
      Parameters:
      colName - the col name
      value - the value
    • setFieldValue

      public void setFieldValue(String name, Object value)
      Sets the field value.
      Parameters:
      name - the name
      value - the value
    • setStatus

      public void setStatus(JKTableRecord.RecordStatus status)
      Sets the status.
      Parameters:
      status - the new status
    • toHash

      public Hashtable<String,Object> toHash()
      To hash.
      Returns:
      the hashtable
    • toValuesVector

      public Vector<Object> toValuesVector()
      To values vector.
      Returns:
      the vector