Aztec® Programming Language
Version 1.1 Alpha 2

Copyright © 2010-2017, Aztec Development Group, All Rights Reserved

Download Aztec

Search        Contact Us

And though I'll never forget your face...

Sometimes I can't remember my name.

- Adam Duritz

 

aztec.system.DynamicCodeException

public class DynamicCodeException from<ExceptionEvent>

Base

Event

ExceptionEvent

DynamicCodeException

The DynamicCodeException class is used to report a compiler error which can occur during a dynamic compile process with one of the Script.LoadModule() methods, the Script.CompileMethod() methods, or the Script.Interpret() family of classes. Any compiler error which is found during the dynamic compilation process will cause this exception to be created and fired by the system. Currently, it only fires a single exception for the entire process, and it only reports the first error found. If a source code file is specified for any of the dynamic compilation methods and it is not found, that will also be reported with this exception.

 

When any of the dynamic compilation methods in the Script class are used, an "exceptions/handle" block should be used, looking for this exception.

DynamicCodeException Methods

DynamicCodeException() Constructor for the DynamicCodeException class
SourceCode() Returns source code or file name containing the compiler error
ErrorId() Returns compiler error which caused the dynamic code exception
ErrorString() Returns a string representing the compiler error
ErrorRow() Returns the one based error row where the error occurred
ErrorColumn() Returns the one based error column where the error occurred

Derived Classes

See Also

  


DynamicCodeException()

public method DynamicCodeException(string SourceCode, int IOError, string ErrorString, int ErrorRow, int ErrorColumn)

Parameters

string

Source Code string or the file name containing the source code

int

Compiler error identifier for the exception

string

Text description for the compiler error

int

Row number in source code where the first error occurred

int

Column number in source code where the first error occurred

Return Value

None

Description

Constructor for the DynamicCodeException class using the source code (or file name) containing the compiler error, and other information about the compiler error. This exception is normally created automatically by the Aztec system.

 

DynamicCodeException Class


SourceCode()

public method<string> SourceCode()

Parameters

None

Return Value

Source code or the file name containing the source code

Description

This method returns the actual source code, or the file name, which contains the specified compile error. If the error is caused by a LoadModule() call and the "IsFile" flag was set to true, then this will be the file name. If the "IsFile" flag is false, or if the error occurs during any of the Interpret() methods, then this will contain the actual source code which was being compiled.

 

DynamicCodeException Class


ErrorId()

public method<int> ErrorId()

Parameters

None

Return Value

Error id

Description

This method returns the compiler error identifier associated with the dynamic code exception.

 

DynamicCodeException Class


ErrorString()

public method<string> ErrorString()

Parameters

None

Return Value

Description for the specified compile error

Description

This method returns a description of the compile error which occurred during the LoadModule() method or Interpret() family of methods.

 

DynamicCodeException Class


ErrorRow()

public method<int> ErrorRow()

Parameters

None

Return Value

Row where error occurred

Description

This method returns the one based row number within the dynamic code where the first compiler error occurred.

 

DynamicCodeException Class


ErrorColumn()

public method<int> ErrorColumn()

Parameters

None

Return Value

Column where error occurred

Description

This method returns the one based column number within the dynamic code where the first compiler error occurred.

 

DynamicCodeException Class

 

Copyright © 2010-2017

Aztec Development Group

All Rights Reserved

Download Aztec