Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
硅谷海盗
kotlin
提交
3d86084a
K
kotlin
项目概览
硅谷海盗
/
kotlin
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
kotlin
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
3d86084a
编写于
4月 19, 2012
作者:
N
Natalia.Ukhorskaya
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add tests for rendering: examples from actual confluence, special tags
上级
8074629b
变更
55
展开全部
隐藏空白更改
内联
并排
Showing
55 changed file
with
720 addition
and
0 deletion
+720
-0
confluence/confluence.iml
confluence/confluence.iml
+1
-0
confluence/src/test/java/org.jetbrains.jet.confluence/TestUtils.java
...src/test/java/org.jetbrains.jet.confluence/TestUtils.java
+34
-0
confluence/src/test/java/org.jetbrains.jet.confluence/rendering/ConfluenceRenderingTest.java
...ins.jet.confluence/rendering/ConfluenceRenderingTest.java
+71
-0
confluence/testData/rendering/elements/class.kt
confluence/testData/rendering/elements/class.kt
+7
-0
confluence/testData/rendering/elements/class.txt
confluence/testData/rendering/elements/class.txt
+8
-0
confluence/testData/rendering/elements/variable.kt
confluence/testData/rendering/elements/variable.kt
+5
-0
confluence/testData/rendering/elements/variable.txt
confluence/testData/rendering/elements/variable.txt
+6
-0
confluence/testData/rendering/elements/when.kt
confluence/testData/rendering/elements/when.kt
+7
-0
confluence/testData/rendering/elements/when.txt
confluence/testData/rendering/elements/when.txt
+8
-0
confluence/testData/rendering/examples/adress_book.kt
confluence/testData/rendering/examples/adress_book.kt
+47
-0
confluence/testData/rendering/examples/adress_book.txt
confluence/testData/rendering/examples/adress_book.txt
+48
-0
confluence/testData/rendering/examples/basic_syntax_define_a_function.kt
...Data/rendering/examples/basic_syntax_define_a_function.kt
+4
-0
confluence/testData/rendering/examples/basic_syntax_define_a_function.txt
...ata/rendering/examples/basic_syntax_define_a_function.txt
+5
-0
confluence/testData/rendering/examples/basic_syntax_define_a_variable.kt
...Data/rendering/examples/basic_syntax_define_a_variable.kt
+4
-0
confluence/testData/rendering/examples/basic_syntax_define_a_variable.txt
...ata/rendering/examples/basic_syntax_define_a_variable.txt
+5
-0
confluence/testData/rendering/examples/basic_syntax_null_checks.kt
...e/testData/rendering/examples/basic_syntax_null_checks.kt
+32
-0
confluence/testData/rendering/examples/basic_syntax_null_checks.txt
.../testData/rendering/examples/basic_syntax_null_checks.txt
+32
-0
confluence/testData/rendering/examples/basic_syntax_use_a_conditional_expression.kt
...ing/examples/basic_syntax_use_a_conditional_expression.kt
+6
-0
confluence/testData/rendering/examples/basic_syntax_use_a_conditional_expression.txt
...ng/examples/basic_syntax_use_a_conditional_expression.txt
+7
-0
confluence/testData/rendering/examples/hello_world_a_multi_language_hello.kt
.../rendering/examples/hello_world_a_multi_language_hello.kt
+9
-0
confluence/testData/rendering/examples/hello_world_a_multi_language_hello.txt
...rendering/examples/hello_world_a_multi_language_hello.txt
+10
-0
confluence/testData/rendering/examples/hello_world_an_object_oriented_hello.kt
...endering/examples/hello_world_an_object_oriented_hello.kt
+9
-0
confluence/testData/rendering/examples/hello_world_an_object_oriented_hello.txt
...ndering/examples/hello_world_an_object_oriented_hello.txt
+10
-0
confluence/testData/rendering/examples/hello_world_reading_a_name_from_command_line.kt
.../examples/hello_world_reading_a_name_from_command_line.kt
+7
-0
confluence/testData/rendering/examples/hello_world_reading_a_name_from_command_line.txt
...examples/hello_world_reading_a_name_from_command_line.txt
+8
-0
confluence/testData/rendering/examples/html_builder.kt
confluence/testData/rendering/examples/html_builder.kt
+31
-0
confluence/testData/rendering/examples/html_builder.txt
confluence/testData/rendering/examples/html_builder.txt
+32
-0
confluence/testData/rendering/examples/html_builder_with_refs.kt
...nce/testData/rendering/examples/html_builder_with_refs.kt
+114
-0
confluence/testData/rendering/examples/html_builder_with_refs.txt
...ce/testData/rendering/examples/html_builder_with_refs.txt
+115
-0
confluence/testData/rendering/examples/welcome_hello.kt
confluence/testData/rendering/examples/welcome_hello.kt
+5
-0
confluence/testData/rendering/examples/welcome_hello.txt
confluence/testData/rendering/examples/welcome_hello.txt
+6
-0
confluence/testData/rendering/tagTypes/a/a_closed_tag.kt
confluence/testData/rendering/tagTypes/a/a_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/a/a_next_token_tag.kt
confluence/testData/rendering/tagTypes/a/a_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/a/a_with_close_tag.kt
confluence/testData/rendering/tagTypes/a/a_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/class/class_closed_tag.kt
...nce/testData/rendering/tagTypes/class/class_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/class/class_next_token_tag.kt
...testData/rendering/tagTypes/class/class_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/class/class_with_close_tag.kt
...testData/rendering/tagTypes/class/class_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/label/label_closed_tag.kt
...nce/testData/rendering/tagTypes/label/label_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/label/label_next_token_tag.kt
...testData/rendering/tagTypes/label/label_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/label/label_with_close_tag.kt
...testData/rendering/tagTypes/label/label_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/ref/ref_closed_tag.kt
confluence/testData/rendering/tagTypes/ref/ref_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/ref/ref_next_token_tag.kt
...nce/testData/rendering/tagTypes/ref/ref_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/ref/ref_with_close_tag.kt
...nce/testData/rendering/tagTypes/ref/ref_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/style/style_closed_tag.kt
...nce/testData/rendering/tagTypes/style/style_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/style/style_next_token_tag.kt
...testData/rendering/tagTypes/style/style_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/style/style_with_close_tag.kt
...testData/rendering/tagTypes/style/style_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/unresolved/unresolved_closed_tag.kt
...ta/rendering/tagTypes/unresolved/unresolved_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/unresolved/unresolved_next_token_tag.kt
...endering/tagTypes/unresolved/unresolved_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/unresolved/unresolved_with_close_tag.kt
...endering/tagTypes/unresolved/unresolved_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/warnings/warning_closed_tag.kt
...estData/rendering/tagTypes/warnings/warning_closed_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/warnings/warning_closed_tag.txt
...stData/rendering/tagTypes/warnings/warning_closed_tag.txt
+2
-0
confluence/testData/rendering/tagTypes/warnings/warning_next_token_tag.kt
...ata/rendering/tagTypes/warnings/warning_next_token_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/warnings/warning_next_token_tag.txt
...ta/rendering/tagTypes/warnings/warning_next_token_tag.txt
+2
-0
confluence/testData/rendering/tagTypes/warnings/warning_with_close_tag.kt
...ata/rendering/tagTypes/warnings/warning_with_close_tag.kt
+1
-0
confluence/testData/rendering/tagTypes/warnings/warning_with_close_tag.txt
...ta/rendering/tagTypes/warnings/warning_with_close_tag.txt
+2
-0
未找到文件。
confluence/confluence.iml
浏览文件 @
3d86084a
...
...
@@ -6,6 +6,7 @@
<content
url=
"file://$MODULE_DIR$"
>
<sourceFolder
url=
"file://$MODULE_DIR$/src/main/java"
isTestSource=
"false"
/>
<sourceFolder
url=
"file://$MODULE_DIR$/src/main/resources"
isTestSource=
"false"
/>
<sourceFolder
url=
"file://$MODULE_DIR$/src/test/java"
isTestSource=
"true"
/>
<excludeFolder
url=
"file://$MODULE_DIR$/target"
/>
</content>
<orderEntry
type=
"inheritedJdk"
/>
...
...
confluence/src/test/java/org.jetbrains.jet.confluence/TestUtils.java
0 → 100644
浏览文件 @
3d86084a
package
org.jetbrains.jet.confluence
;
import
java.io.File
;
import
java.io.FileReader
;
import
java.io.FileWriter
;
import
java.io.IOException
;
/**
* @author Natalia.Ukhorskaya
*/
public
class
TestUtils
{
public
static
String
readFile
(
File
file
)
throws
IOException
{
FileReader
reader
=
new
FileReader
(
file
);
StringBuilder
builder
=
new
StringBuilder
();
int
c
;
while
((
c
=
reader
.
read
())
>=
0
)
{
builder
.
append
((
char
)
c
);
}
reader
.
close
();
return
builder
.
toString
();
}
public
static
void
writeFile
(
File
file
,
String
str
)
throws
IOException
{
FileWriter
writer
=
new
FileWriter
(
file
);
writer
.
write
(
str
);
writer
.
close
();
}
public
static
String
divideResultForLines
(
String
result
)
{
return
result
.
replaceAll
(
"<div class=\"line\">"
,
"\n<div class=\"line\">"
);
}
}
confluence/src/test/java/org.jetbrains.jet.confluence/rendering/ConfluenceRenderingTest.java
0 → 100644
浏览文件 @
3d86084a
package
org.jetbrains.jet.confluence.rendering
;
import
com.atlassian.renderer.v2.macro.MacroException
;
import
junit.framework.Test
;
import
junit.framework.TestCase
;
import
junit.framework.TestSuite
;
import
org.jetbrains.jet.confluence.TestUtils
;
import
org.jetbrains.jet.lexer.JetMacro
;
import
java.io.File
;
import
java.io.IOException
;
/**
* @author Natalia.Ukhorskaya
*/
public
class
ConfluenceRenderingTest
extends
TestCase
{
public
static
Test
suite
()
{
TestSuite
suite
=
new
TestSuite
();
TestSuite
ats
=
new
TestSuite
();
suite
.
addTest
(
ats
);
File
parsingSourceDir
=
new
File
(
"./testData/rendering"
);
addFilesFromDirToSuite
(
parsingSourceDir
,
ats
);
return
suite
;
}
private
static
void
addFilesFromDirToSuite
(
File
file
,
TestSuite
ats
)
{
if
(
file
.
isDirectory
())
{
for
(
File
sourceFile
:
file
.
listFiles
())
{
addFilesFromDirToSuite
(
sourceFile
,
ats
);
}
}
else
{
if
(
file
.
getName
().
endsWith
(
".kt"
))
{
ats
.
addTest
(
new
ConfluenceRenderingTest
(
file
.
getName
(),
file
));
}
}
}
private
final
File
sourceFile
;
public
ConfluenceRenderingTest
(
String
name
,
File
sourceFile
)
{
super
(
name
);
this
.
sourceFile
=
sourceFile
;
}
@Override
protected
void
runTest
()
throws
Throwable
{
checkSourceFile
(
sourceFile
);
}
private
void
checkSourceFile
(
File
sourceFile
)
throws
IOException
,
MacroException
{
String
source
=
TestUtils
.
readFile
(
sourceFile
);
StringBuilder
actualResult
=
new
StringBuilder
();
new
JetMacro
().
generateHtmlFromCode
(
source
,
actualResult
);
File
expectedResultFile
=
new
File
(
sourceFile
.
getAbsolutePath
().
replace
(
".kt"
,
".txt"
));
if
(!
expectedResultFile
.
exists
())
{
expectedResultFile
.
createNewFile
();
TestUtils
.
writeFile
(
expectedResultFile
,
TestUtils
.
divideResultForLines
(
actualResult
.
toString
()));
assertTrue
(
"File with expected result for "
+
expectedResultFile
.
getAbsolutePath
()
+
" is absent."
,
false
);
}
String
expectedResult
=
TestUtils
.
readFile
(
expectedResultFile
);
assertEquals
(
expectedResult
,
TestUtils
.
divideResultForLines
(
actualResult
.
toString
()));
}
}
confluence/testData/rendering/elements/class.kt
0 → 100644
浏览文件 @
3d86084a
class
Greeter1
()
{
}
class
Greeter2
(
val
name
:
String
)
{
}
\ No newline at end of file
confluence/testData/rendering/elements/class.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">Greeter1</code><code class="jet plain">(</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">Greeter2</code><code class="jet plain">(</code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">name</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/elements/variable.kt
0 → 100644
浏览文件 @
3d86084a
val
a
:
Int
=
1
val
b
=
1
val
c
:
Int
c
=
1
var
a
:
String
=
"sss"
\ No newline at end of file
confluence/testData/rendering/elements/variable.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">c</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">c</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">var</code><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">sss</code><code class="jet string">"</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/elements/when.kt
0 → 100644
浏览文件 @
3d86084a
val
language
=
if
(
args
.
size
==
0
)
"EN"
else
args
[
0
]
when
(
language
)
{
"EN"
->
"Hello!"
"ES"
->
"¡Hola!"
"RU"
->
"Привет!"
else
->
"Sorry, I can't greet you in $language yet"
}
\ No newline at end of file
confluence/testData/rendering/elements/when.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">language</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">.</code><code class="jet plain">size</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet number">0</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">EN</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet keyword">else</code><code class="jet whitespace"> </code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">when</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">language</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">EN</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Hello!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">ES</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">¡Hola!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">RU</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Привет!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">else</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Sorry, I can't greet you in </code><code class="jet escape">$</code><code class="jet plain">language</code><code class="jet string"> yet</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/adress_book.kt
0 → 100644
浏览文件 @
3d86084a
namespace
addressbook
class
Contact
(
val
name
:
String
,
val
emails
:
List
<
EmailAddress
>,
val
addresses
:
List
<
PostalAddress
>,
val
phonenums
:
List
<
PhoneNumber
>
)
class
EmailAddress
(
val
user
:
String
,
val
host
:
String
)
class
PostalAddress
(
val
streetAddress
:
String
,
val
city
:
String
,
val
zip
:
String
,
val
state
:
USState
?,
val
country
:
Country
)
{
assert
{(
state
==
null
)
xor
(
country
==
Countries
[
"US"
])
}
}
class
PhoneNumber
(
val
country
:
Country
,
val
areaCode
:
Int
,
val
number
:
Long
)
object
Countries
{
fun
get
(
id
:
CountryID
)
:
Country
=
countryTable
[
id
]
private
var
table
:
Map
<
String
,
Country
>?
=
null
private
val
countryTable
:
Map
<
String
,
Country
>
get
()
{
if
(
table
==
null
)
{
table
=
HashMap
()
for
(
line
in
TextFile
(
"countries.txt"
).
lines
(
stripWhiteSpace
=
true
))
{
table
[
line
]
=
Country
(
line
)
}
}
return
table
}
}
class
Country
(
val
name
:
String
)
\ No newline at end of file
confluence/testData/rendering/examples/adress_book.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet plain">namespace</code><code class="jet whitespace"> </code><code class="jet plain">addressbook</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">Contact</code><code class="jet plain">(</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">name</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">emails</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">List</code><code class="jet plain"><</code><code class="jet plain">EmailAddress</code><code class="jet plain">></code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">addresses</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">List</code><code class="jet plain"><</code><code class="jet plain">PostalAddress</code><code class="jet plain">></code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">phonenums</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">List</code><code class="jet plain"><</code><code class="jet plain">PhoneNumber</code><code class="jet plain">></code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">)</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">EmailAddress</code><code class="jet plain">(</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">user</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">host</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">)</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">PostalAddress</code><code class="jet plain">(</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">streetAddress</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">city</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">zip</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">state</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">USState</code><code class="jet plain">?</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">country</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Country</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">assert</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">(</code><code class="jet plain">state</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">xor</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">country</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet plain">Countries</code><code class="jet plain">[</code><code class="jet string">"</code><code class="jet string">US</code><code class="jet string">"</code><code class="jet plain">]</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">PhoneNumber</code><code class="jet plain">(</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">country</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">areaCode</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">,</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">number</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Long</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">)</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">object</code><code class="jet whitespace"> </code><code class="jet plain">Countries</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet softkeyword">get</code><code class="jet plain">(</code><code class="jet plain">id</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">CountryID</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet plain">countryTable</code><code class="jet plain">[</code><code class="jet plain">id</code><code class="jet plain">]</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet softkeyword">private</code><code class="jet whitespace"> </code><code class="jet keyword">var</code><code class="jet whitespace"> </code><code class="jet plain">table</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Map</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">,</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet plain">></code><code class="jet plain">?</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet keyword">null</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet softkeyword">private</code><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">countryTable</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Map</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">,</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet plain">></code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet softkeyword">get</code><code class="jet plain">(</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">table</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">table</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet plain">HashMap</code><code class="jet plain">(</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">for</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">line</code><code class="jet whitespace"> </code><code class="jet keyword">in</code><code class="jet whitespace"> </code><code class="jet plain">TextFile</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">countries.txt</code><code class="jet string">"</code><code class="jet plain">)</code><code class="jet plain">.</code><code class="jet plain">lines</code><code class="jet plain">(</code><code class="jet plain">stripWhiteSpace</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet keyword">true</code><code class="jet plain">)</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">table</code><code class="jet plain">[</code><code class="jet plain">line</code><code class="jet plain">]</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet plain">(</code><code class="jet plain">line</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code><code class="jet whitespace"> </code><code class="jet plain">table</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">Country</code><code class="jet plain">(</code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">name</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">)</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_define_a_function.kt
0 → 100644
浏览文件 @
3d86084a
// Return type mandatory
fun
sum
(
a
:
Int
,
b
:
Int
)
:
Int
{
return
a
+
b
}
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_define_a_function.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet jet-comment">// Return type mandatory</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">sum</code><code class="jet plain">(</code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">,</code><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">+</code><code class="jet whitespace"> </code><code class="jet plain">b</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_define_a_variable.kt
0 → 100644
浏览文件 @
3d86084a
val
a
:
Int
=
1
val
b
=
1
// Type is inferred
val
c
:
Int
// Type required when no initializer provided
c
=
1
// definite assignment
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_define_a_variable.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code><code class="jet whitespace"> </code><code class="jet jet-comment">// Type is inferred</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">c</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet whitespace"> </code><code class="jet jet-comment">// Type required when no initializer provided</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">c</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet number">1</code><code class="jet whitespace"> </code><code class="jet jet-comment">// definite assignment</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_null_checks.kt
0 → 100644
浏览文件 @
3d86084a
package
multiplier
// Return null if str does not hold a number
fun
parseInt
(
str
:
String
)
:
Int
?
{
// ...
}
fun
main
(
args
:
Array
<
String
>)
{
if
(
args
.
size
<
2
)
{
print
(
"No number supplied"
);
}
val
x
=
parseInt
(
args
[
0
])
val
y
=
parseInt
(
args
[
1
])
// We cannot say 'x * y' now because they may hold nulls
if
(
x
!=
null
&&
y
!=
null
)
{
print
(
x
*
y
)
// Now we can
}
// ...
if
(
x
==
null
)
{
print
(
"Wrong number format in '${args[0]}'"
)
return
}
if
(
y
==
null
)
{
print
(
"Wrong number format in '${args[1]}'"
)
return
}
print
(
x
*
y
)
// Now we know that x and y are not nulls
}
confluence/testData/rendering/examples/basic_syntax_null_checks.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">package</code><code class="jet whitespace"> </code><code class="jet plain">multiplier</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet jet-comment">// Return null if str does not hold a number</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">parseInt</code><code class="jet plain">(</code><code class="jet plain">str</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">?</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// ...</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">main</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">.</code><code class="jet plain">size</code><code class="jet whitespace"> </code><code class="jet plain"><</code><code class="jet whitespace"> </code><code class="jet number">2</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">print</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">No number supplied</code><code class="jet string">"</code><code class="jet plain">)</code><code class="jet plain">;</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">x</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet plain">parseInt</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">y</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet plain">parseInt</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">1</code><code class="jet plain">]</code><code class="jet plain">)</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// We cannot say 'x * y' now because they may hold nulls</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">x</code><code class="jet whitespace"> </code><code class="jet plain">!=</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet whitespace"> </code><code class="jet plain">&&</code><code class="jet whitespace"> </code><code class="jet plain">y</code><code class="jet whitespace"> </code><code class="jet plain">!=</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">print</code><code class="jet plain">(</code><code class="jet plain">x</code><code class="jet whitespace"> </code><code class="jet plain">*</code><code class="jet whitespace"> </code><code class="jet plain">y</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet jet-comment">// Now we can</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// ...</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">x</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">print</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Wrong number format in '</code><code class="jet escape">${</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code><code class="jet escape">}</code><code class="jet string">'</code><code class="jet string">"</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">y</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet keyword">null</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">print</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Wrong number format in '</code><code class="jet escape">${</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">1</code><code class="jet plain">]</code><code class="jet escape">}</code><code class="jet string">'</code><code class="jet string">"</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">print</code><code class="jet plain">(</code><code class="jet plain">x</code><code class="jet whitespace"> </code><code class="jet plain">*</code><code class="jet whitespace"> </code><code class="jet plain">y</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet jet-comment">// Now we know that x and y are not nulls</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_use_a_conditional_expression.kt
0 → 100644
浏览文件 @
3d86084a
fun
max
(
a
:
Int
,
b
:
Int
)
:
Int
{
if
(
a
>
b
)
return
a
else
return
b
}
\ No newline at end of file
confluence/testData/rendering/examples/basic_syntax_use_a_conditional_expression.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">max</code><code class="jet plain">(</code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">,</code><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">a</code><code class="jet whitespace"> </code><code class="jet plain">></code><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code><code class="jet whitespace"> </code><code class="jet plain">a</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">else</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code><code class="jet whitespace"> </code><code class="jet plain">b</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_a_multi_language_hello.kt
0 → 100644
浏览文件 @
3d86084a
fun
main
(
args
:
Array
<
String
>)
{
val
language
=
if
(
args
.
size
==
0
)
"EN"
else
args
[
0
]
println
(
when
(
language
)
{
"EN"
->
"Hello!"
"ES"
->
"¡Hola!"
"RU"
->
"Привет!"
else
->
"Sorry, I can't greet you in $language yet"
})
}
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_a_multi_language_hello.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">main</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">language</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">.</code><code class="jet plain">size</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet number">0</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">EN</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet keyword">else</code><code class="jet whitespace"> </code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">println</code><code class="jet plain">(</code><code class="jet keyword">when</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">language</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">EN</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Hello!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">ES</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">¡Hola!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">RU</code><code class="jet string">"</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Привет!</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">else</code><code class="jet whitespace"> </code><code class="jet plain">-></code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">Sorry, I can't greet you in </code><code class="jet escape">$</code><code class="jet plain">language</code><code class="jet string"> yet</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_an_object_oriented_hello.kt
0 → 100644
浏览文件 @
3d86084a
class
Greeter
(
val
name
:
String
)
{
fun
greet
()
{
println
(
"Hello, ${name}"
);
}
}
fun
main
(
args
:
Array
<
String
>)
{
Greeter
(
args
[
0
]).
greet
()
}
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_an_object_oriented_hello.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">class</code><code class="jet whitespace"> </code><code class="jet plain">Greeter</code><code class="jet plain">(</code><code class="jet keyword">val</code><code class="jet whitespace"> </code><code class="jet plain">name</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">String</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">greet</code><code class="jet plain">(</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">println</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Hello, </code><code class="jet escape">${</code><code class="jet plain">name</code><code class="jet escape">}</code><code class="jet string">"</code><code class="jet plain">)</code><code class="jet plain">;</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">main</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">Greeter</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code><code class="jet plain">)</code><code class="jet plain">.</code><code class="jet plain">greet</code><code class="jet plain">(</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_reading_a_name_from_command_line.kt
0 → 100644
浏览文件 @
3d86084a
fun
main
(
args
:
Array
<
String
>)
{
if
(
args
.
size
==
0
)
{
println
(
"Please provide a name as a command-line argument"
)
return
}
println
(
"Hello, ${args[0]}!"
)
}
\ No newline at end of file
confluence/testData/rendering/examples/hello_world_reading_a_name_from_command_line.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">main</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">if</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet plain">.</code><code class="jet plain">size</code><code class="jet whitespace"> </code><code class="jet plain">==</code><code class="jet whitespace"> </code><code class="jet number">0</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">println</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Please provide a name as a command-line argument</code><code class="jet string">"</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">return</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">println</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Hello, </code><code class="jet escape">${</code><code class="jet plain">args</code><code class="jet plain">[</code><code class="jet number">0</code><code class="jet plain">]</code><code class="jet escape">}</code><code class="jet string">!</code><code class="jet string">"</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/html_builder.kt
0 → 100644
浏览文件 @
3d86084a
import
html.*
fun
result
(
args
:
Array
<
String
>)
=
html
{
head
{
title
{+
"XML encoding with Kotlin"
}
}
body
{
h1
{+
"XML encoding with Kotlin"
}
p
{+
"this format can be used as an alternative markup to XML"
}
// an element with attributes and text content
a
(
href
=
"http://jetbrains.com/kotlin"
)
{+
"Kotlin"
}
// mixed content
p
{
+
"This is some"
b
{+
"mixed"
}
+
"text. For more see the"
a
(
href
=
"http://jetbrains.com/kotlin"
)
{+
"Kotlin"
}
+
"project"
}
p
{+
"some text"
}
// content generated by
p
{
for
(
arg
in
args
)
+
arg
}
}
}
\ No newline at end of file
confluence/testData/rendering/examples/html_builder.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet softkeyword">import</code><code class="jet whitespace"> </code><code class="jet plain">html</code><code class="jet plain">.</code><code class="jet plain">*</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">result</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">=</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">html</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">head</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">title</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">XML encoding with Kotlin</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">body</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">h1</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">XML encoding with Kotlin</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">p</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">this format can be used as an alternative markup to XML</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// an element with attributes and text content</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet plain">(</code><code class="jet plain">href</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">http://jetbrains.com/kotlin</code><code class="jet string">"</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">Kotlin</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// mixed content</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">p</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">This is some</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">b</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">mixed</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">text. For more see the</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">a</code><code class="jet plain">(</code><code class="jet plain">href</code><code class="jet whitespace"> </code><code class="jet plain">=</code><code class="jet whitespace"> </code><code class="jet string">"</code><code class="jet string">http://jetbrains.com/kotlin</code><code class="jet string">"</code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">Kotlin</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">project</code><code class="jet string">"</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">p</code><code class="jet whitespace"> </code><code class="jet plain">{</code><code class="jet plain">+</code><code class="jet string">"</code><code class="jet string">some text</code><code class="jet string">"</code><code class="jet plain">}</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet jet-comment">// content generated by</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">p</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet keyword">for</code><code class="jet whitespace"> </code><code class="jet plain">(</code><code class="jet plain">arg</code><code class="jet whitespace"> </code><code class="jet keyword">in</code><code class="jet whitespace"> </code><code class="jet plain">args</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">+</code><code class="jet plain">arg</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/examples/html_builder_with_refs.kt
0 → 100644
浏览文件 @
3d86084a
import
<ref="html_ns":>html.*
fun
result
(
args
:
Array
<
String
>)
=
<
ref
=
"html"
:>
html
{
<
ref
=
"head"
:>
head
{
<
ref
=
"title"
:>
title
{<
ref
=
"plus"
:>+
"XML encoding with Kotlin"
}
}
<
ref
=
"body"
:>
body
{
<
ref
=
"h1"
:>
h1
{<
ref
=
"plus"
:>+
"XML encoding with Kotlin"
}
<
ref
=
"p"
:>
p
{<
ref
=
"plus"
:>+
"this format can be used as an alternative markup to XML"
}
// an element with attributes and text content
<
ref
=
"a"
:>
a
(
href
=
"http://jetbrains.com/kotlin"
)
{<
ref
=
"plus"
:>+
"Kotlin"
}
// mixed content
<
ref
=
"p"
:>
p
{
<
ref
=
"plus"
:>+
"This is some"
<
ref
=
"b"
:>
b
{<
ref
=
"plus"
:>+
"mixed"
}
<
ref
=
"plus"
:>+
"text. For more see the"
<
ref
=
"a"
:>
a
(
href
=
"http://jetbrains.com/kotlin"
)
{<
ref
=
"plus"
:>+
"Kotlin"
}
<
ref
=
"plus"
:>+
"project"
}
<
ref
=
"p"
:>
p
{<
ref
=
"plus"
:>+
"some text"
}
// content generated by
<
ref
=
"p"
:>
p
{
for
(
arg
in
args
)
<
ref
=
"plus"
:>+
arg
}
}
}
<
label
=
"html_ns"
:>
namespace
html
{
<
label
=
"Factory"
:>
abstract
class
Factory
<
T
>
{
fun
create
()
:
T
}
<
label
=
"Element"
:>
abstract
class
Element
<
label
=
"TextElement"
:>
class
TextElement
(
val
text
:
String
)
:
Element
<
label
=
"Tag"
:>
abstract
class
Tag
(
val
name
:
String
)
:
Element
{
<
label
=
"children"
:>
val
children
=
ArrayList
<
Element
>()
<
label
=
"attributes"
:>
val
attributes
=
HashMap
<
String
,
String
>()
protected
fun
initTag
<
T
:
Element
>(
init
:
T
.()
->
Unit
)
:
T
where
class
object
T
:
Factory
<
T
>
{
val
tag
=
T
.
create
()
tag
.
init
()
<
ref
=
"children"
:>
children
.
add
(
tag
)
return
tag
}
}
<
label
=
"TagWithText"
:>
abstract
class
TagWithText
(
name
:
String
)
:
Tag
(
name
)
{
<
label
=
"plus"
/>
fun
String
.
plus
()
{
children
.
add
(
TextElement
(
this
))
}
}
<
label
=
"HTML"
:>
class
HTML
()
:
TagWithText
(
"html"
)
{
class
object :
Factory
<
HTML
>
{
override
fun
create
()
=
HTML
()
}
<
label
=
"head"
/>
fun
head
(
init
:
Head
.()
->
Unit
)
=
initTag
(
init
)
<
label
=
"body"
/>
fun
body
(
init
:
Body
.()
->
Unit
)
=
initTag
(
init
)
}
<
label
=
"Head"
:>
class
Head
()
:
TagWithText
(
"head"
)
{
class
object :
Factory
<
Head
>
{
override
fun
create
()
=
Head
()
}
<
label
=
"title"
/>
fun
title
(
init
:
Title
.()
->
Unit
)
=
initTag
(
init
)
}
<
label
=
"Title"
:>
class
Title
()
:
TagWithText
(
"title"
)
<
label
=
"BodyTag"
:>
abstract
class
BodyTag
(
name
:
String
)
:
TagWithText
(
name
)
{
}
<
label
=
"Body"
:>
class
Body
()
:
BodyTag
(
"body"
)
{
class
object :
Factory
<
Body
>
{
override
fun
create
()
=
Body
()
}
<
label
=
"b"
/>
fun
b
(
init
:
B
.()
->
Unit
)
=
initTag
(
init
)
<
label
=
"p"
/>
fun
p
(
init
:
P
.()
->
Unit
)
=
initTag
(
init
)
<
label
=
"h1"
/>
fun
h1
(
init
:
H1
.()
->
Unit
)
=
initTag
(
init
)
<
label
=
"a"
/>
fun
a
(
href
:
String
,
init
:
A
.()
->
Unit
)
{
val
a
=
initTag
(
init
)
a
.
href
=
href
}
}
class
B
()
:
BodyTag
(
"b"
)
class
P
()
:
BodyTag
(
"p"
)
class
H1
()
:
BodyTag
(
"h1"
)
class
A
()
:
BodyTag
(
"a"
)
{
var
href
:
String
get
()
=
<
ref
=
"attributes"
:>
attributes
[
"href"
]
set
(
value
)
{
<
ref
=
"attributes"
:>
attributes
[
"href"
]
=
value
}
}
<
label
=
"html"
/>
fun
html
(
init
:
HTML
.()
->
Unit
)
:
HTML
{
val
html
=
HTML
()
html
.
init
()
return
html
}
}
\ No newline at end of file
confluence/testData/rendering/examples/html_builder_with_refs.txt
0 → 100644
浏览文件 @
3d86084a
此差异已折叠。
点击以展开。
confluence/testData/rendering/examples/welcome_hello.kt
0 → 100644
浏览文件 @
3d86084a
package
hello
fun
main
(
args
:
Array
<
String
>)
{
println
(
"Hello, world!"
)
}
\ No newline at end of file
confluence/testData/rendering/examples/welcome_hello.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">package</code><code class="jet whitespace"> </code><code class="jet plain">hello</code> </div>
<div class="line"> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet keyword">fun</code><code class="jet whitespace"> </code><code class="jet plain">main</code><code class="jet plain">(</code><code class="jet plain">args</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Array</code><code class="jet plain"><</code><code class="jet plain">String</code><code class="jet plain">></code><code class="jet plain">)</code><code class="jet whitespace"> </code><code class="jet plain">{</code> </div>
<div class="line"><code class="jet whitespace"> </code><code class="jet plain">println</code><code class="jet plain">(</code><code class="jet string">"</code><code class="jet string">Hello, world!</code><code class="jet string">"</code><code class="jet plain">)</code> </div>
<div class="line"><code class="jet whitespace"></code><code class="jet plain">}</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/tagTypes/a/a_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
a
=
"s"
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/a/a_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
a
=
"s"
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/a/a_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
a
=
"a"
>
allByDefault
:
Int
?</
a
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/class/class_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
class
=
"class"
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/class/class_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
class
=
"class"
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/class/class_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
class
=
"class"
>
allByDefault
:
Int
?</
class
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/label/label_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
label
=
"label"
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/label/label_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
label
=
"label"
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/label/label_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
label
=
"label"
>
allByDefault
:
Int
?</
label
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/ref/ref_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
ref
=
"ref"
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/ref/ref_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
ref
=
"ref"
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/ref/ref_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
ref
=
"ref"
>
allByDefault
:
Int
?</
ref
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/style/style_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
style
=
"style"
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/style/style_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
style
=
"style"
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/style/style_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
style
=
"style"
>
allByDefault
:
Int
?</
style
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/unresolved/unresolved_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
unresolved
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/unresolved/unresolved_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
unresolved
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/unresolved/unresolved_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
unresolved
>
allByDefault
:
Int
?</
unresolved
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_closed_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
warning
/>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_closed_tag.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">var</code><code class="jet whitespace"> </code><div class="jet warning"></div><code class="jet plain">allByDefault</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">?</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_next_token_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
warning
:>
allByDefault
:
Int
?
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_next_token_tag.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">var</code><code class="jet whitespace"> </code><div class="jet warning"><code class="jet plain">allByDefault</code></div><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">?</code></div></div></div></div>
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_with_close_tag.kt
0 → 100644
浏览文件 @
3d86084a
var
<
warning
>
allByDefault
:
Int
?</
warning
>
\ No newline at end of file
confluence/testData/rendering/tagTypes/warnings/warning_with_close_tag.txt
0 → 100644
浏览文件 @
3d86084a
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent"><div class="container">
<div class="line"><code class="jet keyword">var</code><code class="jet whitespace"> </code><div class="jet warning"><code class="jet plain">allByDefault</code><code class="jet whitespace"> </code><code class="jet plain">:</code><code class="jet whitespace"> </code><code class="jet plain">Int</code><code class="jet plain">?</code></div></div></div></div></div>
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录