Log I/O
Loading...
Searching...
No Matches
LisInformationRecord Class Reference

Base class for records holding information. More...

Inherits LisRecord.

Inherited by LisJobIdentificationRecord, LisToolStringInfoRecord, and LisWellSiteDataRecord.

Public Member Functions

void AddRow ()
 Add a table row with empty values to this component.
 
void AddRow (IList< object > values)
 Add a table row to this component.
 
int FindColumn (string columnName)
 Find column with the specified name.
 
string GetColumnName (int columnNo)
 Return the name of the specified column.
 
LisComponent GetComponent (int rowNo, string columnName)
 Return the component of from the specified column in the given row.
 
LisComponent GetComponentAt (int rowNo, int columnNo)
 Return component at the specified index.
 
IList< LisComponentGetComponents ()
 Return the components of this record.
 
string GetName ()
 Return name of this information record.
 
int GetNColumns ()
 Return number of columns of information.
 
int GetNRows ()
 Return number of rows of information.
 
bool IsTable ()
 Check if this record contains a table of information.
 
 LisInformationRecord (int recordType, IList< LisComponent > components)
 Create a LIS information record.
 
void RemoveRow (int rowNo)
 Remove the specified row from this record.
 
override string ToString ()
 
- Public Member Functions inherited from LisRecord
int GetAttributes ()
 Return attributes of this record.
 
int GetRecordType ()
 Return type of this record.
 
override string ToString ()
 

Protected Member Functions

 LisInformationRecord (int recordType, string tableName, IList< string > columnNames)
 Create an empty information record table with a set of prepared column names as specified.
 
- Protected Member Functions inherited from LisRecord
 LisRecord (int recordType, int attributes)
 Create a new LIS record.
 

Additional Inherited Members

- Static Public Attributes inherited from LisRecord
const int ALTERNATE_DATA = 1
 Type 1: Alternate data.
 
const int BLANK = 234
 Type 234: Blank.
 
const int BOOTSTRAP_LOADER = 96
 Type 96: Bootstrap loader.
 
const int COMMENT = 232
 Type 232: Comment.
 
const int DATA_FORMAT_SPECIFICATION = 64
 Type 64: Data format specification.
 
const int ENCRYPTED_TABLE = 42
 Type 42: Encrypted table dump.
 
const int FILE_HEADER = 128
 Type 128: File header.
 
const int FILE_TRAILER = 129
 Type 129: File trailer.
 
const int IMAGE = 86
 Type 86: Image.
 
const int JOB_IDENTIFICATION = 32
 Type 32: Information (job identification).
 
const int KERNEL_LOADER_BOOT = 97
 Type 97: CP-Kernel loader boot.
 
const int LOGICAL_BOT = 138
 Type 138: Logical beginning-of-tape.
 
const int LOGICAL_EOF = 137
 Type 137: Logical end-of-file.
 
const int LOGICAL_EOM = 141
 Type 141: Logical end-of-medium.
 
const int LOGICAL_EOT = 139
 Type 139: Logical end-of-tap.
 
const int NORMAL_DATA = 0
 Type 0: Normal data.
 
const int OPERATOR_COMMAND_INPUTS = 224
 Type 224: Operator command inputs.
 
const int OPERATOR_RESPONSE_INPUTS = 225
 Type 225: Operator response inputs.
 
const int PICTURE = 85
 Type 85: Picture.
 
const int PROGRAM_OVERLAY_HEADER = 101
 Type 101: Program overlay header.
 
const int PROGRAM_OVERLAY_LOAD = 102
 Type 102: Program overlay load.
 
const int REEL_HEADER = 132
 Type 132: Reel header.
 
const int REEL_TRAILER = 133
 Type 133: Reel trailer.
 
const int SOFTWARE_BOOT = 95
 Type 95: TU10 Software boot.
 
const int SYSTEM_OUTPUTS_TO_OPERATOR = 227
 Type 227: System outputs to operator.
 
const int TABLE_DUMP = 47
 Type 47: Table dump.
 
const int TAPE_HEADER = 130
 Type 130: Tape header.
 
