I also seem to not be able to figure out what using
statement to use at the top of my file.
The nuget package is here: https://www.nuget.org/packages/csharp-extensions The method I'm trying to use from it is Object#Send
so, I call
<#objectInstanec>.Send("SomeMethod")
but the compiler says that the method is not defined on type object.
Send
is defined here though: https://github.com/NullVoxPopuli/csharp-extensions/blob/master/Extensions/Methods.cs#L26
I've tried various using statements:
using csharp_extensions.Extensions.Methods;
using csharp_extensions.Extensions;
using csharp_extensions
none seem to work (csharp_extensions
doesn't exist)
UPDATE - how I install the package
my project.json:
{
"dependencies": {
"System.Reflection": "4.1.0-beta-*",
"Microsoft.Extensions.PlatformAbstractions": "(1.0.0-rc1-final,]",
"xunit": "2.1.0-*",
"xunit.runner.dnx": "2.1.0-*",
"csharp-extensions": "1.0.1"
},
"commands": {
"test": "xunit.runner.dnx"
},
"frameworks": {
"dnxcore50": {
"_": "this is the recommended windows runtime",
"dependencies": {
"System.Console": "4.0.0-beta-*",
"System.Reflection": "4.1.0-beta-*",
"System.Reflection.TypeExtensions": "4.1.0-beta-*",
"System.Runtime.Extensions": "(4.0,]",
"System.IO": "(4.0,]",
"csharp-extensions": "1.0.1"
}
}
}
}
and then I install the dependencies via
dnu restore