WorkstationFile class | QSYS API Reference Guide

Estimated reading time: 13 minutes

Represents a Workstation file. It contains methods to handle all Input and Output operations on the file.

Namespace: ASNA.QSys.Runtime Assembly: ASNA.QSys.Runtime.dll

Inheritance: Object –> FileBase –> WorkstationFileBase

Methods

Signature Description
allocateBuffer() Allocates internal objects and constructs the file DataSet.
attachBuffer(AdgDataSet) Set this file’s DataSet to the given AdgDataSet.
ChainByRRN(String, Int32, Char[]) Read a record by relative record number.
ChainByRRN(String, Int32, Indicator[]) Read a record by relative record number.
ChainByRRN(String, Int32, IDS) Read a record by relative record number.
ChainByRRN(String, Decimal, Char[]) Read a record by relative record number.
ChainByRRN(String, Decimal, Indicator[]) Read a record by relative record number.
ChainByRRN(String, Decimal, IDS) Read a record by relative record number.
DeleteByRRN(String, Int32) Delete a record by relative record number.
DeleteByRRN(String, Decimal) Delete a record by relative record number.
ExFmt(String, Indicator[]) Execute Format operation (Write followed by Read).
Read(String, IDS) Read a record.
Read(String, Char[]) Read a record.
Read(String, Indicator[]) Read a record.
Update(String, Indicator[]) Update a record.
Update(String, Indicator[], IDS) Update a record.
UpdateFlds(String, String[]) Update a record, only the given named fields.
Write(String, Indicator[]) Executes WRITE record operation.
Write(String, Indicator[], IDS) Executes WRITE record operation.
WriteSubfile(String, Int32, Char[]) Executes WRITE Subfile record operation.
WriteSubfile(String, Int32, Indicator[]) Executes WRITE Subfile record operation.
WriteSubfile(String, Decimal, Char[]) Executes WRITE Subfile record operation.
WriteSubfile(String, Decimal, Indicator[]) Executes WRITE Subfile record operation.

AdgDataSet allocateBuffer()

Allocates internal objects and constructs the file DataSet.

AdgDataSet allocateBuffer()

void attachBuffer(AdgDataSet adgDataSet)

Set this file’s DataSet to the given AdgDataSet.

void attachBuffer(AdgDataSet adgDataSet)

Parameters

Type Parameter name Description
AdgDataSet adgDataSet The dataset to attach.

