private void copyDCENamespace(IDCTagNS_DCE _in, IDCTagNS_DCE _out, asset _asset) { if (_asset._astate.condActive.statekey == "RUN") { _out.UpReason.valueLong = _asset.CondCur.RootReasonCode.valueLong; _out.Reason.valueLong = 0; } else { //if (_asset.DCE.Reason.valueLong > 0) _out.UpReason.valueLong = 0; _out.Reason.valueLong = _asset.CondCur.RootReasonCode.valueLong; } _out.StartCount.valueLong = _in.StartCount.valueLong; _out.EndCount.valueLong = _in.EndCount.valueLong; _out.State.valueLong = _in.State.valueLong; _out.RunStatus.valueBool = _in.RunStatus.valueBool; _out.EventTerminate.valueBool = _in.EventTerminate.valueBool; }
public static bool LoadFromFile(string fileName, out asset obj) { System.Exception exception = null; return LoadFromFile(fileName, out obj, out exception); }
public static bool Deserialize(string input, out asset obj) { System.Exception exception = null; return Deserialize(input, out obj, out exception); }
/// <summary> /// Deserializes xml markup from file into an asset object /// </summary> /// <param name="fileName">string xml file to load and deserialize</param> /// <param name="obj">Output asset object</param> /// <param name="exception">output Exception value if deserialize failed</param> /// <returns>true if this Serializer can deserialize the object; otherwise, false</returns> public static bool LoadFromFile(string fileName, out asset obj, out System.Exception exception) { exception = null; obj = default(asset); try { obj = LoadFromFile(fileName); return true; } catch (System.Exception ex) { exception = ex; return false; } }
/// <summary> /// Deserializes workflow markup into an asset object /// </summary> /// <param name="input">string workflow markup to deserialize</param> /// <param name="obj">Output asset object</param> /// <param name="exception">output Exception value if deserialize failed</param> /// <returns>true if this Serializer can deserialize the object; otherwise, false</returns> public static bool Deserialize(string input, out asset obj, out System.Exception exception) { exception = null; obj = default(asset); try { obj = Deserialize(input); return true; } catch (System.Exception ex) { exception = ex; return false; } }