Class MAssetGroup

All Implemented Interfaces:
Serializable, Cloneable, Comparator<Object>, I_A_Asset_Group, I_Persistent, Evaluatee, ImmutablePOSupport

public class MAssetGroup extends X_A_Asset_Group implements ImmutablePOSupport
Asset Group Model
Author:
Teo Sarca, SC ARHIPAC SERVICE SRL
See Also:
  • Constructor Details

    • MAssetGroup

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

      public MAssetGroup(Properties ctx, int A_Asset_Group_ID, String trxName)
      Default Constructor
      Parameters:
      ctx - context
      A_Asset_Group_ID -
    • MAssetGroup

      public MAssetGroup(Properties ctx, ResultSet rs, String trxName)
      Load Constructor
      Parameters:
      ctx - context
      rs - result set
    • MAssetGroup

      public MAssetGroup(MAssetGroup copy)
      Copy constructor
      Parameters:
      copy -
    • MAssetGroup

      public MAssetGroup(Properties ctx, MAssetGroup copy)
      Copy constructor
      Parameters:
      ctx -
      copy -
    • MAssetGroup

      public MAssetGroup(Properties ctx, MAssetGroup copy, String trxName)
      Copy constructor
      Parameters:
      ctx -
      copy -
      trxName -
  • Method Details

    • get

      public static MAssetGroup get(int A_Asset_Group_ID)
      Get Asset Group [cache, immutable]
      Parameters:
      A_Asset_Group_ID - asset group id
      Returns:
      asset group or null
    • get

      public static MAssetGroup get(Properties ctx, int A_Asset_Group_ID)
      Get Asset Group [cache, immutable]
      Parameters:
      ctx - context
      A_Asset_Group_ID - asset group id
      Returns:
      asset group or null
    • getCopy

      public static MAssetGroup getCopy(Properties ctx, int A_Asset_Group_ID, String trxName)
      Get updateable copy of MAssetGroup from cache
      Parameters:
      ctx -
      A_Asset_Group_ID -
      trxName -
      Returns:
      MAssetGroup
    • getDefault_ID

      public static int getDefault_ID(SetGetModel m)
      Get default asset group ID for given model. WARNING: trxName = null.
      Parameters:
      m - reference model (used to get AD_Client_ID)
      Returns:
      default asset group ID or 0 if not found
    • updateAsset

      public static void updateAsset(SetGetModel m, int A_Asset_Group_ID)
      Update Asset
      - updates asset M_AssetGroup_ID if is null
    • beforeSave

      protected boolean beforeSave(boolean newRecord)
      Description copied from class: PO
      Called before Save for Pre-Save Operation
      Overrides:
      beforeSave in class PO
      Parameters:
      newRecord - new record
      Returns:
      true if record can be saved
    • afterSave

      protected boolean afterSave(boolean newRecord, boolean success)
      Description copied from class: PO
      Called after Save for Post-Save Operation
      Overrides:
      afterSave in class PO
      Parameters:
      newRecord - new record
      success - true if save operation was success
      Returns:
      if save was a success
    • markImmutable

      public MAssetGroup markImmutable()
      Description copied from interface: ImmutablePOSupport
      mark PO as immutable
      Specified by:
      markImmutable in interface ImmutablePOSupport
      Returns:
      PO