Class DataStatusEvent

java.lang.Object
java.util.EventObject
org.compiere.model.DataStatusEvent
All Implemented Interfaces:
Serializable

public final class DataStatusEvent extends EventObject implements Serializable
Data Status Event

Indicates the current Status of the database

Version:
$Id: DataStatusEvent.java,v 1.4 2006/07/30 00:51:02 jjanke Exp $
Author:
Jorg Janke
See Also:
  • Field Details

    • Created

      public Timestamp Created
      Created
    • CreatedBy

      public Integer CreatedBy
      Created By
    • Updated

      public Timestamp Updated
      Updated
    • UpdatedBy

      public Integer UpdatedBy
      Updated By
    • Info

      public String Info
      Info
    • AD_Table_ID

      public int AD_Table_ID
      Table ID
    • Record_ID

      public Object Record_ID
      Record ID
  • Constructor Details

    • DataStatusEvent

      public DataStatusEvent(Object source1, int totalRows, boolean changed, boolean autoSave, boolean inserting)
      Constructor
      Parameters:
      source1 - source
      totalRows - total rows
      changed - changed
      autoSave - auto save
      inserting - inserting
  • Method Details

    • setLoading

      public void setLoading(int loadedRows)
      Set Loading Info
      Parameters:
      loadedRows - loaded rows
    • isLoading

      public boolean isLoading()
      Is loading
      Returns:
      true if loading
    • getLoadedRows

      public int getLoadedRows()
      Get loaded rows
      Returns:
      loaded rows
    • setCurrentRow

      public void setCurrentRow(int currentRow)
      Set current Row (zero based)
      Parameters:
      currentRow - current row
    • getCurrentRow

      public int getCurrentRow()
      Get current row (zero based)
      Returns:
      current row
    • getTotalRows

      public int getTotalRows()
      Get total rows
      Returns:
      total number of rows
    • setInfo

      public void setInfo(String AD_Message, String info, boolean isError, boolean isWarning)
      Set Message Info
      Parameters:
      AD_Message - message
      info - info
      isError - error
      isWarning - true if warning
    • setInserting

      public void setInserting(boolean inserting)
      Set Inserting
      Parameters:
      inserting - inserting
    • isInserting

      public boolean isInserting()
      Returns:
      true if inserting
    • getAD_Message

      public String getAD_Message()
      Get AD Message
      Returns:
      AD Message
    • getInfo

      public String getInfo()
      Get info for AD Message
      Returns:
      info for AD Message
    • isError

      public boolean isError()
      Is this an error
      Returns:
      true if error
    • isWarning

      public boolean isWarning()
      Is this a warning
      Returns:
      true if warning
    • toString

      public String toString()
      String representation of Status.
      Overrides:
      toString in class EventObject
      Returns:
      Examples: +*1?/20 1/256->2000
    • getMessage

      public String getMessage()
      String representation of Status.
      
            *1/20       Change - automatic commit
            ?1/20       Change - manual confirm
             1/56->200  Loading
             1/20       Normal
           +*1/20       Inserting, changed - automatic commit
        The row number is converted from zero based representation
        
      Returns:
      Status info
    • isChanged

      public boolean isChanged()
      Is Data Changed
      Returns:
      true if changed
    • isFirstRow

      public boolean isFirstRow()
      Is First Row - (zero based)
      Returns:
      true if first row
    • isLastRow

      public boolean isLastRow()
      Is Last Row - (zero based)
      Returns:
      true if last row
    • setChangedColumn

      public void setChangedColumn(int col, String columnName)
      Set Changed Column
      Parameters:
      col - column index
      columnName - column name
    • getChangedColumn

      public int getChangedColumn()
      Get Changed Column
      Returns:
      changed column index
    • getColumnName

      public String getColumnName()
      Get Column Name
      Returns:
      column name
    • setConfirmed

      public void setConfirmed(boolean confirmed)
      Set Confirmed toggle
      Parameters:
      confirmed - confirmed
    • isConfirmed

      public boolean isConfirmed()
      Is Confirmed (e.g. user has seen it)
      Returns:
      true if confirmed
    • isEqual

      public boolean isEqual(DataStatusEvent e)
      Parameters:
      e -
      Returns:
      true if equal with e
    • isInitEdit

      public boolean isInitEdit()
      Returns:
      true if this event is by user start edit this field but not yet completed edit
    • setIsInitEdit

      public void setIsInitEdit(boolean isInitEdit)
      Parameters:
      isInitEdit - indicate this event is by user start edit this field but not yet completed edit