Class MAlertProcessor

All Implemented Interfaces:
Serializable, Cloneable, Comparator<Object>, AdempiereProcessor, AdempiereProcessor2, I_AD_AlertProcessor, I_Persistent, Evaluatee

public class MAlertProcessor extends X_AD_AlertProcessor implements AdempiereProcessor, AdempiereProcessor2
Alert Processor
Version:
$Id: MAlertProcessor.java,v 1.3 2006/07/30 00:51:03 jjanke Exp $
Author:
Jorg Janke
See Also:
  • Constructor Details

    • MAlertProcessor

      public MAlertProcessor(Properties ctx, String AD_AlertProcessor_UU, String trxName)
      UUID based Constructor
      Parameters:
      ctx - Context
      AD_AlertProcessor_UU - UUID key
      trxName - Transaction
    • MAlertProcessor

      public MAlertProcessor(Properties ctx, int AD_AlertProcessorLog_ID, String trxName)
      Standard Constructor
      Parameters:
      ctx - context
      AD_AlertProcessorLog_ID - id
      trxName - transaction
    • MAlertProcessor

      public MAlertProcessor(Properties ctx, ResultSet rs, String trxName)
      Load Constructor
      Parameters:
      ctx - context
      rs - result set
      trxName - transaction
  • Method Details

    • getActive

      public static MAlertProcessor[] getActive(Properties ctx)
      Get active alert processors
      Parameters:
      ctx - context
      Returns:
      active alert processors
    • getServerID

      public String getServerID()
      Get Server ID
      Specified by:
      getServerID in interface AdempiereProcessor
      Returns:
      id
    • getDateNextRun

      public Timestamp getDateNextRun(boolean requery)
      Get Date Next Run
      Specified by:
      getDateNextRun in interface AdempiereProcessor
      Parameters:
      requery - requery
      Returns:
      date next run
    • getLogs

      public AdempiereProcessorLog[] getLogs()
      Get Logs
      Specified by:
      getLogs in interface AdempiereProcessor
      Returns:
      logs
    • deleteLog

      public int deleteLog()
      Delete old Request Log
      Returns:
      number of records
    • getAlerts

      public MAlert[] getAlerts(boolean reload)
      Get Alerts
      Parameters:
      reload - true to always reload from DB
      Returns:
      array of alerts
    • beforeSave

      protected boolean beforeSave(boolean newRecord)
      Description copied from class: PO
      Called before Save for Pre-Save Operation.
      Default implementation is nop, to be implemented in sub-classes that needed it.
      Overrides:
      beforeSave in class PO
      Parameters:
      newRecord - true if it is a new record
      Returns:
      true if record can be saved
    • getFrequencyType

      public String getFrequencyType()
      Description copied from interface: AdempiereProcessor
      Get the frequency type
      Specified by:
      getFrequencyType in interface AdempiereProcessor
      Returns:
      frequency type
    • getFrequency

      public int getFrequency()
      Description copied from interface: AdempiereProcessor
      Get the frequency
      Specified by:
      getFrequency in interface AdempiereProcessor
      Returns:
      frequency
    • isIgnoreProcessingTime

      public boolean isIgnoreProcessingTime()
      Specified by:
      isIgnoreProcessingTime in interface AdempiereProcessor2
      Returns:
      True if previous DateNextRun should be use as base to calculate the new DateNextRun value. False to follow the legacy behaviour where current server time is use as the base to calculate the new DateNextRun value.
    • getScheduleType

      public String getScheduleType()
      Description copied from interface: AdempiereProcessor
      Get the schedule type
      Specified by:
      getScheduleType in interface AdempiereProcessor
      Returns:
      schedule type
    • getCronPattern

      public String getCronPattern()
      Description copied from interface: AdempiereProcessor
      Get the cron pattern
      Specified by:
      getCronPattern in interface AdempiereProcessor
      Returns:
      cron pattern