Partilhar via


TaskCommandLineEventArgs Class

Definition

This class is used by tasks to log their command lines. This class extends BuildMessageEventArgs so that command lines can be logged as messages. Logging a command line is only relevant for tasks that wrap an underlying executable/tool, or emulate a shell command. Tasks that have no command line equivalent should not raise this extended message event.

public ref class TaskCommandLineEventArgs : Microsoft::Build::Framework::BuildMessageEventArgs
[System.Serializable]
public class TaskCommandLineEventArgs : Microsoft.Build.Framework.BuildMessageEventArgs
[<System.Serializable>]
type TaskCommandLineEventArgs = class
    inherit BuildMessageEventArgs
Public Class TaskCommandLineEventArgs
Inherits BuildMessageEventArgs
Inheritance
Inheritance
Attributes

Remarks

WARNING: marking a type [Serializable] without implementing ISerializable imposes a serialization contract -- it is a promise to never change the type's fields i.e. the type is immutable; adding new fields in the next version of the type without following certain special FX guidelines, can break both forward and backward compatibility

Constructors

TaskCommandLineEventArgs()

Default (family) constructor.

TaskCommandLineEventArgs(String, String, MessageImportance, DateTime)

Creates an instance of this class for the given task command line. This constructor allows the timestamp to be set

TaskCommandLineEventArgs(String, String, MessageImportance)

Creates an instance of this class for the given task command line.

Fields

locker

Lock object.

(Inherited from LazyFormattedBuildEventArgs)

Properties

BuildEventContext

Event contextual information for the build event argument

(Inherited from BuildEventArgs)
Code

Code associated with event.

(Inherited from BuildMessageEventArgs)
ColumnNumber

Column number of interest in associated file.

(Inherited from BuildMessageEventArgs)
CommandLine

Gets the task command line associated with this event.

EndColumnNumber

Ending column number of interest in associated file.

(Inherited from BuildMessageEventArgs)
EndLineNumber

Ending line number of interest in associated file.

(Inherited from BuildMessageEventArgs)
File

File associated with event.

(Inherited from BuildMessageEventArgs)
HelpKeyword

Custom help keyword associated with event.

(Inherited from BuildEventArgs)
Importance

Importance of the message

(Inherited from BuildMessageEventArgs)
LineNumber

Line number of interest in associated file.

(Inherited from BuildMessageEventArgs)
Message

Gets the formatted message.

(Inherited from LazyFormattedBuildEventArgs)
Message

Text of event.

(Inherited from BuildEventArgs)
ProjectFile

The project which was building when the message was issued.

(Inherited from BuildMessageEventArgs)
RawMessage

Exposes the underlying message field without side-effects. Used for serialization.

(Inherited from BuildEventArgs)
RawTimestamp

Exposes the private timestamp field to derived types. Used for serialization. Avoids the side effects of calling the Timestamp getter.

(Inherited from BuildEventArgs)
SenderName

Name of the object sending this event.

(Inherited from BuildEventArgs)
Subcategory

The custom sub-type of the event.

(Inherited from BuildMessageEventArgs)
TaskName

Gets the name of the task that raised this event.

ThreadId

The thread that raised event.

(Inherited from BuildEventArgs)
Timestamp

The time when event was raised.

(Inherited from BuildEventArgs)

Applies to