https://github.com/powerumc/elvisnet
Use Elvis Expression is C# 6.0 spec under C# 6.0
https://github.com/powerumc/elvisnet
Last synced: 3 months ago
JSON representation
Use Elvis Expression is C# 6.0 spec under C# 6.0
- Host: GitHub
- URL: https://github.com/powerumc/elvisnet
- Owner: powerumc
- Created: 2016-01-28T08:44:54.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-20T06:15:49.000Z (over 9 years ago)
- Last Synced: 2023-05-19T06:10:18.369Z (about 2 years ago)
- Language: C#
- Size: 20.5 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ElvisNet
Use Elvis Expression is C# 6.0 spec under C# 6.0## Basic
```C#
Expression> expression = () => Environment.CommandLine.Length;
var expect = Elvis.SafeNull(expression);
``````C#
Func func = () => Environment.CommandLine.Length;
var expect = Elvis.SafeNull(func);
```
## Extension Methods```C#
var person = new Person();
// ...
person.SafeNull();
person.SafeNull(o => o.Name.First.ToString());
```