effective-java-3rd-chinese/docs/_style/prism-master/tests/languages/clike/class-name_feature.test
2019-03-14 13:10:17 +08:00

53 lines
784 B
Plaintext

class Foo
interface bar
extends Foo
implements bar
trait Foo
instanceof \bar
new \Foo
catch (bar)
----------------------------------------------------
[
"class ",
["class-name", [
"Foo"
]],
"\r\ninterface ",
["class-name", [
"bar"
]],
"\r\nextends ",
["class-name", [
"Foo"
]],
"\r\nimplements ",
["class-name", [
"bar"
]],
"\r\ntrait ",
["class-name", [
"Foo"
]],
["keyword", "instanceof"],
["class-name", [
["punctuation", "\\"],
"bar"
]],
["keyword", "new"],
["class-name", [
["punctuation", "\\"],
"Foo"
]],
["keyword", "catch"],
["punctuation", "("],
["class-name", [
"bar"
]],
["punctuation", ")"]
]
----------------------------------------------------
Checks for class names.