Example program to test JLANG::JObjectMultiplexer and JLANG::JObjectDemultiplexer classes.
More...
#include <string>
#include <iostream>
#include <iomanip>
#include <vector>
#include "JLang/JSTDObjectReader.hh"
#include "JLang/JSTDObjectWriter.hh"
#include "JLang/JObjectMultiplexer.hh"
#include "JLang/JObjectDemultiplexer.hh"
#include "Jeep/JParser.hh"
#include "Jeep/JMessage.hh"
Go to the source code of this file.
|
int | main (int argc, char **argv) |
|
int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 100 of file JObjectDemultiplexer.cc.
108 JParser<> zap(
"Example program to test object multiplexing and demultiplexing.");
114 catch(
const exception &error) {
115 FATAL(error.what() << endl);
124 for (
int i = 1;
i != 4; ++
i) {
130 cout <<
"a_in ";
copy(a_in.begin(), a_in.end(), ostream_iterator<__A__>(cout,
" ")); cout << endl;
131 cout <<
"b_in ";
copy(b_in.begin(), b_in.end(), ostream_iterator<__B__>(cout,
" ")); cout << endl;
137 JSTDObjectReader<typelist>
in;
143 JSTDObjectWriter<typelist> out;
152 JObjectMultiplexer<typelist> multiplexer (
in);
154 JObjectDemultiplexer<__A__, typelist> demultiplexer(out);
157 multiplexer >> demultiplexer;
160 cout <<
"a_out ";
copy(a_out.begin(), a_out.end(), ostream_iterator<__A__>(cout,
" ")); cout << endl;
161 cout <<
"b_out ";
copy(b_out.begin(), b_out.end(), ostream_iterator<__B__>(cout,
" ")); cout << endl;
Utility class to parse command line options.
#define ASSERT(A,...)
Assert macro.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
void copy(const Head &from, JHead &to)
Copy header from from to to.
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS for EMITTER in