logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class AuthoringIssue

    One finding about an authored asset: how serious it is, which part of the asset it came from, and what is wrong.

    Inheritance
    object
    AuthoringIssue
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    Namespace: Serenity.Shared.Authoring
    Assembly: Serenity.Shared.dll
    Syntax
    public sealed class AuthoringIssue
    Remarks

    Engine-agnostic on purpose. A finding that names its subject and section is what lets a tool turn a message into a link — the editor can select the offending entry and open the group of fields that caused it, instead of printing a sentence about it. Rules that produce these live in Application code, so they are shared by the in-window checks, the project validator and the headless run rather than being written three times.

    Section is a plain string rather than an enum because every aggregate names its own groups; a shared enum would have to know about all of them.

    Fields

    NoSubjectIndex

    Index meaning the finding is about the asset as a whole rather than one entry in it.

    Declaration
    public const int NoSubjectIndex = -1
    Field Value
    Type Description
    int

    Properties

    IsAboutWholeAsset

    Declaration
    public bool IsAboutWholeAsset { get; }
    Property Value
    Type Description
    bool

    Whether the finding is about the asset as a whole rather than one entry in it.

    Message

    Declaration
    public string Message { get; }
    Property Value
    Type Description
    string

    What is wrong, in words the author can act on.

    Section

    Declaration
    public string Section { get; }
    Property Value
    Type Description
    string

    The group of fields the finding belongs to, named in the aggregate's own vocabulary.

    Severity

    Declaration
    public AuthoringSeverity Severity { get; }
    Property Value
    Type Description
    AuthoringSeverity

    How serious the finding is.

    SubjectId

    Declaration
    public string SubjectId { get; }
    Property Value
    Type Description
    string

    Id of the entry the finding came from, or empty when it is about the whole asset.

    SubjectIndex

    Declaration
    public int SubjectIndex { get; }
    Property Value
    Type Description
    int

    Position of that entry in the asset's list, or NoSubjectIndex when it is about the whole asset. Carried alongside the id because an entry with no id yet still has to be reachable.

    Methods

    ForAsset(AuthoringSeverity, string, string)

    A finding about the asset as a whole.

    Declaration
    public static AuthoringIssue ForAsset(AuthoringSeverity severity, string section, string message)
    Parameters
    Type Name Description
    AuthoringSeverity severity

    How serious the finding is.

    string section

    The group of fields it belongs to.

    string message

    What is wrong.

    Returns
    Type Description
    AuthoringIssue

    The finding.

    ForSubject(AuthoringSeverity, string, int, string, string)

    A finding about one entry within the asset.

    Declaration
    public static AuthoringIssue ForSubject(AuthoringSeverity severity, string subjectId, int subjectIndex, string section, string message)
    Parameters
    Type Name Description
    AuthoringSeverity severity

    How serious the finding is.

    string subjectId

    Id of the entry, which may be empty if it has not been named yet.

    int subjectIndex

    Position of the entry in the asset's list.

    string section

    The group of fields it belongs to.

    string message

    What is wrong.

    Returns
    Type Description
    AuthoringIssue

    The finding.

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    object.ToString()
    In this article
    © 2026 Serenity. All Rights Reserved