jellyfin-web/dashboard-ui/bower_components/prism/components/prism-java.js

17 lines
796 B
JavaScript
Raw Normal View History

2016-02-03 16:00:01 -07:00
Prism.languages.java = Prism.languages.extend('clike', {
'keyword': /\b(abstract|continue|for|new|switch|assert|default|goto|package|synchronized|boolean|do|if|private|this|break|double|implements|protected|throw|byte|else|import|public|throws|case|enum|instanceof|return|transient|catch|extends|int|short|try|char|final|interface|static|void|class|finally|long|strictfp|volatile|const|float|native|super|while)\b/,
'number': /\b0b[01]+\b|\b0x[\da-f]*\.?[\da-fp\-]+\b|\b\d*\.?\d+(?:e[+-]?\d+)?[df]?\b/i,
'operator': {
pattern: /(^|[^.])(?:\+[+=]?|-[-=]?|!=?|<<?=?|>>?>?=?|==?|&[&=]?|\|[|=]?|\*=?|\/=?|%=?|\^=?|[?:~])/m,
lookbehind: true
}
2016-05-02 10:34:06 -07:00
});
Prism.languages.insertBefore('java','function', {
'annotation': {
alias: 'punctuation',
pattern: /(^|[^.])@\w+/,
lookbehind: true
}
});