@@ -36,42 +36,42 @@ using MsieJavaScriptEngine.Helpers;
36
36
37
37
namespace MsieJavaScriptEngine .Example .Console
38
38
{
39
- class Program
40
- {
41
- static void Main (string [] args )
42
- {
43
- try
44
- {
45
- using (var jsEngine = new MsieJsEngine ())
46
- {
47
- const string expression = " 7 * 8 - 20" ;
48
- var result = jsEngine .Evaluate <int >(expression );
49
-
50
- Console .WriteLine (" {0} = {1}" , expression , result );
51
- }
52
- }
53
- catch (JsEngineLoadException e )
54
- {
55
- Console .WriteLine (" During loading of JavaScript engine an error occurred." );
56
- Console .WriteLine ();
57
- Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
58
- }
59
- catch (JsScriptException e )
60
- {
61
- Console .WriteLine (" During processing of JavaScript code an error occurred." );
62
- Console .WriteLine ();
63
- Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
64
- }
65
- catch (JsException e )
66
- {
67
- Console .WriteLine (" During working of JavaScript engine an unknown error occurred." );
68
- Console .WriteLine ();
69
- Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
70
- }
71
-
72
- Console .ReadLine ();
73
- }
74
- }
39
+ class Program
40
+ {
41
+ static void Main (string [] args )
42
+ {
43
+ try
44
+ {
45
+ using (var jsEngine = new MsieJsEngine ())
46
+ {
47
+ const string expression = " 7 * 8 - 20" ;
48
+ var result = jsEngine .Evaluate <int >(expression );
49
+
50
+ Console .WriteLine (" {0} = {1}" , expression , result );
51
+ }
52
+ }
53
+ catch (JsEngineLoadException e )
54
+ {
55
+ Console .WriteLine (" During loading of JavaScript engine an error occurred." );
56
+ Console .WriteLine ();
57
+ Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
58
+ }
59
+ catch (JsScriptException e )
60
+ {
61
+ Console .WriteLine (" During processing of JavaScript code an error occurred." );
62
+ Console .WriteLine ();
63
+ Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
64
+ }
65
+ catch (JsException e )
66
+ {
67
+ Console .WriteLine (" During working of JavaScript engine an unknown error occurred." );
68
+ Console .WriteLine ();
69
+ Console .WriteLine (JsErrorHelpers .GenerateErrorDetails (e ));
70
+ }
71
+
72
+ Console .ReadLine ();
73
+ }
74
+ }
75
75
}
76
76
```
77
77
@@ -94,49 +94,49 @@ Also, when you create an instance of the <code title="MsieJavaScriptEngine.MsieJ
94
94
Consider in detail properties of the <code title =" MsieJavaScriptEngine.JsEngineSettings " >JsEngineSettings</code > class:
95
95
96
96
<table border =" 1 " style =" font-size : 0.7em " >
97
- <thead>
98
- <tr valign="top">
99
- <th>Property name</th>
100
- <th>Data type</th>
101
- <th>Default value</th>
102
- <th>Description</th>
103
- </tr>
104
- </thead>
105
- <tbody>
106
- <tr valign="top">
107
- <td><code>EnableDebugging</code></td>
108
- <td><code title="System.Boolean">Boolean</code></td>
109
- <td><code>false</code></td>
110
- <td>Flag for whether to allow debugging in Visual Studio by adding the <code>debugger</code> statement to script code.</td>
111
- </tr>
112
- <tr valign="top">
113
- <td><code>EngineMode</code></td>
114
- <td><code title="MsieJavaScriptEngine.JsEngineMode">JsEngineMode</code> enumeration</td>
115
- <td><code>Auto</code></td>
116
- <td>JavaScript engine mode.</td>
117
- </tr>
118
- <tr valign="top">
119
- <td><code>MaxStackSize</code></td>
120
- <td><code title="System.Int32">Int32</code></td>
121
- <td><code>503 808</code> or <code>1 007 616</code></td>
122
- <td>
123
- <p>Maximum stack size in bytes.</p>
124
- <p>Set a <code>0</code> to use the default maximum stack size specified in the header for the executable.</p>
125
- </td>
126
- </tr>
127
- <tr valign="top">
128
- <td><code>UseEcmaScript5Polyfill</code></td>
129
- <td><code title="System.Boolean">Boolean</code></td>
130
- <td><code>false</code></td>
131
- <td>Flag for whether to use the ECMAScript 5 Polyfill.</td>
132
- </tr>
133
- <tr valign="top">
134
- <td><code>UseJson2Library</code></td>
135
- <td><code title="System.Boolean">Boolean</code></td>
136
- <td><code>false</code></td>
137
- <td>Flag for whether to use the <a href="http://github.com/douglascrockford/JSON-js">JSON2</a> library</td>
138
- </tr>
139
- </tbody>
97
+ <thead>
98
+ <tr valign="top">
99
+ <th>Property name</th>
100
+ <th>Data type</th>
101
+ <th>Default value</th>
102
+ <th>Description</th>
103
+ </tr>
104
+ </thead>
105
+ <tbody>
106
+ <tr valign="top">
107
+ <td><code>EnableDebugging</code></td>
108
+ <td><code title="System.Boolean">Boolean</code></td>
109
+ <td><code>false</code></td>
110
+ <td>Flag for whether to allow debugging in Visual Studio by adding the <code>debugger</code> statement to script code.</td>
111
+ </tr>
112
+ <tr valign="top">
113
+ <td><code>EngineMode</code></td>
114
+ <td><code title="MsieJavaScriptEngine.JsEngineMode">JsEngineMode</code> enumeration</td>
115
+ <td><code>Auto</code></td>
116
+ <td>JavaScript engine mode.</td>
117
+ </tr>
118
+ <tr valign="top">
119
+ <td><code>MaxStackSize</code></td>
120
+ <td><code title="System.Int32">Int32</code></td>
121
+ <td><code>503 808</code> or <code>1 007 616</code></td>
122
+ <td>
123
+ <p>Maximum stack size in bytes.</p>
124
+ <p>Set a <code>0</code> to use the default maximum stack size specified in the header for the executable.</p>
125
+ </td>
126
+ </tr>
127
+ <tr valign="top">
128
+ <td><code>UseEcmaScript5Polyfill</code></td>
129
+ <td><code title="System.Boolean">Boolean</code></td>
130
+ <td><code>false</code></td>
131
+ <td>Flag for whether to use the ECMAScript 5 Polyfill.</td>
132
+ </tr>
133
+ <tr valign="top">
134
+ <td><code>UseJson2Library</code></td>
135
+ <td><code title="System.Boolean">Boolean</code></td>
136
+ <td><code>false</code></td>
137
+ <td>Flag for whether to use the <a href="http://github.com/douglascrockford/JSON-js">JSON2</a> library</td>
138
+ </tr>
139
+ </tbody>
140
140
</table >
141
141
142
142
0 commit comments