site/node_modules/shiki/dist/langs/java.mjs

7 lines
29 KiB
JavaScript
Raw Permalink Normal View History

2024-10-14 06:09:33 +00:00
const lang = Object.freeze({ "displayName": "Java", "name": "java", "patterns": [{ "begin": "\\b(package)\\b\\s*", "beginCaptures": { "1": { "name": "keyword.other.package.java" } }, "contentName": "storage.modifier.package.java", "end": "\\s*(;)", "endCaptures": { "1": { "name": "punctuation.terminator.java" } }, "name": "meta.package.java", "patterns": [{ "include": "#comments" }, { "match": "(?<=\\.)\\s*\\.|\\.(?=\\s*;)", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "(?<!_)_(?=\\s*(\\.|;))|\\b\\d+|-+", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "[A-Z]+", "name": "invalid.deprecated.package_name_not_lowercase.java" }, { "match": "(?x)\\b(?<!\\$)\n(abstract|assert|boolean|break|byte|case|catch|char|class|\nconst|continue|default|do|double|else|enum|extends|final|\nfinally|float|for|goto|if|implements|import|instanceof|int|\ninterface|long|native|new|non-sealed|package|permits|private|protected|public|\nreturn|sealed|short|static|strictfp|super|switch|syncronized|this|\nthrow|throws|transient|try|void|volatile|while|yield|\ntrue|false|null)\\b", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "\\.", "name": "punctuation.separator.java" }] }, { "begin": "\\b(import)\\b\\s*\\b(static)?\\b\\s", "beginCaptures": { "1": { "name": "keyword.other.import.java" }, "2": { "name": "storage.modifier.java" } }, "contentName": "storage.modifier.import.java", "end": "\\s*(;)", "endCaptures": { "1": { "name": "punctuation.terminator.java" } }, "name": "meta.import.java", "patterns": [{ "include": "#comments" }, { "match": "(?<=\\.)\\s*\\.|\\.(?=\\s*;)", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "(?<!\\.)\\s*\\*", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "(?<!_)_(?=\\s*(\\.|;))|\\b\\d+|-+", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "(?x)\\b(?<!\\$)\n(abstract|assert|boolean|break|byte|case|catch|char|class|\nconst|continue|default|do|double|else|enum|extends|final|\nfinally|float|for|goto|if|implements|import|instanceof|int|\ninterface|long|native|new|non-sealed|package|permits|private|protected|public|\nreturn|sealed|short|static|strictfp|super|switch|syncronized|this|\nthrow|throws|transient|try|void|volatile|while|yield|\ntrue|false|null)\\b", "name": "invalid.illegal.character_not_allowed_here.java" }, { "match": "\\.", "name": "punctuation.separator.java" }, { "match": "\\*", "name": "variable.language.wildcard.java" }] }, { "include": "#comments-javadoc" }, { "include": "#code" }, { "include": "#module" }], "repository": { "all-types": { "patterns": [{ "include": "#primitive-arrays" }, { "include": "#primitive-types" }, { "include": "#object-types" }] }, "annotations": { "patterns": [{ "begin": "((@)\\s*([^\\s(]+))(\\()", "beginCaptures": { "2": { "name": "punctuation.definition.annotation.java" }, "3": { "name": "storage.type.annotation.java" }, "4": { "name": "punctuation.definition.annotation-arguments.begin.bracket.round.java" } }, "end": "\\)", "endCaptures": { "0": { "name": "punctuation.definition.annotation-arguments.end.bracket.round.java" } }, "name": "meta.declaration.annotation.java", "patterns": [{ "captures": { "1": { "name": "constant.other.key.java" }, "2": { "name": "keyword.operator.assignment.java" } }, "match": "(\\w*)\\s*(=)" }, { "include": "#code" }] }, { "captures": { "1": { "name": "punctuation.definition.annotation.java" }, "2": { "name": "storage.modifier.java" }, "3": { "name": "storage.type.annotation.java" }, "5": { "name": "punctuation.definition.annotation.java" }, "6": { "name": "storage.type.annotation.java" } }, "match": "(@)(interface)\\s+(\\w*)|((@)\\s*(\\w+))", "name": "meta.declaration.annotation.java" }] }, "anonymous-block-and-instance-initializer": { "begin": "{", "beginCaptures": { "0": { "name": "punctuation.section.block.begin.bracket.curly.java" } }, "end": "}", "endCaptures": { "0": { "name": "punctuation.section.block.end.bracket.curly.java" } }, "patterns": [{ "include": "#code" }] }, "anonymous-classes-and-new": {
var java = [
lang
];
export { java as default };