Beispiel #1
0
 ///
 ///	 <summary> * Set attribute refID to the ID of previous </summary>
 ///
 public virtual void setRef(JDFAudit previous)
 {
     if (previous != null)
     {
         string id = previous.appendAnchor(null); // ensure that previos has
         // an id
         setrefID(id);
     }
 }
Beispiel #2
0
        ///
        ///	 <summary> * init this comment by adding agentname, agentversion and id
        ///	 *  </summary>
        ///	 * <returns> boolean </returns>
        ///
        public override bool init()
        {
            EnumVersion v = getVersion(true);

            if (v.getValue() >= EnumVersion.Version_1_3.getValue() && LocalName.Equals(ElementName.COMMENT))
            {
                appendAnchor(null);
                setAgentName(JDFAudit.getStaticAgentName());
                setAgentVersion(JDFAudit.getStaticAgentVersion());
            }
            return(base.init());
        }
Beispiel #3
0
        ///
        ///	 <summary> * create an update audit for this
        ///	 *
        ///	 * @return </summary>
        ///
        public virtual JDFAudit createUpdateAudit()
        {
            JDFAuditPool pool = getAuditPool();

            if (pool == null)
            {
                return(null);
            }
            JDFAudit copy = (JDFAudit)pool.copyElement(this, null);

            copy.removeAttribute(AttributeName.ID);
            copy.removeAttribute(AttributeName.AGENTNAME);
            copy.removeAttribute(AttributeName.AGENTVERSION);
            copy.init();
            copy.setRef(this);
            return(copy);
        }