CodeOwnersParseException Class

The exception thrown by CodeOwnersFile.Parse when a CODEOWNERS file is invalid.

public sealed class CodeOwnersParseException : Exception
Inheritance
Exception CodeOwnersParseException

Constructors

NameDescription
CodeOwnersParseException()Initializes a new instance of CodeOwnersParseException.
CodeOwnersParseException(string?)Initializes a new instance of CodeOwnersParseException with the specified message.
CodeOwnersParseException(string?, Exception?)Initializes a new instance of CodeOwnersParseException with the specified message and inner exception.

CodeOwnersParseException overloads

CodeOwnersParseException()

CodeOwnersParseException.cs

Initializes a new instance of CodeOwnersParseException.

public CodeOwnersParseException()

CodeOwnersParseException(string?)

CodeOwnersParseException.cs

Initializes a new instance of CodeOwnersParseException with the specified message.

public CodeOwnersParseException(string? message)
Parameters
message string?

CodeOwnersParseException(string?, Exception?)

CodeOwnersParseException.cs

Initializes a new instance of CodeOwnersParseException with the specified message and inner exception.

public CodeOwnersParseException(string? message, Exception? innerException)
Parameters
message string?
innerException Exception?

Properties

NameDescription
ErrorGets the error that made the file invalid. Its CodeOwnersParseError.LineNumber is 0 when the exception was not created by the parser.

Gets the error that made the file invalid. Its CodeOwnersParseError.LineNumber is 0 when the exception was not created by the parser.

public CodeOwnersParseError Error { get; }

Property value

CodeOwnersParseError