From: Juliana Rodrigueiro Date: Wed, 8 Aug 2018 12:13:39 +0000 (+0200) Subject: Add basic restricted_html structure X-Git-Tag: v2.10~3 X-Git-Url: http://developer.intra2net.com/git/?p=libi2ncommon;a=commitdiff_plain;h=09ca2cbf109e5f6b3d24544afd134a88e6f2838f Add basic restricted_html structure --- diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index e0eae1e..01a4e74 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -17,6 +17,7 @@ SET(cpp_sources pidfile.cpp pipestream.cpp pointer_func.cpp + restricted_html.cpp source_track_basics.cpp stringfunc.cpp timefunc.cpp @@ -45,6 +46,7 @@ SET(cpp_headers pidfile.hpp pipestream.hxx pointer_func.hpp + restricted_html.hpp source_track_basics.hpp stringfunc.hxx timefunc.hxx diff --git a/src/restricted_html.cpp b/src/restricted_html.cpp new file mode 100644 index 0000000..a157564 --- /dev/null +++ b/src/restricted_html.cpp @@ -0,0 +1,40 @@ +/* +The software in this package is distributed under the GNU General +Public License version 2 (with a special exception described below). + +A copy of GNU General Public License (GPL) is included in this distribution, +in the file COPYING.GPL. + +As a special exception, if other files instantiate templates or use macros +or inline functions from this file, or you compile this file and link it +with other works to produce a work based on this file, this file +does not by itself cause the resulting work to be covered +by the GNU General Public License. + +However the source code for this file must still be made available +in accordance with section (3) of the GNU General Public License. + +This exception does not invalidate any other reasons why a work based +on this file might be covered by the GNU General Public License. +*/ +/** @file + * @brief restricts html messages to an allowed group of tags. + * + * @copyright © Copyright 2017 Intra2net AG + * + */ + +#include + +#include +#include + +using namespace std; + + +namespace I2n +{ + + + +} // eo namespace I2n diff --git a/src/restricted_html.hpp b/src/restricted_html.hpp new file mode 100644 index 0000000..43bf2e4 --- /dev/null +++ b/src/restricted_html.hpp @@ -0,0 +1,38 @@ +/* +The software in this package is distributed under the GNU General +Public License version 2 (with a special exception described below). + +A copy of GNU General Public License (GPL) is included in this distribution, +in the file COPYING.GPL. + +As a special exception, if other files instantiate templates or use macros +or inline functions from this file, or you compile this file and link it +with other works to produce a work based on this file, this file +does not by itself cause the resulting work to be covered +by the GNU General Public License. + +However the source code for this file must still be made available +in accordance with section (3) of the GNU General Public License. + +This exception does not invalidate any other reasons why a work based +on this file might be covered by the GNU General Public License. +*/ +/** @file + * @brief restricts html code to an allowed group of tags. + * + * @copyright © Copyright 2017 Intra2net AG + * + */ + +#ifndef __RESTRICTED_HTML_HPP +#define __RESTRICTED_HTML_HPP + +#include + +namespace I2n +{ + + +} // eo namespace I2n + +#endif diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 3dfa47c..2928716 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -16,6 +16,7 @@ SET(cpp_sources test_i18n.cpp test_logging.cpp test_pidfile.cpp + test_restricted_html.cpp test_timefunc.cpp test_tmpfstream.cpp test_tribool.cpp diff --git a/test/test_restricted_html.cpp b/test/test_restricted_html.cpp new file mode 100644 index 0000000..c3971ce --- /dev/null +++ b/test/test_restricted_html.cpp @@ -0,0 +1,37 @@ +/* +The software in this package is distributed under the GNU General +Public License version 2 (with a special exception described below). + +A copy of GNU General Public License (GPL) is included in this distribution, +in the file COPYING.GPL. + +As a special exception, if other files instantiate templates or use macros +or inline functions from this file, or you compile this file and link it +with other works to produce a work based on this file, this file +does not by itself cause the resulting work to be covered +by the GNU General Public License. + +However the source code for this file must still be made available +in accordance with section (3) of the GNU General Public License. + +This exception does not invalidate any other reasons why a work based +on this file might be covered by the GNU General Public License. +*/ +/** @file + * @brief unit test for the restricted html functions. + * + * @copyright © Copyright 2017 Intra2net AG + * + */ +#define BOOST_TEST_DYN_LINK +#include + +#include + +using namespace std; +using namespace I2n; + +BOOST_AUTO_TEST_SUITE(test_restricted_html) + + +BOOST_AUTO_TEST_SUITE_END()