ScriptLocation Struct

A location in the source of a running script (see ScriptEngine.GetCurrentScriptLocation): the source file, line number and column number of the violations of the content security policies (https://w3c.github.io/webappsec-csp/#create-violation-for-global, step 2).

public readonly struct ScriptLocation : IEquatable<ScriptLocation>
Implements

Constructors

NameDescription
ScriptLocation(string, int, int)A location in the source of a running script (see ScriptEngine.GetCurrentScriptLocation): the source file, line number and column number of the violations of the content security policies (https://w3c.github.io/webappsec-csp/#create-violation-for-global, step 2).

ScriptLocation(string, int, int)

A location in the source of a running script (see ScriptEngine.GetCurrentScriptLocation): the source file, line number and column number of the violations of the content security policies (https://w3c.github.io/webappsec-csp/#create-violation-for-global, step 2).

public ScriptLocation(string Url, int LineNumber, int ColumnNumber)

Parameters

Url string
The URL of the script (the URL of the document for an inline script or an event handler), as requested by the page (before the redirects).
LineNumber int
The line (1-based).
ColumnNumber int
The column (1-based).

Properties

NameDescription
ColumnNumberThe column (1-based).
LineNumberThe line (1-based).
UrlThe URL of the script (the URL of the document for an inline script or an event handler), as requested by the page (before the redirects).

ColumnNumber

ScriptLocation.cs

The column (1-based).

public int ColumnNumber { get; init; }

Property value

int

The line (1-based).

public int LineNumber { get; init; }

Property value

int

The URL of the script (the URL of the document for an inline script or an event handler), as requested by the page (before the redirects).

public string Url { get; init; }

Property value

string

Methods

NameDescription
Deconstruct(string, int, int)
Equals(ScriptLocation)
Equals(object)
GetHashCode()
ToString()

Deconstruct(string, int, int)

public void Deconstruct(out string Url, out int LineNumber, out int ColumnNumber)

Parameters

Url string
LineNumber int
ColumnNumber int

No documentation is available.

Equals overloads

Equals(ScriptLocation)

public bool Equals(ScriptLocation other)
Parameters
other ScriptLocation
Returns

bool

No documentation is available.

Equals(object)

public override bool Equals(object obj)
Parameters
obj object
Returns

bool

No documentation is available.

GetHashCode()

public override int GetHashCode()

Returns

int

No documentation is available.

ToString()

public override string ToString()

Returns

string

No documentation is available.

Operators

NameDescription
operator ==(ScriptLocation, ScriptLocation)
operator !=(ScriptLocation, ScriptLocation)

operator ==(ScriptLocation, ScriptLocation)

public static bool operator ==(ScriptLocation left, ScriptLocation right)

Parameters

left ScriptLocation
right ScriptLocation

Returns

bool

No documentation is available.

operator !=(ScriptLocation, ScriptLocation)

public static bool operator !=(ScriptLocation left, ScriptLocation right)

Parameters

left ScriptLocation
right ScriptLocation

Returns

bool

No documentation is available.