Class AbstractElementDatabase

java.lang.Object
com.jsql.model.bean.database.AbstractElementDatabase
Direct Known Subclasses:
Column, Database, Table

public abstract class AbstractElementDatabase extends Object
Class used by the model to properly define components of the database. When the model ends a process of injection, it builds the corresponding database elements and provides them to the view. You can traverse elements from columns, to its corresponding table, to its corresponding database, inverse isn't required (database>table>column is not used) Concern only databases, tables and columns, values are raw data directly processed by the view
  • Field Details

    • elementValue

      protected String elementValue
      Label of the current element.
    • MOCK

      public static final AbstractElementDatabase MOCK
      Used by non-progressing threads like File, metadata and shells. Required for suspendable concurrent map tracking.
  • Constructor Details

    • AbstractElementDatabase

      public AbstractElementDatabase()
  • Method Details

    • getParent

      public abstract AbstractElementDatabase getParent()
      Traverse upward, and return the parent.
      Returns:
    • getChildCount

      public abstract int getChildCount()
      Return the number of elements contained by current element :
      - for database: number of tables,
      - for table: number of rows.
    • getLabelCount

      public abstract String getLabelCount()
      Return a readable label displayed by the view.
      Returns:
    • toString

      public String toString()
      Return the label of current element.
      Overrides:
      toString in class Object
    • setElementValue

      public void setElementValue(String elementValue)