Search Results for

    Show / Hide Table of Contents

    Class Comments

    Comments, and the rule that decides where one starts.

    Inheritance
    object
    Comments
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Link.Foundation.Links.Notation
    Assembly: Link.Foundation.Links.Notation.dll
    Syntax
    public static class Comments
    Remarks

    # starts a comment when it opens a token: at the start of the document or after a space, a tab or a line break. A # written inside a token (issue#1047) or inside a delimited reference ("# not a comment") is an ordinary character.

    Fields

    | Edit this page View Source

    Comment

    The character that starts a comment.

    Declaration
    public const char Comment = '#'
    Field Value
    Type Description
    char

    Methods

    | Edit this page View Source

    StripComments(string)

    Blanks every comment of a document.

    Declaration
    public static string StripComments(string document)
    Parameters
    Type Name Description
    string document

    The document to read.

    Returns
    Type Description
    string

    The same document with the characters of every comment replaced by spaces.

    Remarks

    Every character of a comment is replaced rather than removed, so every later character keeps the position it had in the document the caller wrote, and anything the parser reports about a position still points at what the reader can see.

    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX