omniaretail / nimator

Light-weight adhoc framework for creating monitoring apps with c-sharp based system-checks.
MIT License
10 stars 9 forks source link

Having "Nimator" as both a class and namespace creates confusion #16

Open jeroenheijmans opened 8 years ago

jeroenheijmans commented 8 years ago

The Nimator.ExampleConsoleApp has this example code:

var json = reader.ReadToEnd();
return Nimator.FromSettings(logger, json);

However, if you create a new fresh console application and reference Nimator, and copy-paste said code to your code file, you'll not be able to compile. Instead, you need to do this:

var json = reader.ReadToEnd();
return Nimator.Nimator.FromSettings(logger, json); // <-- Subtly different! "Nimator.Nimator..."

This is caused by the fact that the default namespace for the example app is part of a sub-namespace (Nimator.ExampleConsoleApp) of the Nimator namespace, whereas the fresh console app isn't.

Bottom line: it's confusing to have both a class and a namespace called "Nimator". Please consider changing this setup.