CapyKit/Documentation/Help/M_CapyKit_CapyEventReporter_EmitEventOnce.md

2.3 KiB

EmitEventOnce Method

Emits an event with the given severity level, message, unique identifier, and method name one time.

Definition

Namespace: CapyKit
Assembly: CapyKit (in CapyKit.dll) Version: 1.0.0

C#

public static void EmitEventOnce(
	EventLevel eventLevel,
	string message,
	string uniqueIdentifier,
	string method = null,
	params Object[] args
)

F#

static member EmitEventOnce : 
        eventLevel : EventLevel * 
        message : string * 
        uniqueIdentifier : string * 
        ?method : string * 
        args : Object[] 
(* Defaults:
        let _method = defaultArg method null
*)
-> unit 

Parameters

  EventLevel
The severity level of the event.
  String
The message describing the reason for the event. String formatting for args is accepted.
  String
A unique identifier for the event emission.
  String  (Optional)
(Optional) The name of the method where the event was raised.
  Object[]
A variable-length parameters list containing arguments for formatting the message.

Remarks

This method is similar to [!:EmitEvent(EventLevel, string, string, string, object[])] , but requires a unique identifier (such as a Guid) to prevent duplicate emissions.

See Also

Reference

CapyEventReporter Class
CapyKit Namespace
CallerMemberNameAttribute
Guid