Class Location
Represents the location of a reported issue.
Implements
Inherited Members
Namespace: Unity.ProjectAuditor.Editor
Assembly: Unity.ProjectAuditor.Editor.dll
Syntax
[Serializable]
public class Location : ISerializationCallbackReceiver
Constructors
Location(string)
Constructor
Declaration
public Location(string path)
Parameters
| Type | Name | Description |
|---|---|---|
| string | path | File path |
Location(string, int)
Constructor with line number
Declaration
[JsonConstructor]
public Location(string path, int line)
Parameters
| Type | Name | Description |
|---|---|---|
| string | path | File path |
| int | line | Line number |
Properties
Extension
File extension
Declaration
[JsonIgnore]
public string Extension { get; }
Property Value
| Type | Description |
|---|---|
| string |
Filename
Filename
Declaration
[JsonIgnore]
public string Filename { get; }
Property Value
| Type | Description |
|---|---|
| string |
FormattedFilename
Formatted filename with line number
Declaration
[JsonIgnore]
public string FormattedFilename { get; }
Property Value
| Type | Description |
|---|---|
| string |
FormattedPath
Formatted path with line number
Declaration
[JsonIgnore]
public string FormattedPath { get; }
Property Value
| Type | Description |
|---|---|
| string |
IsValid
Checks whether the location is valid
Declaration
public bool IsValid { get; }
Property Value
| Type | Description |
|---|---|
| bool | True if the location is valid |
Line
Line number
Declaration
[JsonProperty("line", DefaultValueHandling = DefaultValueHandling.Ignore)]
public int Line { get; }
Property Value
| Type | Description |
|---|---|
| int |
Path
Full path
Declaration
[JsonIgnore]
public string Path { get; }
Property Value
| Type | Description |
|---|---|
| string |
Methods
OnAfterDeserialize()
Post-serialize callback.
Declaration
public void OnAfterDeserialize()
OnBeforeSerialize()
Pre-serialize callback.
Declaration
public void OnBeforeSerialize()