Updating to latest Dev
This commit is contained in:
commit
a8033f3e51
527 files changed
+40243
-92852
No files matched your search
@@ -1,40 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Xml;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
public class Comparator
|
||||
{
|
||||
private XmlDocument _ResultsDoc;
|
||||
public XmlDocument ResultsDoc
|
||||
{
|
||||
get { return _ResultsDoc; }
|
||||
set { _ResultsDoc = value; }
|
||||
}
|
||||
private XmlDocument _XDoc1;
|
||||
public XmlDocument XDoc1
|
||||
{
|
||||
get { return _XDoc1; }
|
||||
set { _XDoc1 = value; }
|
||||
}
|
||||
private XmlDocument _XDoc2;
|
||||
public XmlDocument XDoc2
|
||||
{
|
||||
get { return _XDoc2; }
|
||||
set { _XDoc2 = value; }
|
||||
}
|
||||
public Comparator(XmlDocument xdoc1, XmlDocument xdoc2)
|
||||
public XmlDocument ResultsDoc { get; set; }
|
||||
public XmlDocument XDoc1 { get; set; }
|
||||
public XmlDocument XDoc2 { get; set; }
|
||||
public Comparator(XmlDocument xdoc1, XmlDocument xdoc2)
|
||||
{
|
||||
XDoc1 = xdoc1;
|
||||
XDoc2 = xdoc2;
|
||||
ResultsDoc = new XmlDocument();
|
||||
ResultsDoc.LoadXml(@"<PlantFormat></PlantFormat>");
|
||||
}
|
||||
public Comparator(string existingFC, string importedFC) //string fName1, string fName2)
|
||||
public Comparator(string existingFC, string importedFC)
|
||||
{
|
||||
XDoc1 = new XmlDocument();
|
||||
XDoc1.LoadXml(existingFC);
|
||||
@@ -104,12 +87,12 @@ namespace VEPROMS.CSLA.Library
|
||||
xnss1.Add(GetKey(xc1), xc1);
|
||||
foreach (XmlNode xc2 in xns2.Values)
|
||||
if (xnss1.ContainsKey(GetKey(xc2)))
|
||||
Compare(xnss1[GetKey(xc2)], xc2, path + "/" + GetKey(xc2));
|
||||
Compare(xnss1[GetKey(xc2)], xc2, $"{path}/{GetKey(xc2)}");
|
||||
else
|
||||
xnss2.Add(GetKey(xc2), xc2);
|
||||
// element differences, if counts are different. xns1 elements are not found in xns2 and xns2 elements are not found in xns1
|
||||
if (xns1.Count == 0 && xns2.Count == 0) return;
|
||||
Console.WriteLine(" {0} {1} {2}", path + "/" + xn1.Name, xns1.Count, xns2.Count);
|
||||
Console.WriteLine($" {path}/{xn1.Name} {xns1.Count} {xns2.Count}");
|
||||
foreach (string key in xnss1.Keys)
|
||||
{
|
||||
if (xnss1[key].Attributes.Count > 0 || xnss1[key].ChildNodes.Count > 0)
|
||||
@@ -210,18 +193,14 @@ namespace VEPROMS.CSLA.Library
|
||||
public string GetKey1(XmlNode xn)
|
||||
{
|
||||
if (xn.Attributes == null) return xn.Name;
|
||||
XmlAttribute xi = xn.Attributes.GetNamedItem("Index") as XmlAttribute;
|
||||
if (xi != null)
|
||||
{
|
||||
XmlAttribute xa = xn.Attributes.GetNamedItem("Name") as XmlAttribute;
|
||||
if (xa != null) return string.Format("{0}[{1}]", xn.Name, xa.Value);
|
||||
return string.Format("{0}[{1}]", xn.Name, xi.Value);
|
||||
}
|
||||
XmlAttribute xt = xn.Attributes.GetNamedItem("Token") as XmlAttribute;
|
||||
if(xt != null) return string.Format("{0}[{1}]", xn.Name, xt.Value);
|
||||
XmlAttribute xw = xn.Attributes.GetNamedItem("ReplaceWord") as XmlAttribute;
|
||||
if(xw != null) return string.Format("{0}[{1}]", xn.Name, xw.Value);
|
||||
return xn.Name;
|
||||
if (xn.Attributes.GetNamedItem("Index") is XmlAttribute xi)
|
||||
{
|
||||
if (xn.Attributes.GetNamedItem("Name") is XmlAttribute xa) return string.Format("{0}[{1}]", xn.Name, xa.Value);
|
||||
return string.Format("{0}[{1}]", xn.Name, xi.Value);
|
||||
}
|
||||
if (xn.Attributes.GetNamedItem("Token") is XmlAttribute xt) return string.Format("{0}[{1}]", xn.Name, xt.Value);
|
||||
if (xn.Attributes.GetNamedItem("ReplaceWord") is XmlAttribute xw) return string.Format("{0}[{1}]", xn.Name, xw.Value);
|
||||
return xn.Name;
|
||||
}
|
||||
static private XmlNode makeXPath(XmlDocument doc, string xpath)
|
||||
{
|
||||
@@ -252,7 +231,6 @@ namespace VEPROMS.CSLA.Library
|
||||
string name = nextNodeInXPath.Substring(indx, nextNodeInXPath.IndexOf("=",indx)-indx);
|
||||
XmlAttribute xKeyd = doc.CreateAttribute(name);
|
||||
indx = nextNodeInXPath.IndexOf("='",indx)+2;
|
||||
string value = nextNodeInXPath.Substring(indx,nextNodeInXPath.IndexOf("'", indx) - indx);
|
||||
xKeyd.Value = nextNodeInXPath.Substring(indx,nextNodeInXPath.IndexOf("'",indx)-indx);
|
||||
node.Attributes.Append(xKeyd);
|
||||
}
|
||||
@@ -277,58 +255,56 @@ namespace VEPROMS.CSLA.Library
|
||||
// go through attributes in first xml document, see if they exist in the 2nd xml document & are identical attribute
|
||||
foreach (XmlAttribute xa1 in atts1)
|
||||
{
|
||||
XmlAttribute xa2 = atts2.GetNamedItem(xa1.Name) as XmlAttribute;
|
||||
if (xa2 == null)
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa1.Name+"Old");
|
||||
xKey.Value = xa1.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("OldKey");
|
||||
xKey.Value = GetKey(atts1Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
else if (xa2.Value != xa1.Value)
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa1.Name + "Old");
|
||||
xKey.Value = xa1.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
XmlAttribute xKey2 = ResultsDoc.CreateAttribute(xa2.Name + "New");
|
||||
xKey2.Value = xa2.Value;
|
||||
xnr.Attributes.Append(xKey2);
|
||||
xKey = ResultsDoc.CreateAttribute("OldKey");
|
||||
xKey.Value = GetKey(atts1Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("NewKey");
|
||||
xKey.Value = GetKey(atts2Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!(atts2.GetNamedItem(xa1.Name) is XmlAttribute xa2))
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa1.Name + "Old");
|
||||
xKey.Value = xa1.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("OldKey");
|
||||
xKey.Value = GetKey(atts1Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
else if (xa2.Value != xa1.Value)
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa1.Name + "Old");
|
||||
xKey.Value = xa1.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
XmlAttribute xKey2 = ResultsDoc.CreateAttribute(xa2.Name + "New");
|
||||
xKey2.Value = xa2.Value;
|
||||
xnr.Attributes.Append(xKey2);
|
||||
xKey = ResultsDoc.CreateAttribute("OldKey");
|
||||
xKey.Value = GetKey(atts1Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("NewKey");
|
||||
xKey.Value = GetKey(atts2Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
}
|
||||
// go through attributes in 2nd xml document to see if they exist in the first xml document & are identical
|
||||
foreach (XmlAttribute xa2 in atts2)
|
||||
{
|
||||
XmlAttribute xa1 = atts1.GetNamedItem(xa2.Name) as XmlAttribute;
|
||||
if (xa1 == null)
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa2.Name+"New");
|
||||
xKey.Value = xa2.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("NewKey");
|
||||
xKey.Value = GetKey(atts2Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!(atts1.GetNamedItem(xa2.Name) is XmlAttribute))
|
||||
{
|
||||
XmlNode xnr = MakeXPathFormat(path);
|
||||
if (xnr != null)
|
||||
{
|
||||
XmlAttribute xKey = ResultsDoc.CreateAttribute(xa2.Name + "New");
|
||||
xKey.Value = xa2.Value;
|
||||
xnr.Attributes.Append(xKey);
|
||||
xKey = ResultsDoc.CreateAttribute("NewKey");
|
||||
xKey.Value = GetKey(atts2Par);
|
||||
if (xKey.Value != null) xnr.Attributes.Append(xKey);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -1,8 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Xml;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.ComponentModel;
|
||||
using System.Xml;
|
||||
using System.Linq;
|
||||
@@ -32,54 +31,27 @@ namespace VEPROMS.CSLA.Library
|
||||
private LazyLoad<string> _Name;
|
||||
[DisplayName("Name")]
|
||||
[Description("EP Viewer File Name")]
|
||||
public string Name
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Name, "@Name");
|
||||
}
|
||||
}
|
||||
public string Name => LazyLoad(ref _Name, "@Name");
|
||||
// Name of the EP Viewer Format File
|
||||
private LazyLoad<string> _Description;
|
||||
[DisplayName("Description")]
|
||||
[Description("EP Viewer Description")]
|
||||
public string Description
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Description, "@Description");
|
||||
}
|
||||
}
|
||||
public string Description => LazyLoad(ref _Description, "@Description");
|
||||
// Id of Annotation Type Associated with this file
|
||||
private LazyLoad<int?> _AnnotationTypeID;
|
||||
[DisplayName("AnnotationTypeID")]
|
||||
[Description("Id of Annotation Type Associated with this file")]
|
||||
public int? AnnotationTypeID
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _AnnotationTypeID, "@AnnotationTypeID");
|
||||
}
|
||||
}
|
||||
public int? AnnotationTypeID => LazyLoad(ref _AnnotationTypeID, "@AnnotationTypeID");
|
||||
|
||||
// Return Name of Annotation that EP Format File is Attached to
|
||||
public string AnnotationName()
|
||||
{
|
||||
return AnnotationTypeInfo.Get((int) AnnotationTypeID).Name;
|
||||
}
|
||||
public string AnnotationName() => AnnotationTypeInfo.Get((int)AnnotationTypeID).Name;
|
||||
|
||||
//if xml value is blank, should element export?
|
||||
//defaults to true
|
||||
private LazyLoad<bool> _exportblank;
|
||||
[DisplayName("exportblank")]
|
||||
[Description("if xml value is blank, should element export?")]
|
||||
public bool exportblank
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _exportblank, "@exportblank");
|
||||
}
|
||||
}
|
||||
public bool exportblank => LazyLoad(ref _exportblank, "@exportblank");
|
||||
// returns a list of fields that are defined in the EP format's structure
|
||||
private EPFields _FieldList;
|
||||
public EPFields FieldList
|
||||
@@ -141,8 +113,10 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
if (dr.Read())
|
||||
{
|
||||
XmlDocument xd = new XmlDocument();
|
||||
xd.XmlResolver = null;
|
||||
XmlDocument xd = new XmlDocument
|
||||
{
|
||||
XmlResolver = null
|
||||
};
|
||||
xd.LoadXml(dr.GetString("Data"));
|
||||
return xd;
|
||||
}
|
||||
@@ -255,21 +229,9 @@ namespace VEPROMS.CSLA.Library
|
||||
public EPField(XmlNode xmlNode) : base(xmlNode) { }
|
||||
public EPField() : base() { }
|
||||
private LazyLoad<string> _name;
|
||||
public string name
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _name, "@name");
|
||||
}
|
||||
}
|
||||
public string name => LazyLoad(ref _name, "@name");
|
||||
private LazyLoad<string> _type;
|
||||
public string type
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _type, "@type");
|
||||
}
|
||||
}
|
||||
public string type => LazyLoad(ref _type, "@type");
|
||||
private LazyLoad<string> _label;
|
||||
public string label
|
||||
{
|
||||
@@ -284,22 +246,10 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
}
|
||||
private LazyLoad<string> _text;
|
||||
public string text
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _text, "@text");
|
||||
}
|
||||
}
|
||||
public string text => LazyLoad(ref _text, "@text");
|
||||
//roid of group item that individual sub-items will be the choices for the list/combobox for ROSINGLE and ROMULTI
|
||||
private LazyLoad<string> _rosource;
|
||||
public string rosource
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _rosource, "@rosource");
|
||||
}
|
||||
}
|
||||
public string rosource => LazyLoad(ref _rosource, "@rosource");
|
||||
//the columns in the RO that will be included in the exports
|
||||
private LazyLoad<string> _returncols;
|
||||
public List<string> returncols()
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.ComponentModel;
|
||||
using System.Xml;
|
||||
|
||||
@@ -23,44 +20,23 @@ namespace VEPROMS.CSLA.Library
|
||||
#region Business Methods
|
||||
// description to associate with a DocStyle
|
||||
private LazyLoad<string> _Name;
|
||||
[DisplayName("Name")]
|
||||
[Description("Page Style Name")]
|
||||
public string Name
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Name, "@Name");
|
||||
}
|
||||
}
|
||||
[DisplayName("Name")]
|
||||
[Description("Page Style Name")]
|
||||
public string Name => LazyLoad(ref _Name, "@Name");
|
||||
|
||||
// a unuque number that is referenced from the DocStyles
|
||||
private LazyLoad<int?> _Index;
|
||||
[DisplayName("Index")]
|
||||
[Description("Page Style Index")]
|
||||
public int? Index
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Index, "@Index");
|
||||
}
|
||||
}
|
||||
// a unuque number that is referenced from the DocStyles
|
||||
private LazyLoad<int?> _Index;
|
||||
[DisplayName("Index")]
|
||||
[Description("Page Style Index")]
|
||||
public int? Index => LazyLoad(ref _Index, "@Index");
|
||||
|
||||
private PageItems _PageItems;
|
||||
public PageItems PageItems
|
||||
{
|
||||
get
|
||||
{
|
||||
return (_PageItems == null)? _PageItems = new PageItems(SelectNodes("Item")): _PageItems;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
#region Override ToString
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("{0:D2} - {1}", Index, Name);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
private PageItems _PageItems;
|
||||
public PageItems PageItems => _PageItems ?? (_PageItems = new PageItems(SelectNodes("Item")));
|
||||
#endregion
|
||||
#region Override ToString
|
||||
public override string ToString() => string.Format("{0:D2} - {1}", Index, Name);
|
||||
#endregion
|
||||
}
|
||||
#endregion
|
||||
#region PageItems
|
||||
[TypeConverter(typeof(vlnListConverter<PageItems, PageItem>))]
|
||||
@@ -79,192 +55,91 @@ namespace VEPROMS.CSLA.Library
|
||||
#endregion
|
||||
#region Business Methods
|
||||
private VE_Font _Font;
|
||||
[Category("Font")]
|
||||
[DisplayName("Font")]
|
||||
[Description("Font")]
|
||||
public VE_Font Font
|
||||
{
|
||||
get
|
||||
{
|
||||
return (_Font == null) ?_Font = new VE_Font(XmlNode): _Font;
|
||||
}
|
||||
}
|
||||
private RelatedItem _RelatedItem;
|
||||
public RelatedItem RelatedItem
|
||||
{
|
||||
get
|
||||
{
|
||||
return (_RelatedItem == null) ? _RelatedItem = new RelatedItem(SelectSingleNode("RelatedItem")) : _RelatedItem;
|
||||
}
|
||||
}
|
||||
[Category("Font")]
|
||||
[DisplayName("Font")]
|
||||
[Description("Font")]
|
||||
public VE_Font Font => _Font ?? (_Font = new VE_Font(XmlNode));
|
||||
private RelatedItem _RelatedItem;
|
||||
public RelatedItem RelatedItem => _RelatedItem ?? (_RelatedItem = new RelatedItem(SelectSingleNode("RelatedItem")));
|
||||
|
||||
// this can be an actual token, in curly braces, that dynamically gets replaced with information, or just plain text
|
||||
private LazyLoad<string> _Token;
|
||||
[Category("Content")]
|
||||
[DisplayName("Content")]
|
||||
[Description("Item Content")]
|
||||
public string Token
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Token, "@Token");
|
||||
}
|
||||
}
|
||||
// this can be an actual token, in curly braces, that dynamically gets replaced with information, or just plain text
|
||||
private LazyLoad<string> _Token;
|
||||
[Category("Content")]
|
||||
[DisplayName("Content")]
|
||||
[Description("Item Content")]
|
||||
public string Token => LazyLoad(ref _Token, "@Token");
|
||||
|
||||
// the row on the page to place the Item
|
||||
private LazyLoad<float?> _Row;
|
||||
[Category("Location")]
|
||||
[DisplayName("Vertical Position")]
|
||||
[Description("Vertical Position")]
|
||||
public float? Row
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Row, "@Row");
|
||||
}
|
||||
}
|
||||
// the row on the page to place the Item
|
||||
private LazyLoad<float?> _Row;
|
||||
[Category("Location")]
|
||||
[DisplayName("Vertical Position")]
|
||||
[Description("Vertical Position")]
|
||||
public float? Row => LazyLoad(ref _Row, "@Row");
|
||||
|
||||
// the column on the page to place the Item
|
||||
private LazyLoad<float?> _Col;
|
||||
[Category("Location")]
|
||||
[DisplayName("Horizontal Position")]
|
||||
[Description("Horizontal Position")]
|
||||
public float? Col
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Col, "@Col");
|
||||
}
|
||||
}
|
||||
// the column on the page to place the Item
|
||||
private LazyLoad<float?> _Col;
|
||||
[Category("Location")]
|
||||
[DisplayName("Horizontal Position")]
|
||||
[Description("Horizontal Position")]
|
||||
public float? Col => LazyLoad(ref _Col, "@Col");
|
||||
|
||||
// the justification at the Col position in which to print the Token information
|
||||
private LazyLoad<E_Justify?> _Justify;
|
||||
public E_Justify? Justify
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad<E_Justify>(ref _Justify, "@Justify");
|
||||
}
|
||||
}
|
||||
// the justification at the Col position in which to print the Token information
|
||||
private LazyLoad<E_Justify?> _Justify;
|
||||
public E_Justify? Justify => LazyLoad<E_Justify>(ref _Justify, "@Justify");
|
||||
|
||||
//run the PROMS Replace Words logic on the resulting text of Token
|
||||
private LazyLoad<bool> _RepWords; // F2021-053: Do replace words in page list
|
||||
public bool RepWords
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _RepWords, "@RepWords");
|
||||
}
|
||||
}
|
||||
//run the PROMS Replace Words logic on the resulting text of Token
|
||||
private LazyLoad<bool> _RepWords; // F2021-053: Do replace words in page list
|
||||
public bool RepWords => LazyLoad(ref _RepWords, "@RepWords");
|
||||
|
||||
//Flag to tell PROMS to get the alarm value information based on the specified Child applicability
|
||||
private LazyLoad<bool> _ROLkUpMatch; // C2021-065 (BNPP Alarms format)
|
||||
public bool ROLkUpMatch
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _ROLkUpMatch, "@ROLkUpMatch");
|
||||
}
|
||||
}
|
||||
//Flag to tell PROMS to get the alarm value information based on the specified Child applicability
|
||||
private LazyLoad<bool> _ROLkUpMatch; // C2021-065 (BNPP Alarms format)
|
||||
public bool ROLkUpMatch => LazyLoad(ref _ROLkUpMatch, "@ROLkUpMatch");
|
||||
|
||||
// Flag to specify if that PageStyle Item should be used in creating alarm point information
|
||||
// for viewing in the PROMS step editor
|
||||
// this information is displayed in a Note that it build on the fly when first opening an Alarm Point page
|
||||
private LazyLoad<bool> _ROLkUpInEditor; // C2021-018 (BNPP Alarms format)
|
||||
public bool ROLkUpInEditor
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _ROLkUpInEditor, "@ROLkUpInEditor");
|
||||
}
|
||||
}
|
||||
// Flag to specify if that PageStyle Item should be used in creating alarm point information
|
||||
// for viewing in the PROMS step editor
|
||||
// this information is displayed in a Note that it build on the fly when first opening an Alarm Point page
|
||||
private LazyLoad<bool> _ROLkUpInEditor; // C2021-018 (BNPP Alarms format)
|
||||
public bool ROLkUpInEditor => LazyLoad(ref _ROLkUpInEditor, "@ROLkUpInEditor");
|
||||
|
||||
// defines a maxium width before the resolved PSI token (procedure specific information) text is wrapped
|
||||
// on to the next line
|
||||
private LazyLoad<int?> _MaxWidth;
|
||||
public int? MaxWidth
|
||||
{
|
||||
get
|
||||
{
|
||||
return (LazyLoad(ref _MaxWidth, "@MaxWidth"));
|
||||
}
|
||||
}
|
||||
// defines a maxium width before the resolved PSI token (procedure specific information) text is wrapped
|
||||
// on to the next line
|
||||
private LazyLoad<int?> _MaxWidth;
|
||||
public int? MaxWidth => LazyLoad(ref _MaxWidth, "@MaxWidth");
|
||||
|
||||
// MaxWidth, above, flagged that, if there was more than 1 line, the topmargin would be adjusted by however
|
||||
// many lines the PSI item contained (for wst alarms). The MaxWidthCurPage is used when that adjustment
|
||||
// should not be made, the length of the PSI item is only relevant for the current page.
|
||||
// (see AdjustTopMarginForMultiLinePageListItems variable and how it is used)
|
||||
private LazyLoad<int?> _MaxWidthCurPage;
|
||||
public int? MaxWidthCurPage
|
||||
{
|
||||
get
|
||||
{
|
||||
return (LazyLoad(ref _MaxWidthCurPage, "@MaxWidthCurPage"));
|
||||
}
|
||||
}
|
||||
// MaxWidth, above, flagged that, if there was more than 1 line, the topmargin would be adjusted by however
|
||||
// many lines the PSI item contained (for wst alarms). The MaxWidthCurPage is used when that adjustment
|
||||
// should not be made, the length of the PSI item is only relevant for the current page.
|
||||
// (see AdjustTopMarginForMultiLinePageListItems variable and how it is used)
|
||||
private LazyLoad<int?> _MaxWidthCurPage;
|
||||
public int? MaxWidthCurPage => LazyLoad(ref _MaxWidthCurPage, "@MaxWidthCurPage");
|
||||
|
||||
// the resolved pagestype item font size will be reduce in order to fit within the defined width
|
||||
private LazyLoad<int?> _FontShrinkAftLen; // F2021-066 & 070 (text len before shrinking font)
|
||||
public int? FontShrinkAftLen
|
||||
{
|
||||
get
|
||||
{
|
||||
return (LazyLoad(ref _FontShrinkAftLen, "@FontShrinkAftLen"));
|
||||
}
|
||||
}
|
||||
// the resolved pagestype item font size will be reduce in order to fit within the defined width
|
||||
private LazyLoad<int?> _FontShrinkAftLen; // F2021-066 & 070 (text len before shrinking font)
|
||||
public int? FontShrinkAftLen => LazyLoad(ref _FontShrinkAftLen, "@FontShrinkAftLen");
|
||||
|
||||
// used in Alarm Point Table page style values with FontShrinkAftLen set, will display this message if the text cannot be shrunk enough (and be readable) to fit within the defined width
|
||||
private LazyLoad<string> _FontTooSmallMsg; // F2021-066 message if can't shrink enough
|
||||
public string FontTooSmallMsg
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _FontTooSmallMsg, "@FontTooSmallMsg");
|
||||
}
|
||||
}
|
||||
// used in Alarm Point Table page style values with FontShrinkAftLen set, will display this message if the text cannot be shrunk enough (and be readable) to fit within the defined width
|
||||
private LazyLoad<string> _FontTooSmallMsg; // F2021-066 message if can't shrink enough
|
||||
public string FontTooSmallMsg => LazyLoad(ref _FontTooSmallMsg, "@FontTooSmallMsg");
|
||||
|
||||
// F2023-039 allow to select text color of a pagelist line
|
||||
// sets a text color for the page style Item
|
||||
private LazyLoad<string> _TextColor;
|
||||
public string TextColor
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _TextColor, "@TextColor");
|
||||
}
|
||||
}
|
||||
// F2023-039 allow to select text color of a pagelist line
|
||||
// sets a text color for the page style Item
|
||||
private LazyLoad<string> _TextColor;
|
||||
public string TextColor => LazyLoad(ref _TextColor, "@TextColor");
|
||||
|
||||
// set to a string, will remove the matching string from the end
|
||||
// F2023-112 Vogtle Units 3 & Backgrounds - trim the ending "-B" from the procedure number (used in title box of page header)
|
||||
private LazyLoad<string> _TrimEnding;
|
||||
public string TrimEnding
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _TrimEnding, "@TrimEnding");
|
||||
}
|
||||
}
|
||||
// C2025-033 to specify to print pagestyle item for a specific Child procedure
|
||||
private LazyLoad<int?> _ChildNum;
|
||||
public int? ChildNum
|
||||
{
|
||||
get
|
||||
{
|
||||
return (LazyLoad(ref _ChildNum, "@ChildNum"));
|
||||
}
|
||||
}
|
||||
// set to a string, will remove the matching string from the end
|
||||
// F2023-112 Vogtle Units 3 & Backgrounds - trim the ending "-B" from the procedure number (used in title box of page header)
|
||||
private LazyLoad<string> _TrimEnding;
|
||||
public string TrimEnding => LazyLoad(ref _TrimEnding, "@TrimEnding");
|
||||
// C2025-033 to specify to print pagestyle item for a specific Child procedure
|
||||
private LazyLoad<int?> _ChildNum;
|
||||
public int? ChildNum => LazyLoad(ref _ChildNum, "@ChildNum");
|
||||
|
||||
#endregion
|
||||
#region Override ToString
|
||||
public override string ToString()
|
||||
{
|
||||
//return string.Format("({0:D5},{1:D5}) - {2}",Row,Col,Token);
|
||||
return Token;
|
||||
}
|
||||
public override string GetPDDisplayName()
|
||||
{ return string.Format("({0},{1})",Row,Col); }
|
||||
#endregion
|
||||
}
|
||||
#endregion
|
||||
#region Override ToString
|
||||
public override string ToString() => Token;
|
||||
public override string GetPDDisplayName() => string.Format("({0},{1})", Row, Col);
|
||||
#endregion
|
||||
}
|
||||
#endregion
|
||||
#region RelatedItem
|
||||
// RelatedItem was added to allow a PSI logical to have an associated PSI item, and if both are
|
||||
@@ -281,53 +156,29 @@ namespace VEPROMS.CSLA.Library
|
||||
|
||||
// the name of the PSI logical token to check
|
||||
private LazyLoad<string> _Token;
|
||||
[Category("RelatedContent")]
|
||||
[DisplayName("RelatedContent")]
|
||||
[Description("Item RelatedContent")]
|
||||
public string Token
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Token, "@Token");
|
||||
}
|
||||
}
|
||||
[Category("RelatedContent")]
|
||||
[DisplayName("RelatedContent")]
|
||||
[Description("Item RelatedContent")]
|
||||
public string Token => LazyLoad(ref _Token, "@Token");
|
||||
|
||||
// new Row value to use for PageStyle Item
|
||||
private LazyLoad<float?> _Row;
|
||||
[Category("Location")]
|
||||
[DisplayName("Vertical Position")]
|
||||
[Description("Vertical Position")]
|
||||
public float? Row
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Row, "@Row");
|
||||
}
|
||||
}
|
||||
// new Row value to use for PageStyle Item
|
||||
private LazyLoad<float?> _Row;
|
||||
[Category("Location")]
|
||||
[DisplayName("Vertical Position")]
|
||||
[Description("Vertical Position")]
|
||||
public float? Row => LazyLoad(ref _Row, "@Row");
|
||||
|
||||
// new Col value to use for PageStyle Item
|
||||
private LazyLoad<float?> _Col;
|
||||
[Category("Location")]
|
||||
[DisplayName("Horizontal Position")]
|
||||
[Description("Horizontal Position")]
|
||||
public float? Col
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _Col, "@Col");
|
||||
}
|
||||
}
|
||||
// new Col value to use for PageStyle Item
|
||||
private LazyLoad<float?> _Col;
|
||||
[Category("Location")]
|
||||
[DisplayName("Horizontal Position")]
|
||||
[Description("Horizontal Position")]
|
||||
public float? Col => LazyLoad(ref _Col, "@Col");
|
||||
|
||||
// new Justify value to use for PageStyle Item
|
||||
private LazyLoad<E_Justify?> _Justify;
|
||||
public E_Justify? Justify
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad<E_Justify>(ref _Justify, "@Justify");
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
// new Justify value to use for PageStyle Item
|
||||
private LazyLoad<E_Justify?> _Justify;
|
||||
public E_Justify? Justify => LazyLoad<E_Justify>(ref _Justify, "@Justify");
|
||||
#endregion
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user