2008-06-30 23:57:58 +00:00
|
|
|
#include "parser.h"
|
2008-06-30 06:51:22 +00:00
|
|
|
#include <fstream>
|
2008-06-30 23:57:58 +00:00
|
|
|
#include <iostream>
|
2008-06-25 22:45:08 +00:00
|
|
|
|
|
|
|
|
int main()
|
|
|
|
|
{
|
2008-06-30 06:51:22 +00:00
|
|
|
std::ifstream fin("test.yaml");
|
2008-06-30 23:57:58 +00:00
|
|
|
YAML::Parser parser(fin);
|
|
|
|
|
|
2008-06-30 06:51:22 +00:00
|
|
|
YAML::Document doc;
|
2008-07-01 06:28:10 +00:00
|
|
|
while(parser) {
|
|
|
|
|
std::cout << "---\n";
|
|
|
|
|
parser.GetNextDocument(doc);
|
|
|
|
|
std::cout << doc;
|
|
|
|
|
}
|
2008-06-30 23:57:58 +00:00
|
|
|
getchar();
|
2008-06-25 22:45:08 +00:00
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|