Table of Contents

Class ProjectBuild

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

The build section of a .rdproj project (Build, RD-VBAL §2.2.3.1): what the project builds into, and where its program starts.

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

Remarks

Its members are written outputType and entryPoint, as files have them: "build": { "outputType": "Library" }, "build": { "outputType": "ConsoleApplication" }, "build": { "entryPoint": "Module1.Main" }.

It is read as a project file written by hand may have it, and never makes a project file unreadable. An outputType other than Library or ConsoleApplication, whatever its case, is Application, and an entryPoint that is not a string, or is empty or blank, is none. What is written back is what was read, not the text it was read from: the outputType of an Application, and an entry point that is none, are left out. A build that is not an object reads as no section, and is not written back.

Properties

EntryPoint

The procedure the program starts with, as Module.Procedure or a lone Procedure, or the name of a script's module, which starts at its script; null for the script of the one standard module that is a script, or else the Sub Main of the one standard module that declares one. ProgramEntryPoint.Of finds the procedure it names.

[JsonPropertyName("entryPoint")]
[JsonConverter(typeof(ProjectEntryPointJsonConverter))]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? EntryPoint { get; init; }

Property Value

string

ExtensionData

The members of the section this model does not know, as they were read, which are written back (ExtensionData).

[JsonExtensionData]
public Dictionary<string, JsonElement>? ExtensionData { get; init; }

Property Value

Dictionary<string, JsonElement>

IsConsoleApplication

Whether the project's program runs in the console, whose user interface its run gets (ConsoleApplication).

[JsonIgnore]
public bool IsConsoleApplication { get; }

Property Value

bool

IsLibrary

Whether the project builds into a library, which has no entry point (Library).

[JsonIgnore]
public bool IsLibrary { get; }

Property Value

bool

OutputType

What the project builds into. Application unless the section says Library or ConsoleApplication.

[JsonPropertyName("outputType")]
[JsonConverter(typeof(ProjectOutputTypeJsonConverter))]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public ProjectOutputType OutputType { get; init; }

Property Value

ProjectOutputType