ServParam2ClientModelEngine/CodeShowWeb/Index.aspx

91 lines
4.8 KiB
Plaintext
Raw Normal View History

2018-10-18 17:59:03 +08:00
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Index.aspx.cs" Inherits="CodeShowWeb.Index" %>
<!DOCTYPE html>
<html>
<head>
2018-10-19 01:35:43 +08:00
<title>服务端参数跨语言代码转换引擎</title>
2018-10-18 17:59:03 +08:00
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<link rel="stylesheet" href="styles/default.css">
<script src="highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
</head>
2018-10-18 23:06:30 +08:00
<body style="background-color:black">
<h2>服务端参数跨语言代码转换引擎 Ver 0.1.0 -- 皓月</h2>
<h4>是一个C#服务端API参数实体类、转换成于各类语言客户端解析参数代码减少客户端开发人员重复工作量</h4>
2018-10-19 01:35:43 +08:00
<font size="0.5">PS:文档引用本页调用方法 {http://引擎url}?lang={要转换到的目标语言类型}&Assembly={程序集命名空间}&ReqM={请求参数在服务端的实体类名}&ReqM={请求参数在服务端的实体类名}</font>
2018-10-18 23:06:30 +08:00
<h4>请选择目前支持转换到的目标语言:</h4>
2018-10-19 01:35:43 +08:00
<h3><a href="/Index.aspx?lang=Java">Java/Android</a>、<a href="/Index.aspx?lang=Swift">Swift/iOS</a>、<a href="/Index.aspx?lang=JavaScript">Ajax/Javascript</a>、<a href="/Index.aspx?lang=PHP">PHP</a>、<a href="/Index.aspx?lang=Golang">Golang</a>、</h3>
<h3><a href="/Index.aspx?lang=CSharp">C#</a>、<a href="/Index.aspx?lang=MarkDown">MarkDown参数表格编码</a>、<a href="/Index.aspx?lang=HYJson">皓月转换引擎实体类转译Json</a>、</h3>
2018-10-18 23:06:30 +08:00
2018-10-18 17:59:03 +08:00
<h4>选择你喜欢的代码配色方案<div id="changeStyleSelect"></div></h4>
2018-10-19 01:35:43 +08:00
<h2>已转换为目标语种为"<%=GetLangCodeShowName() %>"代码结果:</h2>
2018-10-18 23:06:30 +08:00
2018-10-19 01:35:43 +08:00
<p></p>
<h3>请求参数代码:</h3>
2018-10-18 23:06:30 +08:00
<div ><pre>
2018-10-19 01:35:43 +08:00
<code class="<%=GetLangCodeShowName() %>"">
<%=GetCode() %>
</code>
</pre>
</div>
<p></p>
<h3>返回参数代码:</h3>
<div ><pre>
<code class="<%=GetLangCodeShowName() %>"">
2018-10-18 23:06:30 +08:00
<%=GetCode() %>
2018-10-18 17:59:03 +08:00
</code>
</pre>
</div>
2018-10-18 23:06:30 +08:00
2018-10-18 17:59:03 +08:00
<style>
@font-face
{
font-family: myFirstFont;
src: url('KawkabMono-Regular.ttf'),
url('KawkabMono-Regular.ttf'); /* IE9+,可以是具体的实际链接 */
}
body
{
font-family:myFirstFont;
2018-10-18 23:06:30 +08:00
color:#ffffff;
2018-10-18 17:59:03 +08:00
}
2018-10-18 23:06:30 +08:00
a{color:#52cbf8}
2018-10-18 17:59:03 +08:00
2018-10-18 23:06:30 +08:00
.div-inline{ display:inline;}
</style>
2018-10-18 17:59:03 +08:00
<script>
2018-10-18 23:06:30 +08:00
styleArr = ["<%=GetCodeStyle() %>",//第一个放自己喜欢的23333
2018-10-18 17:59:03 +08:00
"agate.css", "androidstudio.css", "arduino-light.css", "arta.css", "ascetic.css", "atelier-cave-dark.css", "atelier-cave-light.css", "atelier-dune-dark.css", "atelier-dune-light.css", "atelier-estuary-dark.css", "atelier-estuary-light.css", "atelier-forest-dark.css", "atelier-forest-light.css", "atelier-heath-dark.css", "atelier-heath-light.css", "atelier-lakeside-dark.css", "atelier-lakeside-light.css", "atelier-plateau-dark.css", "atelier-plateau-light.css", "atelier-savanna-dark.css", "atelier-savanna-light.css", "atelier-seaside-dark.css", "atelier-seaside-light.css", "atelier-sulphurpool-dark.css", "atelier-sulphurpool-light.css", "brown-paper.css", "codepen-embed.css", "color-brewer.css", "dark.css", "darkula.css", "default.css", "docco.css", "dracula.css", "far.css", "foundation.css", "github.css", "github-gist.css", "googlecode.css", "grayscale.css", "gruvbox-dark.css", "gruvbox-light.css", "hopscotch.css", "hybrid.css", "idea.css", "ir-black.css", "kimbie.dark.css", "kimbie.light.css", "magula.css", "mono-blue.css", "monokai.css", "monokai-sublime.css", "obsidian.css", "paraiso-dark.css", "paraiso-light.css", "pojoaque.css", "purebasic.css", "qtcreator_dark.css", "qtcreator_light.css", "railscasts.css", "rainbow.css", "school-book.css", "solarized-dark.css", "solarized-light.css", "sunburst.css", "tomorrow.css", "tomorrow-night.css", "tomorrow-night-blue.css", "tomorrow-night-bright.css", "tomorrow-night-eighties.css", "vs.css", "xcode.css", "xt256.css", "zenburn.css"];
2018-10-18 23:06:30 +08:00
selectHtml = [];
selectHtml.push('<select id="changeStyle">');
for (i in styleArr) {
OptionValue = styleArr[i];
selectHtml.push('<option value="' + OptionValue + '" >' + OptionValue + '</option>');
}
selectHtml.push('</select>');
selectHtmlString = selectHtml.join("");
document.getElementById('changeStyleSelect').innerHTML = selectHtmlString;
2018-10-18 17:59:03 +08:00
2018-10-18 23:06:30 +08:00
obj = document.getElementById('changeStyle');
obj.addEventListener("change", function (event) {
var value = this.options[this.options.selectedIndex].value;
l = document.createElement('link');
l.setAttribute('href', 'styles/' + value);
l.setAttribute('rel', 'stylesheet');
document.head.appendChild(l);
2018-10-18 17:59:03 +08:00
});
2018-10-18 23:06:30 +08:00
2018-10-18 17:59:03 +08:00
//首先载入自己喜欢的
l = document.createElement('link');
2018-10-18 23:06:30 +08:00
l.setAttribute('href', 'styles/' +"<%=GetCodeStyle() %>");
l.setAttribute('rel', 'stylesheet');
document.head.appendChild(l);
2018-10-18 17:59:03 +08:00
</script>
</body>
</html>