Runs the parser immediately instead of waiting until the next call to Run. Specify the optimizationLevel using the OptimizationLevels enumeration described below. Returns True if the optimization succeeded, False if there was an error.
Use the OptimizationLevels enumeration to specify optimization level to use to compile the script before running it.
|None||No optimizations will be performed and the script will be compiled lazily (a JIT). Your script will start quickly, but will run more slowly than the other two optimization levels. This is the default if you do not precompile before calling Run.|
|Low||The script will be compiled up front, but few optimizations will be applied. It will take longer for your script to start, but it will run more quickly.|
|High||The script will be compiled up front and all possible optimizations should be ran. This will take the most time to compile the script, but it will run the quickest.|
This precompiles a script with an optimization level of "High" before it runs: