| tableentry : output |
Output the block to the stream.
Any other method of any other object can call this method. This is called 'public' access.
The data-type returned is "voidtype";
This method is contained in the object "tableentry".
The method takes the following arguments:
filedef : Pointer to tgl_structure_parser
Not sure.
obj : Pointer to @schemaobj
Not sure.
This method is overridden from an abstract method with the same signature found in the object @block.
The files "tgl_structure_parser.hpp", "schema/schema_obj.hpp", "../cppxmlobj/reflect/jscript_object_navigator.hpp" and "tgl_tablecol.hpp" are included.
Output an entry in a table. First we get the member named "row" in the obj object, then search for the table object.
std::string rname = obj->get(_row);
if (rname == "")
{
filedef->error("Could not find row [" + _row + "] in obj.");
return;
}
ph::reflect::jscript_object_navigator n(root(), filedef->console(), false, false);
std::string loc = _table + ".rows('" + rname + "').cols('" + _col + "')";
ph::common::object_base *no = n.navigate(this, loc);
if (!no)
{
filedef->error("Could not find location [" + loc + "] in object.");
return;
}
tgl_tablecol *o = dynamic_cast<tgl_tablecol *>(no);
if (!o)
{
filedef->error("Table column is not an obj.");
return;
}
filedef->write_output(o->get("string"));