Class: IRPack::Specification::RuntimeOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/irpack/specification.rb

Overview

Options to script engine passed in runtime.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeRuntimeOptions

Returns a new instance of RuntimeOptions.



89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
# File 'lib/irpack/specification.rb', line 89

def initialize
  @debug_mode = false
  @no_adaptive_compilation = false
  @compilation_threshold = -1
  @exception_detail = false
  @show_clr_exceptions = false
  @warning_level = 1
  @debug_variable = false
  @profile = false
  @trace = false
  @required_paths = []
  @search_paths = []
  @pass_exceptions = false
  @private_binding = false
end

Instance Attribute Details

#compilation_thresholdObject

The number of iterations before the interpreter starts compiling (default is 32).



58
59
60
# File 'lib/irpack/specification.rb', line 58

def compilation_threshold
  @compilation_threshold
end

#debug_modeObject Also known as: D

True if emit debugging information (PDBs) for Visual Studio debugger (default is false).



54
55
56
# File 'lib/irpack/specification.rb', line 54

def debug_mode
  @debug_mode
end

#debug_variableObject Also known as: d

Debugging flags ($DEBUG) (default is false).



66
67
68
# File 'lib/irpack/specification.rb', line 66

def debug_variable
  @debug_variable
end

#exception_detailObject

True if enable ExceptionDetail mode (default is false).



60
61
62
# File 'lib/irpack/specification.rb', line 60

def exception_detail
  @exception_detail
end

#no_adaptive_compilationObject

True if disable adaptive compilation (default is false).



56
57
58
# File 'lib/irpack/specification.rb', line 56

def no_adaptive_compilation
  @no_adaptive_compilation
end

#pass_exceptionsObject

True if do not catch exceptions that are unhandled by script code.



76
77
78
# File 'lib/irpack/specification.rb', line 76

def pass_exceptions
  @pass_exceptions
end

#private_bindingObject

True if enable binding to private members.



78
79
80
# File 'lib/irpack/specification.rb', line 78

def private_binding
  @private_binding
end

#profileObject

True if enable support for IronRuby::Clr.profile (default is false).



68
69
70
# File 'lib/irpack/specification.rb', line 68

def profile
  @profile
end

#required_pathsObject Also known as: r

Required libraries before executing entry_file.



72
73
74
# File 'lib/irpack/specification.rb', line 72

def required_paths
  @required_paths
end

#search_pathsObject Also known as: I

$LOAD_PATH directories.



74
75
76
# File 'lib/irpack/specification.rb', line 74

def search_paths
  @search_paths
end

#show_clr_exceptionsObject

True if display CLS Exception information (default is false).



62
63
64
# File 'lib/irpack/specification.rb', line 62

def show_clr_exceptions
  @show_clr_exceptions
end

#traceObject

True if enable support for set_trace_func (default is false).



70
71
72
# File 'lib/irpack/specification.rb', line 70

def trace
  @trace
end

#warning_levelObject Also known as: W

Warning level; 0=silence, 1=medium (default), 2=verbose.



64
65
66
# File 'lib/irpack/specification.rb', line 64

def warning_level
  @warning_level
end

Instance Method Details

#to_hashObject



105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
# File 'lib/irpack/specification.rb', line 105

def to_hash
  {
    DebugMode:             @debug_mode,
    PrivateBinding:        @private_binding,
    NoAdaptiveCompilation: @no_adaptive_compilation,
    CompilationThreshold:  @compilation_threshold,
    ExceptionDetail:       @exception_detail,
    ShowClrExceptions:     @show_clr_exceptions,
    PassExceptions:        @pass_exceptions,
    Profile:               @profile,
    Verbosity:             @warning_level,
    DebugVariable:         @debug_variable,
    EnableTracing:         @trace,
    RequiredPaths:         @required_paths,
    SearchPaths:           @search_paths,
  }
end