psdi.app.workorder

Class WoTagOut

  • All Implemented Interfaces:
    java.rmi.Remote, WoTagOutRemote, MboConstants, MboRemote, MaxRemoteProxy


    public class WoTagOut
    extends Mbo
    implements WoTagOutRemote
    Mbo object to represent WoTagOut. A workorder can have multiple tagouts with the same tagoutid and different wosafetydatasource. A wotagout can have different wosafetydatasource than its hazard. Therefore a WoTagOut mbo can be "owned" by more than one wosafetylink, for different hazards and/or different wosafetydatasource.

    A WoTagOut is always associated with a WoHazard (it cannot exist independently).

    Tagouts are related to hazards via the WoSafetyLink object. See Work Order Safety Mbos Overview.

    This object includes non-persistent attributes.

    This is a site level object.

    The key attributes for this object are SiteID, WoNum, TagOutID, and WoSafetyDataSource.

    The attributes in this object are as follows:

    Attribute NameDescription
    AssetDescriptionNon-persistent attribute. If AssetNum or Location is not null, this equals the description of the asset or location.
    DescriptionFreeform description. Also accommodates a long description.
    AssetNumAsset number to be tagged out. Foreign key to Asset.
    Either AssetNum or Location may be specified (not both).
    HazardIDNon-persistent attribute. The HazardID that owns this tagout, from wosafetylink.
    LocationLocation to be tagged out. Foreign key to Location.
    Either AssetNum or Location may be specified (not both).
    OrgIDThe organization for this site, stored on this table for ease of access. This equals the value for OrgID specified on the Site table.
    RequiredStateIdentifies the condition of the asset when tagged out.
    SiteIDThe site to which this record pertains. Foreign key to Site.
    TagOutIDMain identifier for this object. May be foreign key to TagOut.
    WoNumForeign key to Workorder.
    WoSafetyDataSourceSee Work Order Safety Mbos Overview.
    See Also:
    WOService.tagoutsMustBelongToHazards()
    • Constructor Detail

      • WoTagOut

        public WoTagOut(MboSet ms)
                 throws MXException,
                        java.rmi.RemoteException
        Construct the WoTagOut object
        Throws:
        MXException
        java.rmi.RemoteException
    • Method Detail

      • add

        public void add()
                 throws MXException,
                        java.rmi.RemoteException
        Add a mbo, defaulting the attributes shown below. Owner can be Workorder or WoSafetyLink.
        Attribute NameAttribute Value
        TagOutIDIf owner is WoSafetyLink, equals the owner's TagOutID.
        WoNumOwner's WoNum
        WoSafetyDataSourceIf owner is WoSafetyLink, equals the owner's WoSafetyDataSource.
        Specified by:
        add in interface MboRemote
        Overrides:
        add in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • delete

        public void delete(long accessModifier)
                    throws MXException,
                           java.rmi.RemoteException
        Delete all WoTagLock for this WoTagOut.
        Specified by:
        delete in interface MboRemote
        Overrides:
        delete in class Mbo
        Parameters:
        accessModifier - The bitwise flag specified to determine if certain normal security checks are to be bypassed for this delete request. For example: if the accessModifer is NOACCESSCHECK, then the check for the object's NODELETE flag and the call to the object's canDelete() method will not be performed. If the accessModifer is NONE, then all the access checks are performed before this object is marked delete.
        Throws:
        MXException
        java.rmi.RemoteException
        See Also:
        Mbo.delete(long)
      • undelete

        public void undelete()
                      throws MXException,
                             java.rmi.RemoteException
        Description copied from class: Mbo
        Unmark the Mbo for deletion. Can only be called after a delete() and before the save() has been performed. This method will also unmark associated Long Description and Translation Mbos.
        Specified by:
        undelete in interface MboRemote
        Overrides:
        undelete in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • appValidate

        public void appValidate()
                         throws MXException,
                                java.rmi.RemoteException
        Application validation routine. If manually adding a wotagout to the workorder and we don't have a WoSafetyLink virtual owner, add row to WoSafetyLink.
        Overrides:
        appValidate in class Mbo
        Throws:
        MXException
        java.rmi.RemoteException
      • skipCopyField

        protected boolean skipCopyField(MboValueInfo mvi)
                                 throws java.rmi.RemoteException,
                                        MXException
        This method overrides the skipCopyField() in the Mbo.Since this method takes the MboValueInfo as its parameter just check to see if this field needs to be copied or skipped.If this field does not need to be copied return true. The following is a list of fields that are not copied from the source WOTagOut to the target WOTagOut.
        1. WONUM
        Overrides:
        skipCopyField in class Mbo
        Parameters:
        - - The MboValueInfo object of the MboValue that needs to be copied.
        Returns:
        - True,if the field does not need to be copied.In all other cases return false.
        Throws:
        MXException
        java.rmi.RemoteException