|
@@ -164,59 +164,91 @@ namespace MeasureData
|
|
|
m_opt = Operation.Init;
|
|
|
m_state = State.Unmeasured;
|
|
|
m_switch = false;
|
|
|
+ Position = new SemPosition();
|
|
|
}
|
|
|
|
|
|
//样品孔存储xml文档
|
|
|
public override void Serialize(bool isStoring, XmlDocument xml, XmlNode rootNode)
|
|
|
{
|
|
|
|
|
|
- Slo<CutHole> slo = new Slo<CutHole> ();
|
|
|
+ Slo<CutHole> slo_cuthole = new Slo<CutHole>();
|
|
|
+
|
|
|
+ xString regName = new xString();
|
|
|
+ regName.AssignValue("CutHole");
|
|
|
+ slo_cuthole.Register("RegName", regName);
|
|
|
+
|
|
|
//样品名称
|
|
|
xString SampleName = new xString();
|
|
|
SampleName.AssignValue(this.SampleName);
|
|
|
- slo.Register("SampleName", SampleName);
|
|
|
+ slo_cuthole.Register("SampleName", SampleName);
|
|
|
+
|
|
|
+ Slo<SemPosition> slo_sp = new Slo<SemPosition>();
|
|
|
+ xDouble ptx = new xDouble();
|
|
|
+ ptx.AssignValue(this.Position.X);
|
|
|
+ slo_sp.Register("X", ptx);
|
|
|
+
|
|
|
+ xDouble pty = new xDouble();
|
|
|
+ pty.AssignValue(this.Position.X);
|
|
|
+ slo_sp.Register("Y", pty);
|
|
|
+
|
|
|
+ xDouble ptz = new xDouble();
|
|
|
+ ptz.AssignValue(this.Position.Z);
|
|
|
+ slo_sp.Register("Z", ptz);
|
|
|
+
|
|
|
+ xDouble ptt = new xDouble();
|
|
|
+ ptt.AssignValue(this.Position.T);
|
|
|
+ slo_sp.Register("T", ptt);
|
|
|
+
|
|
|
+ xDouble ptr = new xDouble();
|
|
|
+ ptr.AssignValue(this.Position.R);
|
|
|
+ slo_sp.Register("R", ptr);
|
|
|
+
|
|
|
+ xDouble ptm = new xDouble();
|
|
|
+ ptx.AssignValue(this.Position.M);
|
|
|
+ slo_sp.Register("M", ptm);
|
|
|
+ slo_cuthole.Register("Position", slo_sp);
|
|
|
|
|
|
//是否有PT沉积
|
|
|
xBool PT = new xBool();
|
|
|
PT.AssignValue(this.PT);
|
|
|
- slo.Register("PT", PT);
|
|
|
+ slo_cuthole.Register("PT", PT);
|
|
|
//FIB工作模板
|
|
|
xString FIBTemp = new xString();
|
|
|
FIBTemp.AssignValue(this.FIBTemp);
|
|
|
- slo.Register("FIBTemp", FIBTemp);
|
|
|
+ slo_cuthole.Register("FIBTemp", FIBTemp);
|
|
|
//PT工作模板
|
|
|
xString PTTemp = new xString();
|
|
|
PTTemp.AssignValue(this.PTTemp);
|
|
|
- slo.Register("PTTemp", PTTemp);
|
|
|
+ slo_cuthole.Register("PTTemp", PTTemp);
|
|
|
|
|
|
//操作步骤
|
|
|
xInt OPT = new xInt();
|
|
|
OPT.AssignValue(this.OPT.GetHashCode());
|
|
|
- slo.Register("OPT", OPT);
|
|
|
+ slo_cuthole.Register("OPT", OPT);
|
|
|
//开始时间
|
|
|
xTime_t START = new xTime_t();
|
|
|
START.AssignValue(this.START);
|
|
|
- slo.Register("START", START);
|
|
|
+ slo_cuthole.Register("START", START);
|
|
|
//结束时间
|
|
|
xTime_t END = new xTime_t();
|
|
|
END.AssignValue(this.END);
|
|
|
- slo.Register("END", END);
|
|
|
+ slo_cuthole.Register("END", END);
|
|
|
//测量结果
|
|
|
xInt STATE = new xInt();
|
|
|
STATE.AssignValue(this.STATE.GetHashCode());
|
|
|
- slo.Register("STATE", STATE);
|
|
|
+ slo_cuthole.Register("STATE", STATE);
|
|
|
//测量开关
|
|
|
xBool SWITCH = new xBool();
|
|
|
SWITCH.AssignValue(this.SWITCH);
|
|
|
- slo.Register("SWITCH", SWITCH);
|
|
|
+ slo_cuthole.Register("SWITCH", SWITCH);
|
|
|
|
|
|
if (isStoring)
|
|
|
{
|
|
|
- slo.Serialize(true, xml, rootNode);
|
|
|
+ slo_cuthole.Serialize(true, xml, rootNode);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- slo.Serialize(false, xml, rootNode);
|
|
|
+ slo_cuthole.Serialize(false, xml, rootNode);
|
|
|
|
|
|
this.SampleName = SampleName.value();
|
|
|
this.PT = PT.value();
|
|
@@ -227,9 +259,15 @@ namespace MeasureData
|
|
|
this.END = END.value();
|
|
|
this.STATE = (State)STATE.value();
|
|
|
this.SWITCH = SWITCH.value();
|
|
|
+ this.Position.X = (float)ptx.value();
|
|
|
+ this.Position.Y = (float)pty.value();
|
|
|
+ this.Position.Z = (float)ptz.value();
|
|
|
+ this.Position.T = (float)ptt.value();
|
|
|
+ this.Position.R = (float)ptr.value();
|
|
|
+ this.Position.M = (float)ptm.value();
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
}
|
|
|
|
|
|
}
|