5 int main(int argc, char **argv) {
7 // test filter set/get/exception
9 std::cout << "\nTRY" << "\n";
12 filter.name("filter1");
13 std::cout << "filter: " << filter.name() << "\n";
15 filter.name() = "filter1 rename";
16 std::cout << "filter: " << filter.name() << "\n";
18 throw yp2::Filter_Exception("finished");
20 catch (std::exception &e) {
21 std::cout << e.what() << "\n";
26 std::cout << "\nTRY" << "\n";
29 filter1.name("filter1");
32 filter2.name() = "filter2";
34 std::cout << "filter1 filter2" << "\n";
37 router1.rule(filter1);
38 std::cout << "router1.rule(filter1)" << "\n";
41 router2.rule(filter2);
42 std::cout << "router2.rule(filter2)" << "\n";
45 pack_in.data(7).router(router1);
46 std::cout << "pack_in.data(7).router(router1)" << "\n";
49 std::cout << "pack_in.move()" << "\n";
51 pack_in.router(router2);
52 std::cout << "pack_in.router(router2)" << "\n";
55 std::cout << "pack_in.move()" << "\n";
57 throw yp2::Router_Exception("finished");
60 catch (std::exception &e) {
61 std::cout << e.what() << "\n";
68 * indent-tabs-mode: nil
70 * vim: shiftwidth=4 tabstop=8 expandtab