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);
}
查看全文
相关阅读:
自定义 Spring Boot 安全组件 Security 的用户名和密码的方法
禁用 Spring Boot 中引入安全组件 spring-boot-starter-security 的方法
CentOS 7 上配置 maven 的环境变量
CentOS 7 上配置 JDK1.8 的环境变量
CentOS 7 上安装 xz utils 解压缩工具
常用 Maven 配置
接口统计模板
为什么领域模型对于架构师如此重要? https://blog.csdn.net/qq_40741855/article/details/84835212
什么是实体关系图(ERD)? 转
彻底明白Flink系统学习5:window、Linux本地安装Flink
原文地址:https://www.cnblogs.com/fjchenq/p/525287.html
最新文章
hexo支持mathjax
n阶贝塞尔曲线
Unity编辑器
toLua踩坑
图形学噪声解析
C++ 类 超细节攻略
Unity Shader 噪声消融特效
2、WindowManager源码分析--最后一战
1、客户端编译、服务器、数据库搭建,完美运行--最后之战
大型Unity手游《英雄之刃-最后之战》源码分析
热门文章
SciTE编写lua的快捷键整理
Lua的文件IO操作
在Lua中封装一个调试日志(附lua时间格式)
Lua中“.”调用方法与“:”调用方法的区别
Unity热更新技术整理
Protocol Buffers
更新 Spring Data JPA 之数据表名的命名规则为驼峰命名法
JDBC 与 JPA 初探
nodeJS 的 npm 设置国内高速镜像之淘宝镜像的方法
解决 alibaba 数据库连接池 druid-1.1.22 无法使用 JDK 11 的问题
Copyright © 2011-2022 走看看