Program.cs
38 lines
| 772 B
| text/x-csharp
|
CSharpLexer
/ Implab.Playground / Program.cs
cin
|
r267 | using System; | ||
cin
|
r277 | using System.Collections.Generic; | ||
cin
|
r268 | using System.Diagnostics; | ||
cin
|
r284 | using System.Dynamic; | ||
cin
|
r272 | using System.Linq; | ||
cin
|
r278 | using Implab.Components; | ||
cin
|
r268 | using Implab.Diagnostics; | ||
cin
|
r267 | using Implab.ServiceHost.Unity; | ||
cin
|
r229 | using Implab.Xml; | ||
cin
|
r267 | using Unity; | ||
using Unity.Injection; | ||||
cin
|
r272 | using Unity.Registration; | ||
cin
|
r229 | |||
namespace Implab.Playground { | ||||
cin
|
r286 | using static Trace<Bar>; | ||
class Foo { | ||||
cin
|
r277 | |||
cin
|
r267 | } | ||
cin
|
r286 | class Bar : Foo { | ||
cin
|
r278 | |||
cin
|
r267 | } | ||
cin
|
r229 | public class Program { | ||
cin
|
r255 | static void Main(string[] args) { | ||
cin
|
r279 | |||
cin
|
r286 | using(TraceRegistry.Global.Subscribe(ch => { | ||
Console.WriteLine($"{ch.Id}: {ch.Source.Name}"); | ||||
}, true)) { | ||||
Trace<Foo>.Log("Hi!"); | ||||
Log("Respect!"); | ||||
cin
|
r272 | } | ||
cin
|
r233 | } | ||
cin
|
r229 | |||
} | ||||
} | ||||