bool ChainByRRN(string formatName, int rrn, Char[] optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, int rrn, Char[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Int32 rrn Relative record number of the record to read.
Char[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool ChainByRRN(string formatName, int rrn, Indicator[] optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, int rrn, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Int32 rrn Relative record number of the record to read.
Indicator[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool ChainByRRN(string formatName, int rrn, IDS optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, int rrn, IDS optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Int32 rrn Relative record number of the record to read.
IDS optionIndicators Indicator data structure to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool ChainByRRN(string formatName, decimal rrn, Char[] optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, decimal rrn, Char[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Decimal rrn Relative record number of the record to read.
Char[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool ChainByRRN(string formatName, decimal rrn, Indicator[] optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, decimal rrn, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Decimal rrn Relative record number of the record to read.
Indicator[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool ChainByRRN(string formatName, decimal rrn, IDS optionIndicators)

Read a record by relative record number.

bool ChainByRRN(string formatName, decimal rrn, IDS optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Decimal rrn Relative record number of the record to read.
IDS optionIndicators Indicator data structure to use in the read operation.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool DeleteByRRN(string formatName, int rrn)

Delete a record by relative record number.

bool DeleteByRRN(string formatName, int rrn)

Parameters

Type Parameter name Description
String formatName Name of the record format to delete.
Int32 rrn Relative record number of the record to delete.

Returns

Type Description
Boolean True if record is found, false otherwise.

bool DeleteByRRN(string formatName, decimal rrn)

Delete a record by relative record number.

bool DeleteByRRN(string formatName, decimal rrn)

Parameters

Type Parameter name Description
String formatName Name of the record format to delete.
Decimal rrn Relative record number of the record to delete.

Returns

Type Description
Boolean True if record is found, false otherwise.

void ExFmt(string formatName, Indicator[] optionIndicators)

Execute Format operation (Write followed by Read).

void ExFmt(string formatName, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to execute.
Indicator[] optionIndicators Indicator array to use in the operation.

bool Read(string formatName, IDS indDS)

Read a record.

bool Read(string formatName, IDS indDS)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
IDS indDS Indicator data structure to use in the read operation.

Returns

Type Description
Boolean True if record is found, False otherwise.

bool Read(string formatName, Char[] optionIndicators)

Read a record.

bool Read(string formatName, Char[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Char[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, False otherwise.

bool Read(string formatName, Indicator[] optionIndicators)

Read a record.

bool Read(string formatName, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Indicator[] optionIndicators Indicator array to use in the read operation.

Returns

Type Description
Boolean True if record is found, False otherwise.

void Update(string formatName, Indicator[] optionIndicators)

Update a record.

void Update(string formatName, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to update.
Indicator[] optionIndicators Indicator array to use in the update operation.

void Update(string formatName, Indicator[] optionIndicators, IDS fromDS)

Update a record.

void Update(string formatName, Indicator[] optionIndicators, IDS fromDS)

Parameters

Type Parameter name Description
String formatName Name of the record format to update.
Indicator[] optionIndicators Indicator array to use in the update operation.
IDS fromDS Input indicator Data Structure.

void UpdateFlds(string formatName, String[] fields)

Update a record, only the given named fields.

void UpdateFlds(string formatName, String[] fields)

Parameters

Type Parameter name Description
String formatName Name of the record format to update.
String[] fields Input field name collection.

void Write(string formatName, Indicator[] optionIndicators)

Executes WRITE record operation.

void Write(string formatName, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Input format name.
Indicator[] optionIndicators Indicator array to use in the read operation.

void Write(string formatName, Indicator[] optionIndicators, IDS fromDS)

Executes WRITE record operation.

void Write(string formatName, Indicator[] optionIndicators, IDS fromDS)

Parameters

Type Parameter name Description
String formatName Input format name.
Indicator[] optionIndicators Indicator array to use in the read operation.
IDS fromDS Input Indicator Data Structure.

bool WriteSubfile(string formatName, int rrn, Char[] optionIndicators)

Executes WRITE Subfile record operation.

bool WriteSubfile(string formatName, int rrn, Char[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Int32 rrn Input subfile Relative Record Number.
Char[] optionIndicators Input Option indicators.

Returns

Type Description
Boolean True if NOT End of File condition reached, False otherwise.

bool WriteSubfile(string formatName, int rrn, Indicator[] optionIndicators)

Executes WRITE Subfile record operation.

bool WriteSubfile(string formatName, int rrn, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Int32 rrn Input subfile Relative Record Number.
Indicator[] optionIndicators Input Option indicators.

Returns

Type Description
Boolean True if NOT End of File condition reached, False otherwise.

bool WriteSubfile(string formatName, decimal rrn, Char[] optionIndicators)

Executes WRITE Subfile record operation.

bool WriteSubfile(string formatName, decimal rrn, Char[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Decimal rrn Input subfile Relative Record Number.
Char[] optionIndicators Input Option indicators.

Returns

Type Description
Boolean True if NOT End of File condition reached, False otherwise.

bool WriteSubfile(string formatName, decimal rrn, Indicator[] optionIndicators)

Executes WRITE Subfile record operation.

bool WriteSubfile(string formatName, decimal rrn, Indicator[] optionIndicators)

Parameters

Type Parameter name Description
String formatName Name of the record format to read.
Decimal rrn Input subfile Relative Record Number.
Indicator[] optionIndicators Input Option indicators.

Returns

Type Description
Boolean True if NOT End of File condition reached, False otherwise.