|
GiNaC
1.6.2
|
00001 00005 /* 00006 * GiNaC Copyright (C) 1999-2011 Johannes Gutenberg University Mainz, Germany 00007 * 00008 * This program is free software; you can redistribute it and/or modify 00009 * it under the terms of the GNU General Public License as published by 00010 * the Free Software Foundation; either version 2 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * This program is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License 00019 * along with this program; if not, write to the Free Software 00020 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00021 */ 00022 00023 #include "print.h" 00024 00025 #include <iostream> 00026 00027 namespace GiNaC { 00028 00030 unsigned next_print_context_id = 0; 00031 00032 00033 GINAC_IMPLEMENT_PRINT_CONTEXT(print_context, void) 00034 GINAC_IMPLEMENT_PRINT_CONTEXT(print_dflt, print_context) 00035 GINAC_IMPLEMENT_PRINT_CONTEXT(print_latex, print_context) 00036 GINAC_IMPLEMENT_PRINT_CONTEXT(print_python, print_context) 00037 GINAC_IMPLEMENT_PRINT_CONTEXT(print_python_repr, print_context) 00038 GINAC_IMPLEMENT_PRINT_CONTEXT(print_tree, print_context) 00039 GINAC_IMPLEMENT_PRINT_CONTEXT(print_csrc, print_context) 00040 GINAC_IMPLEMENT_PRINT_CONTEXT(print_csrc_float, print_csrc) 00041 GINAC_IMPLEMENT_PRINT_CONTEXT(print_csrc_double, print_csrc) 00042 GINAC_IMPLEMENT_PRINT_CONTEXT(print_csrc_cl_N, print_csrc) 00043 00044 print_context::print_context() 00045 : s(std::cout), options(0) {} 00046 print_context::print_context(std::ostream & os, unsigned opt) 00047 : s(os), options(opt) {} 00048 00049 print_dflt::print_dflt() 00050 : print_context(std::cout) {} 00051 print_dflt::print_dflt(std::ostream & os, unsigned opt) 00052 : print_context(os, opt) {} 00053 00054 print_latex::print_latex() 00055 : print_context(std::cout) {} 00056 print_latex::print_latex(std::ostream & os, unsigned opt) 00057 : print_context(os, opt) {} 00058 00059 print_python::print_python() 00060 : print_context(std::cout) {} 00061 print_python::print_python(std::ostream & os, unsigned opt) 00062 : print_context(os, opt) {} 00063 00064 print_python_repr::print_python_repr() 00065 : print_context(std::cout) {} 00066 print_python_repr::print_python_repr(std::ostream & os, unsigned opt) 00067 : print_context(os, opt) {} 00068 00069 print_tree::print_tree() 00070 : print_context(std::cout), delta_indent(4) {} 00071 print_tree::print_tree(unsigned d) 00072 : print_context(std::cout), delta_indent(d) {} 00073 print_tree::print_tree(std::ostream & os, unsigned opt, unsigned d) 00074 : print_context(os, opt), delta_indent(d) {} 00075 00076 print_csrc::print_csrc() 00077 : print_context(std::cout) {} 00078 print_csrc::print_csrc(std::ostream & os, unsigned opt) 00079 : print_context(os, opt) {} 00080 00081 print_csrc_float::print_csrc_float() 00082 : print_csrc(std::cout) {} 00083 print_csrc_float::print_csrc_float(std::ostream & os, unsigned opt) 00084 : print_csrc(os, opt) {} 00085 00086 print_csrc_double::print_csrc_double() 00087 : print_csrc(std::cout) {} 00088 print_csrc_double::print_csrc_double(std::ostream & os, unsigned opt) 00089 : print_csrc(os, opt) {} 00090 00091 print_csrc_cl_N::print_csrc_cl_N() 00092 : print_csrc(std::cout) {} 00093 print_csrc_cl_N::print_csrc_cl_N(std::ostream & os, unsigned opt) 00094 : print_csrc(os, opt) {} 00095 00096 } // namespace GiNaC