Class: Rouge::Lexers::Jsonnet
- Inherits:
-
RegexLexer
- Object
- Rouge::Lexer
- RegexLexer
- Rouge::Lexers::Jsonnet
- Defined in:
- lib/rouge/lexers/jsonnet.rb
Constant Summary
Constants inherited from RegexLexer
Constants included from Token::Tokens
Token::Tokens::Num, Token::Tokens::Str
Instance Attribute Summary
Attributes inherited from Rouge::Lexer
Class Method Summary collapse
Methods inherited from RegexLexer
append, #delegate, #goto, #group, #groups, #in_state?, #pop!, prepend, #push, #recurse, replace_state, #reset!, #reset_stack, #stack, start, start_procs, state, #state, #state?, state_definitions, states, #step, #stream_tokens, #token
Methods inherited from Rouge::Lexer
aliases, all, #as_bool, #as_lexer, #as_list, #as_string, #as_token, #bool_option, continue_lex, #continue_lex, debug_enabled?, demo, demo_file, desc, detect?, detectable?, disable_debug!, enable_debug!, filenames, find, find_fancy, guess, guess_by_filename, guess_by_mimetype, guess_by_source, guesses, #hash_option, #initialize, lex, #lex, #lexer_option, #list_option, lookup_fancy, mimetypes, option, option_docs, #reset!, #stream_tokens, #string_option, tag, #tag, title, #token_option, #with
Methods included from Token::Tokens
Constructor Details
This class inherits a constructor from Rouge::Lexer
Class Method Details
.builtins ⇒ Object
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 |
# File 'lib/rouge/lexers/jsonnet.rb', line 32 def self.builtins @builtins ||= Set.new %w( acos asin atan ceil char codepoint cos exp exponent filter floor force length log makeArray mantissa objectFields objectHas pow sin sqrt tan thisFile type abs assertEqual escapeStringBash escapeStringDollars escapeStringJson escapeStringPython filterMap flattenArrays foldl foldr format join lines manifestIni manifestPython manifestPythonVars map max min mod range set setDiff setInter setMember setUnion sort split stringChars substr toString uniq ) end |
.constants ⇒ Object
26 27 28 29 30 |
# File 'lib/rouge/lexers/jsonnet.rb', line 26 def self.constants @constants ||= Set.new %w( null true false ) end |
.declarations ⇒ Object
20 21 22 23 24 |
# File 'lib/rouge/lexers/jsonnet.rb', line 20 def self.declarations @declarations ||= Set.new %w( function ) end |
.keywords ⇒ Object
13 14 15 16 17 18 |
# File 'lib/rouge/lexers/jsonnet.rb', line 13 def self.keywords @keywords ||= Set.new %w( self super local for in if then else import importstr error tailstrict assert ) end |