Table of Contents

Class FileBlock

Namespace
RDCore.SDK.Workspace
Assembly
RDCore.SDK.Protocols.dll

A module that a block of a source file declares: its name, what kind of module it is, and the lines of the file it spans.

public sealed record FileBlock : IEquatable<FileBlock>
Inheritance
FileBlock
Implements
Inherited Members

Constructors

FileBlock(string, FileBlockKind, int, int)

A module that a block of a source file declares: its name, what kind of module it is, and the lines of the file it spans.

public FileBlock(string Name, FileBlockKind Kind, int HeaderLine, int EndLine)

Parameters

Name string

The module's name, as the block's header writes it.

Kind FileBlockKind

Whether the block declares a standard module or a class module.

HeaderLine int

The zero-based line of the block's header (Class Name, Module Name).

EndLine int

The zero-based line of the block's end (End Class, End Module).

Properties

CreatableColumn

The zero-based column of HeaderLine where the header writes Creatable, whose nine characters start there; null when it does not write it (IsCreatable is then false).

public int? CreatableColumn { get; init; }

Property Value

int?

EndLine

The zero-based line of the block's end (End Class, End Module).

public int EndLine { get; init; }

Property Value

int

HeaderLine

The zero-based line of the block's header (Class Name, Module Name).

public int HeaderLine { get; init; }

Property Value

int

IsCreatable

Whether the block's header writes Creatable before Class (Creatable Class Name); a Module block's never does.

public bool IsCreatable { get; init; }

Property Value

bool

Remarks

This is what the header writes, and nothing more: what Creatable makes of a class is the language's to say.

IsPartial

Whether the block's header writes Partial before its kind (Partial Class Name, Partial Module Name).

public bool IsPartial { get; init; }

Property Value

bool

Remarks

This is what the header writes, and nothing more: what Partial makes of a module is the language's to say.

Kind

Whether the block declares a standard module or a class module.

public FileBlockKind Kind { get; init; }

Property Value

FileBlockKind

KindColumn

The zero-based column of HeaderLine where the header writes the block's kind, Class or Module, in whatever case it writes it. The word spans the length of its Kind's name from there.

public int KindColumn { get; init; }

Property Value

int

Name

The module's name, as the block's header writes it.

public string Name { get; init; }

Property Value

string

NameColumn

The zero-based column of HeaderLine where the header writes the module's name. The name spans Name's length from there, which is what a rename of the module edits.

public int NameColumn { get; init; }

Property Value

int

PartialColumn

The zero-based column of HeaderLine where the header writes Partial, whose seven characters start there; null when it does not write it (IsPartial is then false).

public int? PartialColumn { get; init; }

Property Value

int?

Visibility

The visibility the block's header states before its kind (Public Class Name, Private Module Name): Public or Private; null when the header states none.

public AccessModifier? Visibility { get; init; }

Property Value

AccessModifier?

Remarks

This is what the header writes, and nothing more: what a module with no stated visibility is, and what a visibility makes of a module, is the language's to say.

VisibilityColumn

The zero-based column of HeaderLine where the header writes its visibility, Public or Private; null when it writes none (Visibility is then null too). The word spans the length of its Visibility's name from there.

public int? VisibilityColumn { get; init; }

Property Value

int?