38 #ifndef PI_PROPERTIES_TABLEHEADER_SERIALIZER 39 #define PI_PROPERTIES_TABLEHEADER_SERIALIZER 54 template<
typename o_stream>
69 header.push_back(std::string(
""));
121 if ( line ==
int(header.size()) )
124 header.push_back(std::string(
""));
126 header[line-1] += std::string(
" | ") +
s;
128 return header[line-1].length();
133 if ( line ==
int(header.size() ) )
134 header.push_back(std::string(
""));
138 if (
int(header[line-1].length()) -
int(header[line].length()) > 0 )
141 header[
line] += std::string(
" | ");
143 if (
int(header[line-1].length()) -
int(header[line].length()) > 0 )
144 header[
line] += std::string( header[line-1].length() - header[line].length() ,
' ');
151 std::string name = v.
getName();
152 if ( v.
value().getType() !=
"type_less")
153 name+= std::string(
" <") + v.
value().getType() + std::string(
">");
160 if ( v.
value().getProperties().empty() )
161 store( std::string(
"<empty>") );
169 if (
int(header[line].length()) - int(header[line -1].length()) > 0)
170 header[line-1] += std::string( header[line].length() - header[line-1].length(),
' ');
175 for (std::vector<std::string>::iterator it = header.begin(); it != header.end(); ++it)
177 *this->
s << *it <<std::string(
" |")<<std::endl;
182 header.push_back(std::string(
""));
Properties & getProperties()
Properties::const_iterator const_iterator
const std::string & getName() const
StreamProcessor(o_stream &_s)