Class: Saxon::XSLT::StaticContext::DSL Private
- Inherits:
-
Object
- Object
- Saxon::XSLT::StaticContext::DSL
- Includes:
- Common
- Defined in:
- lib/saxon/xslt/static_context.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Provides the hooks for constructing a Saxon::XSLT::StaticContext with a DSL.
Class Method Summary collapse
-
.define(block, args = {}) ⇒ Saxon::XPath::StaticContext
private
Create an instance based on the args hash, and execute the passed in Proc/lambda against it using
#instance_execand return a new Saxon::XSLT::StaticContext with the results.
Instance Method Summary collapse
-
#default_collation(collation_uri) ⇒ Object
private
Set the default Collation to use.
Methods included from Common
Class Method Details
.define(block, args = {}) ⇒ Saxon::XPath::StaticContext
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Create an instance based on the args hash, and execute the passed in Proc/lambda against it using #instance_exec and return a new Saxon::XSLT::StaticContext with the results
33 34 35 36 37 |
# File 'lib/saxon/xslt/static_context.rb', line 33 def self.define(block, args = {}) dsl = new(args) dsl.instance_exec(&block) unless block.nil? StaticContext.new(dsl.args_hash) end |
Instance Method Details
#default_collation(collation_uri) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Set the default Collation to use. This should be one of the special collation URIs Saxon recognises, or one that has been registered using Saxon::Processor#declare_collations on the Processor that created the Compiler this context is for.
45 46 47 |
# File 'lib/saxon/xslt/static_context.rb', line 45 def default_collation(collation_uri) @default_collation = collation_uri end |