zoukankan
html css js c++ java
添加文件Node
private
XmlElement AddFileNode(XmlElement rootNode,
string
filename)
{
XmlElement node
=
docOutput.CreateElement(
"
File
"
);
Trace.WriteLine(
string
.Format(
"
\t*File Created: {0}
"
, filename));
PerformStep();
XmlAttribute attName
=
docOutput.CreateAttribute(
"
name
"
);
attName.Value
=
filename;
node.Attributes.Append(attName);
XmlAttribute attTime
=
docOutput.CreateAttribute(
"
startTime
"
);
attTime.Value
=
DateTime.Now.ToFileTime().ToString();
node.Attributes.Append(attTime);
rootNode.AppendChild(node);
return
node;
}
AddFileNode(commonNode,
"
EntityKeyBaseCore.generated.cs
"
);
this
.GetTemplate(
"
EntityKeyBaseCore.generated.cst
"
).SetProperty(
"
BLLNameSpace
"
, BLLNameSpace);
this
.RenderToFile(
"
EntityKeyBaseCore.generated.cst
"
, rootPathBLL
+
"
\\EntityKeyBaseCore.generated.cs
"
,
true
);
if
(
!
File.Exists(rootPathBLL
+
"
\\EntityKeyBase.cs
"
))
{
AddFileNode(commonNode,
"
EntityKeyBase.cs
"
);
this
.GetTemplate(
"
EntityKeyBase.cst
"
).SetProperty(
"
BLLNameSpace
"
, BLLNameSpace);
this
.RenderToFile(
"
EntityKeyBase.cst
"
, rootPathBLL
+
"
\\EntityKeyBase.cs
"
,
true
);
}
public
void
RenderToFile(
string
templateName,
string
path,
bool
overwrite)
{
this
._CurrentFileName
=
path;
this
.GetTemplate(templateName).RenderToFile(path, overwrite);
this
._counter
++
;
}
public
CodeTemplate GetTemplate(
string
templateType)
{
return
(CodeSmith.Engine.CodeTemplate)_CodeTemplates[templateType];
}
public
MoM.Templates.CommonSqlCode GetTemplateBase(
string
templateType)
{
return
(MoM.Templates.CommonSqlCode) GetTemplate(templateType);
}
查看全文
相关阅读:
传统工业制造商Opto 22宣布加入Linux基金会
Android Stack
An Overview of the Android Architecture (Android Studio)
基于嵌入式操作系统的物联网安全
什么是雾计算?它与云计算有什么区别?
《速度与激情8》中的信息安全技术
专利驳回的三大基本原因
专利
【习题 4-2 Uva201】Squares
【习题4-1 Uva1589】Xiangqi
原文地址:https://www.cnblogs.com/fjchenq/p/525287.html
最新文章
邻接矩阵实现图的存储,DFS,BFS遍历
二叉树的建立及递归遍历
十大编程算法
如何处理C++构造函数中的错误——兼谈不同语言的错误处理
闲话函数式变成与OOP
C++最快的读取文件的方案(scanf,cin(及取消sync),fread)的详细对比
loadrunner / socket level data and wininet level data
OS + CentOS 7 / centos 7 / VirtualBox /vegrant
db nosql redis / Redis Sentinel
passat / maintenance / baoyang
热门文章
org.gnome.Terminal 调用 StartServiceByName 出错 (in Fedora)
(OK) Host 中,【adb connect】【adb shell】VirtualBox 中的 lineageOS-14.1
Install and run Android in Androidx86 emulator
(OK) VirtualBox 中的 lineageOS,点击 Developer options,GUI 重启
VirtualBox 中的 lineageOS,点击 Developer options,GUI 重启
(OK) Android Settings和SettingsProvider源码分析与修改
Android MTK 去掉 Setting 中 Wifi 和 蓝牙
How To Enable Android's Developer Options
The Android ADB principle (1) --- ADB enable / disable
Developer options
Copyright © 2011-2022 走看看