NTrace 1.0.0.50

There is a newer version of this package available.
See the version list below for details.
dotnet add package NTrace --version 1.0.0.50                
NuGet\Install-Package NTrace -Version 1.0.0.50                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="NTrace" Version="1.0.0.50" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add NTrace --version 1.0.0.50                
#r "nuget: NTrace, 1.0.0.50"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install NTrace as a Cake Addin
#addin nuget:?package=NTrace&version=1.0.0.50

// Install NTrace as a Cake Tool
#tool nuget:?package=NTrace&version=1.0.0.50                

Introduction

Trace is a trace management for logging operations in .NET.

Its purpose is to encapsulate trace operations for different locations (e.g. console, file etc.). In addition trace messages can be categorized to be filtered at application level. The following sections show the details

Trace Service Management

The core component is the trace management service which controls registered tracers and handles also the categories. Only messages matching the wanted categories will be processed by each known tracer

Register Tracers

Initially no tracers are known to the service. To associate a tracer it has to be registered. This is a task that is done at the very beginning of each application. A tracer has to implement the ITracer interface. In the current release there are only a few build-in tracers available. This will grow in the future.

Build-In Tracers

For the current release there are the following build-in tracers available:

  • ConsoleTracer
  • FileTracer
  • DelegateTracer

Tracer-Adapters

NLog is supported via an adapter, check out NuGet package NTrace.Adapters.NLog for more information

Trace Types

A message can be traced of a specific type, like:

  • Error
  • Warning
  • Information

Trace Categories

To control the purpose of a traced message, it can be assigned a specific category. The following categories are available right now:

  • Application
  • Connection
  • Method
  • Data
  • Query
  • Debug

At application level, these categories can be combined (e.g. Data | Query) where you only want to see those data in you log to keep it clean. But if writing an error, the message will be traced, regardless of the filtered category.

IoC Support

NTrace is designed for the use in an IoC (Inversion of Control scenario) environment. For that it provides an interface ITraceService.

Product Compatible and additional computed target framework versions.
.NET Framework net461 is compatible.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on NTrace:

Package Downloads
NTrace.Adapters.NLog

NLog Adapter for NTrace

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.1.1 502 1/7/2021
2.1.0 488 11/27/2020
2.0.0 566 10/30/2020
1.2.0.53 558 11/12/2019
1.1.0.52 810 9/30/2019
1.0.0.50 759 9/10/2019
0.5.0.47 701 10/22/2018
0.4.0.46 728 10/19/2018
0.3.0.45 767 10/10/2018
0.2.0.41 717 9/27/2018

Features:

- [#57] - Add support of delegates as a tracer
- [#58] - Add support of NLog as a tracer
- [#59] - Improved writing of string data (containing quotes)