Class MEntityType

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

    public class MEntityType
    extends X_AD_EntityType
    implements ImmutablePOSupport
    Enitity Type Model
    Version:
    $Id: MEntityType.java,v 1.2 2006/07/30 00:51:02 jjanke Exp $
    Author:
    Jorg Janke, Teo Sarca
  • BF [ 2827777 ] MEntityType.isSystemMaintained not working well https://sourceforge.net/p/adempiere/bugs/1993/
  • FR [ 2827786 ] Introduce MEntityType.get(Properties ctx, String entityType) https://sourceforge.net/p/adempiere/feature-requests/778/
  • BF [ 2861194 ] EntityType is not using normal PO framework for getting IDs https://sourceforge.net/p/adempiere/bugs/2103/
  • See Also:
    Serialized Form
    • Constructor Detail

      • MEntityType

        public MEntityType​(Properties ctx,
                           int AD_EntityType_ID,
                           String trxName)
        Standard Constructor
        Parameters:
        ctx - context
        AD_EntityType_ID - id
        trxName - transaction
      • MEntityType

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

        public MEntityType​(MEntityType copy)
        Parameters:
        copy -
    • Method Detail

      • get

        public static MEntityType get​(String entityType)
        Get EntityType object by name (immutable)
        Parameters:
        entityType -
        Returns:
        entity type
      • get

        public static MEntityType get​(Properties ctx,
                                      String entityType)
        Get EntityType object by name (immutable)
        Parameters:
        ctx -
        entityType -
        Returns:
        entity type
      • isSystemMaintained

        public boolean isSystemMaintained()
        Is System Maintained. Any Entity Type with ID < 1000000.
        Returns:
        true if D/C/U/CUST/A/EXT/XX (ID < 1000000)
      • beforeSave

        protected boolean beforeSave​(boolean newRecord)
        Before Save
        Overrides:
        beforeSave in class PO
        Parameters:
        newRecord - new
        Returns:
        true if it can be saved
      • beforeDelete

        protected boolean beforeDelete()
        Before Delete
        Overrides:
        beforeDelete in class PO
        Returns:
        true if it can be deleted