MessageLocation Class |
Represents the location of a message, which means, for the end-user, a line in a file of source code.
From the aspect developer, the location can be known as an object representing an element of code
(for instance a Type or MethodInfo). Such implicit locations are resolved
by PostSharp to a file and line number.
Namespace: PostSharp.Extensibility
Assembly: PostSharp (in PostSharp.dll) Version: 6.6.14.0 (6.6.14.0)
C#
[SerializableAttribute] public class MessageLocation
The MessageLocation type exposes the following members.
Name | Description | |
---|---|---|
CodeElement |
Element of code (reflection object or Declaration) from which the location must be resolved.
| |
EndColumn |
Gets the ending column in the file that caused the
message.
| |
EndLine |
Gets the ending line in the file that caused the message.
| |
File |
Gets the name of the file that caused the message.
| |
StartColumn |
Gets the starting column in the file that caused the message.
| |
StartLine |
Gets the starting line in the file that caused the message.
|
Name | Description | |
---|---|---|
Explicit(String) |
Builds a MessageLocation explicitly by specifying a filename, when the
| |
Explicit(String, Int32, Int32) |
Builds a MessageLocation explicitly by specifying a filename, line, and column.
| |
Explicit(String, Int32, Int32, Int32, Int32) |
Builds a MessageLocation explicitly by specifying a filename, line, and column.
| |
Of(Object) |
Builds a MessageLocation from an object representing an
element of code (Type, MethodInfo, ConstructorInfo,
FieldInfo, IExpression, Assembly, ParameterInfo, EventInfo,
PropertyInfo or, if
you are using PostSharp SDK, any Declaration).
| |
Of(Assembly) |
Builds a MessageLocation from an Assembly.
| |
Of(MemberInfo) |
Builds a MessageLocation from a MemberInfo (Type,
MethodInfo, ConstructorInfo, FieldInfo,
PropertyInfo, EventInfo).
| |
Of(ParameterInfo) |
Builds a MessageLocation from a ParameterInfo.
| |
Of(IExpression) |
Builds a MessageLocation from an IExpression.
| |
Of(LocationInfo) |
Builds a MessageLocation from a LocationInfo.
| |
Of(SymbolSequencePoint) |
Builds a MessageLocation from a SymbolSequencePoint.
|
Name | Description | |
---|---|---|
Unknown |
Represents an unknown or indeterminate location of the error message.
|