Class: Typst::Query
Instance Attribute Summary collapse
-
#format ⇒ Object
Returns the value of attribute format.
-
#result(raw: false) ⇒ Object
Returns the value of attribute result.
Attributes inherited from Base
#font_paths, #input, #root, #sys_inputs
Instance Method Summary collapse
-
#initialize(selector, input, field: nil, one: false, format: "json", root: ".", font_paths: [], sys_inputs: {}) ⇒ Query
constructor
A new instance of Query.
Methods inherited from Base
Constructor Details
#initialize(selector, input, field: nil, one: false, format: "json", root: ".", font_paths: [], sys_inputs: {}) ⇒ Query
Returns a new instance of Query.
189 190 191 192 193 |
# File 'lib/typst.rb', line 189 def initialize(selector, input, field: nil, one: false, format: "json", root: ".", font_paths: [], sys_inputs: {}) super(input, root: root, font_paths: font_paths, sys_inputs: sys_inputs) self.format = format self.result = Typst::_query(selector, field, one, format, self.input, self.root, self.font_paths, File.dirname(__FILE__), false, sys_inputs) end |
Instance Attribute Details
#format ⇒ Object
Returns the value of attribute format.
186 187 188 |
# File 'lib/typst.rb', line 186 def format @format end |
#result(raw: false) ⇒ Object
Returns the value of attribute result.
187 188 189 |
# File 'lib/typst.rb', line 187 def result @result end |