Table of Contents

Class FileStatementAccess

Namespace
RDCore.SDK.Runtime.Abstract.Execution
Assembly
RDCore.SDK.dll

Which file statements a channel opened under a given mode and access may be used by (MS-VBAL §5.4.5.1's own table).

public static class FileStatementAccess
Inheritance
FileStatementAccess
Inherited Members

Remarks

The specification states this as one table covering every file statement, so it is encoded once here rather than restated by each of them — a statement asks whether it is allowed on a channel and reports Bad file mode when it is not. Getting it wrong in twelve places independently is the alternative.

👉 A blank cell in that table means the statement is not valid in that mode at all, whatever the access; a cell listing accesses means valid only under those.

Methods

ImpliedAccess(VBFileMode)

The access an Open with no Access clause implies, from its mode (MS-VBAL §5.4.5.1's other table).

public static VBFileAccessMode ImpliedAccess(VBFileMode mode)

Parameters

mode VBFileMode

The mode the Open declared, or defaulted to Random.

Returns

VBFileAccessMode

IsValid(string, VBFileMode, VBFileAccessMode)

Whether statement may be used on a channel opened under mode and access.

public static bool IsValid(string statement, VBFileMode mode, VBFileAccessMode access)

Parameters

statement string

The statement's keyword — a Tokens constant, including the two-keyword LineInput.

mode VBFileMode

The mode the channel was opened under.

access VBFileAccessMode

The access the channel was opened under.

Returns

bool

Remarks

A statement this table says nothing about is not restricted by it — Close and Reset are valid on any channel, and the table does not list them.