2.2.3 - Error Return Object - JdlError

John W. Campbell

2.2.3.1 Introduction

This is a class used to return error information from methods. It is used extensively throughout this package. The JdlError object returns a logical flag indicating whether or not an error was found, a numerical flag indicating the nature of the error and two message strings which may be used to return descriptions of the error condition. The returned items are accessed as public fields.

Constructor, Fields and Methods:

Class Details
Accessible Fields
Constructor
Clear Error Method

2.2.3.2 Class Details

Package:
Jdl.JdlLib;
Class name:
JdlError
Class definition:
public class JdlError
Extends:
Object
Implements:
none
Actions:
none

2.2.3.3 Accessible Fields

The following accessible fields have been defined:

public boolean err
Error flag = true error, = false OK - 'err'.
public int flag
Error type (Dependent on method where the object is used to return error status) - 'flag'
public String msg1
Error message 1 (may be null) - 'msg1'
public String msg2
Error message 2 (may be null) - 'msg2'

2.2.3.4 Constructor

2.2.3.4.1 Introduction

A single constructor is available.

Constructor:

Constructor 1

2.2.3.4.2 Constructor 1

Create a JdlError object with error flags set to false and 0 and with null messages.

Constructor Definition:
public JdlError()
Parameters List:
none

2.2.3.5 Clear Error Method

2.2.3.5.1 Introduction

A single method is available to clear the contents of the JdlError object.

Method:

Clear error object - clear

2.2.3.5.2 Clear error object - clear

This clears the contents of the JdlError object setting 'err = false', 'flag = 0', 'msg1 = null' and 'msg2 = null'.

Method Definition:
public void clear()
Parameters List:
none

⇑ Up 2   ⇑ Up 1   ⇑ Top of this