This commit is contained in:
243
PROMS/Volian.Utils.Library/vlnObject/vlnControl.xml
Normal file
243
PROMS/Volian.Utils.Library/vlnObject/vlnControl.xml
Normal file
@@ -0,0 +1,243 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<dbControl>
|
||||
<connection string="Provider=Microsoft.Jet.OLEDB.4.0;Data source={path};Extended Properties=dBase III;Persist Security Info=False"/>
|
||||
<default datapath="\\rhmdesktop\VEDATA"/>
|
||||
<dbObject type="datapath"
|
||||
items="Plants"
|
||||
imageindex="1"
|
||||
key=""
|
||||
title=""
|
||||
select=""
|
||||
table=""
|
||||
criteria=""
|
||||
sort=""
|
||||
child="plant">
|
||||
<folders child="plant">
|
||||
<folder title="xEntergy Nuclear Northeast - Indian Point Unit 2" template="veip2" />
|
||||
<folder title="Virginia Power - Surry" template="vesurry" />
|
||||
<folder title="Virginia Power - Surry (1A)" template="vesurrya" />
|
||||
<folder title="Virginia Power - North Anna" template="venanna" />
|
||||
<folder title="Virginia Power - North Anna, Unit 1" template="venanna1" />
|
||||
<folder title="Virginia Power - North Anna, Unit 2" template="venanna2" />
|
||||
<folder title="Northern States Power - Prairie Island Emergency Operating Procedures" template="vensp" />
|
||||
<folder title="Northern States Power - Prairie Island Abnormal Operating Procedures" template="venspaop" />
|
||||
<folder title="Northern States Power - Prairie Island Electrical Maintenance Procedures" template="vensppe" />
|
||||
<folder title="Northern States Power - Prairie Island Alarm Response Procedures" template="vensparp" />
|
||||
<folder title="Northern States Power - Prairie Island Remote Alarm Response Procedures" template="vensprar" />
|
||||
<folder title="Northern States Power - Prairie Island System Operating Procedures" template="venspsop" />
|
||||
<folder title="Northern States Power - Prairie Island Instrument Failure Guides" template="venspifg" />
|
||||
<folder title="Northern States Power - Prairie Island Alarm Response Modifications" template="vensparm" />
|
||||
<folder title="Northern States Power - Prairie Island SAMGS" template="venspsam" />
|
||||
<folder title="American Electric Power - D. C. Cook" template="veaep" />
|
||||
<folder title="Wisconsin Electric Power - Point Beach" template="vewpb" />
|
||||
<folder title="Constellation Energy Group - Ginna" template="verge" />
|
||||
<folder title="TUEC - Comanche Peak" template="vetuec" />
|
||||
<folder title="Entergy Nuclear Northeast - Indian Point Unit 3" template="veip3" />
|
||||
<folder title="Maine Yankee Atomic Power Company - Maine Yankee" template="vemya" />
|
||||
<folder title="Yankee Atomic Electric - Yankee Rowe" template="veyae" />
|
||||
<folder title="Wisconsin Public Service Corp.- Kewaunee" template="vewps" />
|
||||
<folder title="Wisconsin Public Service Corp.- Kewaunee Operating Procedures" template="vewpsop" />
|
||||
<folder title="Wisconsin Public Service Corp.- Kewaunee Alarm Response Procedures" template="vewpsarp" />
|
||||
<folder title="Wisconsin Public Service Corp.- Kewaunee OP EOPs and AOPs" template="vewpsaep" />
|
||||
<folder title="South Carolina Gas and Electric - V.C. Summer" template="vesummer" />
|
||||
<folder title="Louisiana Power and Light - Waterford" template="velpl" />
|
||||
<folder title="Pacific Gas and Electric - Diablo Canyon" template="vepac" />
|
||||
<folder title="Southern California Edison - San Onofre" template="vesce" />
|
||||
<folder title="Carolina Power and Light - Robinson" template="vecplr" />
|
||||
<folder title="Arkansas Nuclear One - Unit 1" template="veano1" />
|
||||
<folder title="Emergency Operating Procedures" template="veano2" />
|
||||
<folder title="Normal Operating Procedures" template="veano2op" />
|
||||
<folder title="Abnormal Operating Procedures" template="veano2ap" />
|
||||
<folder title="Low Mode Emergency Operating Procedures" template="veano2lm" />
|
||||
<folder title="Annunciator Procedures" template="veano2an" />
|
||||
<folder title="Southern Nuclear Operating Company - Vogtle" template="vegpc" />
|
||||
<folder title="Florida Power and Light - Turkey Point EOPs" template="vefpl" />
|
||||
<folder title="Florida Power and Light - Turkey Point ONOPs" template="vefpl4" />
|
||||
<folder title="Florida Power and Light - Turkey Point SAMGs" template="vefpls" />
|
||||
<folder title="STPNOC - South Texas" template="vehlp" />
|
||||
<folder title="Carolina Power and Light - Shearon Harris" template="vecpls" />
|
||||
<folder title="Virginia Power - EPIP" template="veepip" />
|
||||
<folder title="AmerenUE - Callaway Plant" template="vecal" />
|
||||
<folder title="ADM - Administrative Procedures - Wolf Creek" template="vewcnadm" />
|
||||
<folder title="ALR - Alarm Response Procedures - Wolf Creek" template="vewcnalr" />
|
||||
<folder title="CKL - Check List Procedures - Wolf Creek" template="vewcnckl" />
|
||||
<folder title="EMG - Emergency Procedures - Wolf Creek" template="vewcnemg" />
|
||||
<folder title="FP - Fire Protection Procedures - Wolf Creek" template="vewcnfp" />
|
||||
<folder title="FHP - Fuel Handling Procedures - Wolf Creek" template="vewcnfhp" />
|
||||
<folder title="GEN - General Operating Procedures - Wolf Creek" template="vewcngen" />
|
||||
<folder title="OFN - Off-Normal Procedures - Wolf Creek" template="vewcnofn" />
|
||||
<folder title="STN STS - Surveillance Procedures - Wolf Creek" template="vewcnsur" />
|
||||
<folder title="STN - Non-Tech Spec Surveillance Procedures - Wolf Creek" template="vewcnstn" />
|
||||
<folder title="STS - Tech Spec Surveillance Procedures - Wolf Creek" template="vewcnsts" />
|
||||
<folder title="SYS - System Procedures - Wolf Creek" template="vewcnsys" />
|
||||
<folder title="TMP - Temporary Procedures - Wolf Creek" template="vewcntmp" />
|
||||
<folder title="IPS - IPS Procedures - Wolf Creek" template="vewcnips" />
|
||||
<folder title="CHM - Chemistry Procedures - Wolf Creek" template="vewcnchm" />
|
||||
<folder title="Wolf Creek Procedures - Local Drive" template="vewcn" />
|
||||
<folder title="Duke Power - Catawba 1B Interim Set" template="vecat" />
|
||||
<folder title="Duke Power - Catawba Revision 1C" template="vecns" />
|
||||
<folder title="Duke Power - McGuire" template="vemcg" />
|
||||
<folder title="Exelon Nuclear - Braidwood/Byron" template="vecebwb" />
|
||||
<folder title="Exelon Nuclear - Braidwood" template="vebraid" />
|
||||
<folder title="Exelon Nuclear - Byron" template="vebyron" />
|
||||
<folder title="Constellation Energy Group - Calvert Cliffs" template="vebge" />
|
||||
<folder title="North Atlantic Energy Service Corp. - Seabrook Nuclear Plant" template="vesea" />
|
||||
<folder title="Volian Enterprises. - River Bend Station" template="vervbnd" />
|
||||
<folder title="River Bend Station - Mechanical Procedures" template="vervmech" />
|
||||
<folder title="River Bend Station - Operations Procedures" template="vervops" />
|
||||
<folder title="River Bend Station - Radiation Protection Procedures" template="vervrp" />
|
||||
<folder title="River Bend Station - Fire Protection Procedures" template="vervfp" />
|
||||
<folder title="River Bend Station - I and C" template="vervic" />
|
||||
<folder title="River Bend Station - Chemistry Procedures" template="vervchem" />
|
||||
<folder title="River Bend Station - Electrical Procedures" template="vervelec" />
|
||||
<folder title="River Bend Station - Protective Relay Procedures" template="vervrel" />
|
||||
<folder title="River Bend Station - Operations Procedures" template="vervops" />
|
||||
<folder title="River Bend Station - IST" template="vervist" />
|
||||
<folder title="Southern Nuclear Operating Company - Farley Nuclear Plant" template="vefnp" />
|
||||
<folder title="CEN - Combustion Engineering ERGs" template="vecen" />
|
||||
<folder title="WOG - Emergency Response Guidelines LP Rev. 1" template="velp1" />
|
||||
<folder title="WOG - Emergency Response Guidelines HP Rev. 1" template="vehp1" />
|
||||
<folder title="WOG - Emergency Response Guidelines LP Rev. 1a" template="velpr1a" />
|
||||
<folder title="WOG - Emergency Response Guidelines HP Rev. 1a" template="vehp1a" />
|
||||
<folder title="WOG - Emergency Response Guidelines LP Rev. 1b" template="velpr1b" />
|
||||
<folder title="WOG - Emergency Response Guidelines HP Rev. 1b" template="vehp1b" />
|
||||
<folder title="WOG - Emergency Response Guidelines HP Rev. 1b - Figures" template="vehp1bfg" />
|
||||
<folder title="WOG - Emergency Response Guidelines Rev. 1c" template="verev1c" />
|
||||
<folder title="WOG - Emergency Response Guidelines Rev. 2" template="verev2" />
|
||||
<folder title="VEPROMS - Test and Validation Procedures" template="vetest" />
|
||||
<folder title="VEPROMS - Test Procedures for Calvert Cliffs" template="vebgedt" />
|
||||
<folder title="VEPROMS - Demo Database" template="vedemo" />
|
||||
<folder title="VEPROMS - UKRAINE Verbal Translation EOIs" template="veukrain" />
|
||||
<folder title="VEPROMS - PI Wolf Creek Performance Improvement Procedures" template="vewcnpi" />
|
||||
</folders>
|
||||
</dbObject>
|
||||
<dbObject type="plant"
|
||||
items="Sets"
|
||||
imageindex="2"
|
||||
key=""
|
||||
title=""
|
||||
select=""
|
||||
table=""
|
||||
criteria=""
|
||||
sort=""
|
||||
child="set">
|
||||
<folders active="set.dbf">
|
||||
<folder title="Emergency Procedures" template="procs" exception="procs2"/>
|
||||
<folder title="Emergency Procedures Unit 1" template="procs" requires="procs2"/>
|
||||
<folder title="Emergency Procedures Unit 2" template="procs2" />
|
||||
<folder title="Emergency Procedures - Sample Version" template="samples" />
|
||||
<folder title="Emergency Procedures (Intro / Attachment / Foldout)" template="pages" />
|
||||
<folder title="Emergency Procedures (Intro / Attachment / Foldout)" template="intro" />
|
||||
<folder title="Emergency Procedures (Intro / Attachment / Foldout)" template="intro2" />
|
||||
<folder title="Writer's Guide" template="wg" />
|
||||
<folder title="Abnormal Procedures" template="abbyproc" />
|
||||
<folder template="*.prc" title="~Procedures ({filename})" />
|
||||
<folder template="*.bck" title="~Background Documents ({filename})" />
|
||||
<folder template="*.dvt" title="~Deviation Documents ({filename})" />
|
||||
<folder template="*.sl?" title="~Procedures ({filename})" />
|
||||
</folders>
|
||||
</dbObject>
|
||||
<dbObject type="set"
|
||||
items="Versions"
|
||||
imageindex="3"
|
||||
key=""
|
||||
title=""
|
||||
select=""
|
||||
table=""
|
||||
criteria=""
|
||||
sort=""
|
||||
child="version">
|
||||
<folders active="set.dbf">
|
||||
<folder template="." title="Working Draft" />
|
||||
<folder template="approved" title="Approved Version"/>
|
||||
<folder template="chgsht" title="Change Sheet Version"/>
|
||||
<folder template="tmpchg" title="Temporary Change"/>
|
||||
<folder template="approved\tmpchg" title="Approved Temporary Change"/>
|
||||
</folders>
|
||||
</dbObject>
|
||||
<dbObject type="version"
|
||||
items="Procedures"
|
||||
imageindex="4"
|
||||
key="dbPath"
|
||||
title="{number} - {title}"
|
||||
select="select * from [set] where entry is not null"
|
||||
table="Set"
|
||||
criteria="entry is not null"
|
||||
sort="number"
|
||||
child="proc">
|
||||
<folders active="set.dbf">
|
||||
<folder template="*.zip" title="Archive ({filename})" child="archive"/>
|
||||
<!--folder template="approved" title="Approved Version" child="version"/-->
|
||||
</folders>
|
||||
</dbObject>
|
||||
<dbObject type="proc"
|
||||
imageindex="5"
|
||||
items="Sections"
|
||||
key="{{Entry}}"
|
||||
title="{step} - {sequence} {text}"
|
||||
select="select * from(
|
||||
select
|
||||
asc(mid(sequence,2,1))-48 as sec,
|
||||
asc(mid(step,1,1))-64 as sec2,
|
||||
rtrim(mid(text,76,8)) as fmt,
|
||||
mid(text,83,3) as subfmt,
|
||||
rtrim(mid(text,86,20)) as secnum,
|
||||
iif(mid(step,2,1)='0','S',mid(step,2,1)) + right('0'+rtrim(left(iif(type is null,'',type),1)),1) as OldType,
|
||||
* from [{{entry}}] where sequence like ' %') order by sec"
|
||||
table="Proc"
|
||||
criteria=""
|
||||
sort="step,sequence"
|
||||
child="section"/>
|
||||
<dbObject type="section"
|
||||
imageindex="6"
|
||||
items="Steps"
|
||||
key=""
|
||||
title="{stp: 3} - {text}"
|
||||
select="select stp,step,text,type from (select asc(mid(step,2,1))-48 as stp,* from [{{entry}}] where step like '{{Step:1}}%' and sequence='S')order by stp"
|
||||
table="Section"
|
||||
criteria=""
|
||||
sort="stp"
|
||||
child="step"/>
|
||||
<dbObject type="step"
|
||||
imageindex="7"
|
||||
items="Step Structure"
|
||||
key="{{Step}}"
|
||||
title="{Sequence} - {Text}"
|
||||
select="select * from [{{entry}}] where step = '{{Step}}' and (sequence like '[*S!]_' or sequence='S$') "
|
||||
select1="select * from [{{entry}}] where step = '{{step}}' and sequence <> 'S'"
|
||||
table="Step"
|
||||
criteria=""
|
||||
sort="sequence"
|
||||
child="substep"
|
||||
child1="dbStepStruct"/>
|
||||
<dbObject type="substep"
|
||||
imageindex="8"
|
||||
items="Substeps"
|
||||
key=""
|
||||
title="{sequence} - {text}"
|
||||
select="select * from [{{entry}}] where step = '{{step}}' and (sequence like '{{sequence}}_' or sequence like '{{sequence}}[*!]_') "
|
||||
table="SubStep"
|
||||
criteria=""
|
||||
sort="sequence"
|
||||
child1="dbSubStep"/>
|
||||
<dbObject type="stepstruct"
|
||||
imageindex="8"
|
||||
items="Structure"
|
||||
key="{{Step}}{{Sequence}}"
|
||||
title="{Sequence} - {Text}"
|
||||
select=""
|
||||
table=""
|
||||
criteria=""
|
||||
sort=""
|
||||
child=""/>
|
||||
<dbObject type="archive"
|
||||
items=""
|
||||
imageindex="9"
|
||||
key=""
|
||||
title=""
|
||||
select=""
|
||||
table=""
|
||||
criteria=""
|
||||
sort=""
|
||||
child=""/>
|
||||
</dbControl>
|
282
PROMS/Volian.Utils.Library/vlnObject/vlnObject.cs
Normal file
282
PROMS/Volian.Utils.Library/vlnObject/vlnObject.cs
Normal file
@@ -0,0 +1,282 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Xml.Serialization;
|
||||
using System.Xml;
|
||||
using System.Xml.Schema;
|
||||
using System.Collections;
|
||||
using System.IO;
|
||||
using System.Text.RegularExpressions;
|
||||
|
||||
namespace vlnObjectLibrary
|
||||
{
|
||||
[Serializable()]
|
||||
public class vlnObject : IXmlSerializable , IDisposable
|
||||
{
|
||||
#region Log4Net
|
||||
private static readonly log4net.ILog log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
|
||||
#endregion
|
||||
public void Dispose()
|
||||
{
|
||||
/* See if I need to do anything */
|
||||
}
|
||||
#region XML Serialization
|
||||
public void WriteXml(XmlWriter w)
|
||||
{
|
||||
WriteXml(w, true);
|
||||
}
|
||||
public void WriteXml(XmlWriter w,bool bSaveParent)
|
||||
{
|
||||
w.WriteAttributeString("title", Title);
|
||||
w.WriteAttributeString("path", Path);
|
||||
w.WriteAttributeString("type", Type);
|
||||
if (m_PropArray.Count > 0)
|
||||
{
|
||||
w.WriteStartElement("properties");
|
||||
foreach (string sKey in m_PropArray.Keys)
|
||||
{
|
||||
w.WriteStartElement("property");
|
||||
w.WriteAttributeString("name", sKey);
|
||||
w.WriteAttributeString("value", PropArray[sKey]);
|
||||
w.WriteEndElement();
|
||||
}
|
||||
w.WriteEndElement();
|
||||
}
|
||||
if (bSaveParent && Parent != null)
|
||||
{
|
||||
w.WriteStartElement("parent");
|
||||
Parent.WriteXml(w);
|
||||
w.WriteEndElement();
|
||||
}
|
||||
}
|
||||
private bool SkipToElement(XmlReader xr)
|
||||
{
|
||||
while (xr.Read())
|
||||
if (xr.NodeType == XmlNodeType.Element || xr.NodeType == XmlNodeType.EndElement)
|
||||
return xr.NodeType == XmlNodeType.Element;
|
||||
return false;
|
||||
}
|
||||
public void ReadXml(XmlReader xr)
|
||||
{
|
||||
SkipToElement(xr);
|
||||
if (xr.MoveToAttribute("title")) m_Title = xr.Value;
|
||||
if (xr.MoveToAttribute("type")) m_Type = xr.Value;
|
||||
if (xr.MoveToAttribute("path")) m_Path = xr.Value;
|
||||
while (SkipToElement(xr))
|
||||
{
|
||||
if (xr.NodeType == XmlNodeType.Element && xr.Name == "properties")
|
||||
while (SkipToElement(xr))
|
||||
if (xr.NodeType == XmlNodeType.Element && xr.Name == "property")
|
||||
AddProp(xr.ReadSubtree());
|
||||
if (xr.NodeType == XmlNodeType.Element && xr.Name == "parent")
|
||||
m_Parent = new vlnObject(xr.ReadSubtree());
|
||||
}
|
||||
xr.Close();
|
||||
}
|
||||
|
||||
public XmlSchema GetSchema()
|
||||
{
|
||||
return (null);
|
||||
}
|
||||
#endregion
|
||||
#region Constructors
|
||||
public vlnObject(vlnObject parent, string type, string title, string path)
|
||||
{
|
||||
m_Parent = parent;
|
||||
m_Type = type;
|
||||
m_Title = title;
|
||||
m_Path = path;
|
||||
m_PropArray = new Dictionary<string,string>();
|
||||
}
|
||||
public vlnObject()
|
||||
{
|
||||
m_Parent = null;
|
||||
m_Title = null;
|
||||
m_Path = null;
|
||||
m_Type = null;
|
||||
m_PropArray = new Dictionary<string, string>();
|
||||
}
|
||||
public vlnObject(XmlReader xr)
|
||||
{
|
||||
m_Parent = null;
|
||||
m_PropArray = new Dictionary<string, string>();
|
||||
this.ReadXml(xr);
|
||||
}
|
||||
public vlnObject(string sXML)
|
||||
{
|
||||
m_Parent = null;
|
||||
m_PropArray = new Dictionary<string, string>();
|
||||
this.ReadXml(new XmlTextReader(new StringReader(sXML)));
|
||||
}
|
||||
#endregion
|
||||
#region Public Properties
|
||||
private vlnObject m_Parent;
|
||||
public vlnObject Parent
|
||||
{
|
||||
get { return m_Parent; }
|
||||
set { m_Parent = value; }
|
||||
}
|
||||
private string m_Title;
|
||||
public string Title
|
||||
{
|
||||
get { return m_Title; }
|
||||
set { m_Title = value; }
|
||||
}
|
||||
private string m_Path;
|
||||
public string Path
|
||||
{
|
||||
get { return m_Path; }
|
||||
set { m_Path = value; }
|
||||
}
|
||||
private string m_Type;
|
||||
|
||||
public string Type
|
||||
{
|
||||
get { return m_Type; }
|
||||
set { m_Type = value; }
|
||||
}
|
||||
private Dictionary<string,string> m_PropArray;
|
||||
public Dictionary<string, string> PropArray
|
||||
{
|
||||
get { return m_PropArray; }
|
||||
set { m_PropArray = value; }
|
||||
}
|
||||
#endregion
|
||||
#region Public Methods
|
||||
public vlnObject Add(string type, string title, string path)
|
||||
{
|
||||
vlnObject b = new vlnObject(this, type, title, path);
|
||||
return b;
|
||||
}
|
||||
public void AddProp(string name, string value)
|
||||
{
|
||||
PropArray[name.ToUpper()] = value;
|
||||
}
|
||||
public void AddProp(XmlReader xr)
|
||||
{
|
||||
SkipToElement(xr);
|
||||
string sName = null;
|
||||
string sValue = null;
|
||||
if (xr.MoveToAttribute("name")) sName = xr.Value;
|
||||
if (xr.MoveToAttribute("value")) sValue = xr.Value;
|
||||
if (sName != null && sValue != null) AddProp(sName, sValue);
|
||||
xr.Close();
|
||||
}
|
||||
public override string ToString()
|
||||
{
|
||||
StringWriter swxml = new StringWriter();
|
||||
XmlSerializer mySer = new XmlSerializer(this.GetType());
|
||||
mySer.Serialize(swxml, this);
|
||||
return swxml.ToString();
|
||||
}
|
||||
#endregion
|
||||
private List<vlnObject> m_Children;
|
||||
public List<vlnObject> Children
|
||||
{
|
||||
get
|
||||
{
|
||||
return m_Children;
|
||||
}
|
||||
set
|
||||
{
|
||||
m_Children = value;
|
||||
}
|
||||
}
|
||||
public void LoadChildren(string sXml)
|
||||
{
|
||||
LoadChildren(new XmlTextReader(new StringReader(sXml)));
|
||||
}
|
||||
public void LoadChildren(XmlReader xr)
|
||||
{
|
||||
m_Children = new List<vlnObject>();
|
||||
SkipToElement(xr);
|
||||
while(SkipToElement(xr)){
|
||||
vlnObject o = new vlnObject(xr.ReadSubtree());
|
||||
o.Parent = this;
|
||||
m_Children.Add(o);
|
||||
}
|
||||
}
|
||||
public string AllChildren()
|
||||
{
|
||||
StringWriter sw = new StringWriter();
|
||||
XmlTextWriter xw = new XmlTextWriter(sw);
|
||||
xw.WriteStartElement("children");
|
||||
foreach (vlnObject vb in Children)
|
||||
{
|
||||
xw.WriteStartElement("vlnObject");
|
||||
vb.WriteXml(xw,false);
|
||||
xw.WriteEndElement();
|
||||
}
|
||||
xw.WriteEndElement();
|
||||
return sw.ToString();
|
||||
}
|
||||
public string ProcessString(string s)
|
||||
{
|
||||
//string retval=s;
|
||||
//string retval = Regex.Replace(s, "{[.]*}", new MatchEvaluator(ReplaceKey));
|
||||
string retval = Regex.Replace(s, "{{.*?}}", new MatchEvaluator(ReplaceRow));
|
||||
retval = Regex.Replace(retval, "{.*?}", new MatchEvaluator(ReplaceDrv));
|
||||
return retval;
|
||||
}
|
||||
private string ReplaceRow(Match m)
|
||||
{
|
||||
string sResult = FindField(m.Value.Substring(2, m.Value.Length - 4));
|
||||
if (sResult == null && Parent != null)
|
||||
{
|
||||
sResult = Parent.ReplaceRow(m);
|
||||
}
|
||||
if (sResult == null)
|
||||
{
|
||||
log.ErrorFormat("vlnObject - Couldn't find {0}", m.Value);
|
||||
}
|
||||
return sResult;
|
||||
}
|
||||
private string ReplaceDrv(Match m)
|
||||
{
|
||||
string sRetVal = FindField(m.Value.Substring(1, m.Value.Length - 2));
|
||||
if (sRetVal == null) sRetVal = "";
|
||||
return sRetVal;
|
||||
}
|
||||
private string FindField(string s)
|
||||
{
|
||||
string retval = "";
|
||||
string[] parts = s.ToUpper().Split(":".ToCharArray());
|
||||
switch (s.ToUpper())
|
||||
{
|
||||
case "PATH":
|
||||
retval = m_Path;
|
||||
break;
|
||||
//case "TITLE":
|
||||
//retval = m_Title;
|
||||
//break;
|
||||
case "TYPE":
|
||||
retval = m_Type;
|
||||
break;
|
||||
default:
|
||||
if (PropArray.ContainsKey(parts[0]))
|
||||
{
|
||||
retval = PropArray[parts[0]].ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
break;
|
||||
}
|
||||
if (parts.Length > 1)
|
||||
{
|
||||
int width = Convert.ToInt32(parts[1]);
|
||||
if (parts[1][0] == ' ' || parts[1][0] == '0')
|
||||
{
|
||||
retval = retval.PadLeft(width, parts[1][0]);
|
||||
}
|
||||
else
|
||||
{
|
||||
retval = retval.PadRight(width).Substring(0, width).Trim();
|
||||
}
|
||||
}
|
||||
return retval;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
64
PROMS/Volian.Utils.Library/vlnObject/vlnObjectLibrary.csproj
Normal file
64
PROMS/Volian.Utils.Library/vlnObject/vlnObjectLibrary.csproj
Normal file
@@ -0,0 +1,64 @@
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.50727</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{933269F5-C3AD-423E-88EB-133A7333FD6B}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>vlnObject</RootNamespace>
|
||||
<AssemblyName>vlnObject</AssemblyName>
|
||||
<SccProjectName>
|
||||
</SccProjectName>
|
||||
<SccLocalPath>
|
||||
</SccLocalPath>
|
||||
<SccAuxPath>
|
||||
</SccAuxPath>
|
||||
<SccProvider>
|
||||
</SccProvider>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>..\..\..\..\..\veproms\bin\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="log4net, Version=1.2.9.0, Culture=neutral, PublicKeyToken=b32731d11ce58905">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\..\..\veproms\bin\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="vlnObject.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="vlnControl.xml">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
Reference in New Issue
Block a user