const int TAPE_TRAILER = 131
 Type 131: Tape trailer.
 
const int TOOL_STRING_INFO = 39
 Type 39: Information (tool string info).
 
const int WELL_SITE_DATA = 34
 Type 34: Information (well site data).
 

Detailed Description

Base class for records holding information.

Information records can be of two types, a one-dimensional list or a two-dimensional table.

A table is identified by having the first record as type = 73. Then each row of the table is started with a record of type = 0, being the component of the first column cell, and then N records of type = 69 being the cells for the consecutive columns.

See LIS 79 Documentation Section 4.1.3.

Author
Petroware AS

Constructor & Destructor Documentation

◆ LisInformationRecord() [1/2]

LisInformationRecord ( int recordType,
IList< LisComponent > components )

Create a LIS information record.

Parameters
recordTypeInformation record type.
componentsThe components that makes up the record. Non-null.
Exceptions
ArgumentNullExceptionIf components is null.

◆ LisInformationRecord() [2/2]

LisInformationRecord ( int recordType,
string tableName,
IList< string > columnNames )
protected

Create an empty information record table with a set of prepared column names as specified.

Actual content to the table is added through the AddRow() method.

Parameters
recordTypeInformation record type.
tableNameTable name. Non-null.
columnNamesName of columns. Non-null and with at least two entries.
Exceptions
ArgumentNullExceptionIf tableName or columnNames are null.

Member Function Documentation

◆ AddRow()

void AddRow ( IList< object > values)

Add a table row to this component.

Parameters
valuesThe values making up the table row. Should have as many entries as the table has columns.
Exceptions
ArgumentNullExceptionIf values is null
ArgumentExceptionIf number of values doesn't match the number of columns in the table.

◆ FindColumn()

int FindColumn ( string columnName)

Find column with the specified name.

Case-insensitive search.

Parameters
columnNameName of column to locate. Non-null.
Returns
Requested column number (0-based) or -1 if not found.
Exceptions
ArgumentNullExceptionIf columnName is null

◆ GetColumnName()

string GetColumnName ( int columnNo)

Return the name of the specified column.

Parameters
columnNoColumn to get name of. [0,nColumns>.
Returns
The requested column name. Never null.
Exceptions
ArgumentExceptionIf columnNo is out of bounds.

◆ GetComponent()

LisComponent GetComponent ( int rowNo,
string columnName )

Return the component of from the specified column in the given row.

Parameters
rowNoRow number to pick from. [0,nRows>
columnNameName of column to get value from. Non-null.
Returns
The requested component, or null if the column could not be found.
Exceptions
ArgumentNullExceptionIf rowNo is out of bounds or columnName is null.

◆ GetComponentAt()

LisComponent GetComponentAt ( int rowNo,
int columnNo )

Return component at the specified index.

Parameters
rowNoRow number index. [0,nRows>
columnNoColumn number index. [0,nRColumns>
Returns
The requested component. Null if there is no component at this location.
Exceptions
ArgumentExceptionIf rowNo or columnNo are out of bounds.

◆ GetComponents()

IList< LisComponent > GetComponents ( )

Return the components of this record.

Returns
The components of this record. Never null.

◆ GetName()

string GetName ( )

Return name of this information record.

A name is only provided for table data, and in that case it is the value of the table identifying component.

Returns
The name of this information record. Null if non-provided or N/A.

◆ GetNColumns()

int GetNColumns ( )

Return number of columns of information.

Returns
Number of information columns.

◆ GetNRows()

int GetNRows ( )

Return number of rows of information.

For a non-table record this will be the number of contained components.

Returns
Number of information rows. [0,>.

◆ IsTable()

bool IsTable ( )

Check if this record contains a table of information.

Returns
True if this is a table of information, otherwise it is a one-dimensional list.

◆ RemoveRow()

void RemoveRow ( int rowNo)

Remove the specified row from this record.

Parameters
rowNoRow to remove. [0,nRows>.
Exceptions
ArgumentExceptionIf rowNo is out of bounds.

The documentation for this class was generated from the following file: