This repo contains the source for YamlVB, a .NET Yaml parsing library.
Parse commonly found YAML patterns that could be used when driving a console program operation. See some of the test cases for ideas.
Exercise of .NET regexes.
This is as an overengineering exercise in .NET Regexes and VB.NET 2008. There's nothing bad about over-engineering when used for discovering the limits of a specific technology.
To each one his own, but personally, I like C# way better than VB.NET for doing things in .NET. VB.NET syntax is more convoluted and I just can't do a lot of handy developer things like:
- Nice inline list initialization. VB.NET2010, fares a bit better.
- No inline dictionary initialization.
- No multi-line strings.
- Incomplete operator overloading.
- Based on the above, it would be very difficult to design a fluent API.
As you may see, the test cases are all writte in C# because writing them in VB.NET was extremely counter-intuitive.
Ideas for improvement:
Using extension methods could make the program easier to read.
For my requirements none. Although the parser is not fully functional, as I said my primary intent was an exercise and to use the parser for driving console programs via a Yaml instructions file. Code coverage is currently aabove 96%, so the parser is pretty stable.
(The MIT License)
Copyright © 2010 Pierre Jacomet
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ‘Software’), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED ‘AS IS’, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.