ScriptException

Overview

ScriptException is the class for EcmaScript exceptions.

Location

 

Column  assign

Specifies column number where exception happened.

@property (assign) int32 Column

Event  retain

Specifies event

@property (retain) NSString *Event

exceptionName    (declared in ROException)

Return the exception name to be used to construct the class instance as NSException descendant. See NSException documentation for more details.

+ (NSString *) exceptionName

exceptionWithMessage:    (declared in ROException)

Constructs the excetion instance with the given text message (corresponds to reason of NSException).

+ (ROException *) exceptionWithMessage:(NSString *)aExceptionMessage

Parameters:

  • aExceptionMessage: A text string decribing the exception

fromServer  assign    (declared in ROException)

This flag is used to distinguish server side exceptions from client side ones. Set to YES for server side exceptions.

@property (assign) BOOL fromServer

initWithMessage:    (declared in ROException)

initializes a new ROException with the given error message.

- (id) initWithMessage:(NSString *)aExceptionMessage

Parameters:

  • aExceptionMessage: A text string decribing the exception

initWithMessage::::::

Initializes new instance of the ScriptException

- (id) initWithMessage:(NSString *)anExceptionMessage :(int32)aLine :(int32)aColumn :(NSString *)aEvent :(NSString *)aInnerStackTrace :(enum ScriptExceptionType)aType

Parameters:

  • anExceptionMessage: Excepition message
  • aLine: Line number at which given exception happened
  • aColumn: Column number at which given exception happened
  • aEvent: Event, where given exception happened
  • aInnerStackTrace: Inner stack trace of given exception
  • aType: Type of the ScriptException

initWithMessage:fromServer:    (declared in ROException)

Initializes a new ROException with the given error message and optionally marks the exception as having been received from a server by setting the fromServer property.

- (id) initWithMessage:(NSString *)aExceptionMessage fromServer:(BOOL)aFromServer

Parameters:

  • aExceptionMessage: A text string decribing the exception
  • aFromServer: Set to YES for server side exceptions.

InnerStackTrace  retain

Specifies inner stack trace.

@property (retain) NSString *InnerStackTrace

Line  assign

Specifies line number where exception happened.

@property (assign) int32 Line

readFromMessage:withName:

This method is used for reading the ScriptException instance from a message packet.

- (void) readFromMessage:(ROMessage *)aMessage withName:(NSString *)aName

Parameters:

  • aMessage:
  • aName:

serverStackTrace  copy    (declared in ROException)

Used to store the stack trace of server exception. The availability of this information depends on the server platform.

@property (copy) NSString *serverStackTrace

Type  assign

Specifies the type of the ScriptException

@property (assign) enum ScriptExceptionType Type

writeToMessage:withName:

Metod serializes ScriptException with given name into given message.

- (void) writeToMessage:(ROMessage *)aMessage withName:(NSString *)aName

Parameters:

  • aMessage:
  • aName:

 

Column  assign

Specifies column number where exception happened.

@property (assign) int32 Column

Event  retain

Specifies event

@property (retain) NSString *Event

fromServer  assign    (declared in ROException)

This flag is used to distinguish server side exceptions from client side ones. Set to YES for server side exceptions.

@property (assign) BOOL fromServer

InnerStackTrace  retain

Specifies inner stack trace.

@property (retain) NSString *InnerStackTrace

Line  assign

Specifies line number where exception happened.

@property (assign) int32 Line

serverStackTrace  copy    (declared in ROException)

Used to store the stack trace of server exception. The availability of this information depends on the server platform.

@property (copy) NSString *serverStackTrace

Type  assign

Specifies the type of the ScriptException

@property (assign) enum ScriptExceptionType Type

 

exceptionName    (declared in ROException)

Return the exception name to be used to construct the class instance as NSException descendant. See NSException documentation for more details.

+ (NSString *) exceptionName

exceptionWithMessage:    (declared in ROException)

Constructs the excetion instance with the given text message (corresponds to reason of NSException).

+ (ROException *) exceptionWithMessage:(NSString *)aExceptionMessage

Parameters:

  • aExceptionMessage: A text string decribing the exception

 

initWithMessage:    (declared in ROException)

initializes a new ROException with the given error message.

- (id) initWithMessage:(NSString *)aExceptionMessage

Parameters:

  • aExceptionMessage: A text string decribing the exception

initWithMessage::::::

Initializes new instance of the ScriptException

- (id) initWithMessage:(NSString *)anExceptionMessage :(int32)aLine :(int32)aColumn :(NSString *)aEvent :(NSString *)aInnerStackTrace :(enum ScriptExceptionType)aType

Parameters:

  • anExceptionMessage: Excepition message
  • aLine: Line number at which given exception happened
  • aColumn: Column number at which given exception happened
  • aEvent: Event, where given exception happened
  • aInnerStackTrace: Inner stack trace of given exception
  • aType: Type of the ScriptException

initWithMessage:fromServer:    (declared in ROException)

Initializes a new ROException with the given error message and optionally marks the exception as having been received from a server by setting the fromServer property.

- (id) initWithMessage:(NSString *)aExceptionMessage fromServer:(BOOL)aFromServer

Parameters:

  • aExceptionMessage: A text string decribing the exception
  • aFromServer: Set to YES for server side exceptions.

readFromMessage:withName:

This method is used for reading the ScriptException instance from a message packet.

- (void) readFromMessage:(ROMessage *)aMessage withName:(NSString *)aName

Parameters:

  • aMessage:
  • aName:

writeToMessage:withName:

Metod serializes ScriptException with given name into given message.

- (void) writeToMessage:(ROMessage *)aMessage withName:(NSString *)aName

Parameters:

  • aMessage:
  • aName:

See Also