include/relpipe/writer/RelationalWriter.h
branchv_0
changeset 27 a64afb2d24c9
parent 26 8ae93a43fed2
child 29 142bdbba520f
equal deleted inserted replaced
26:8ae93a43fed2 27:a64afb2d24c9
     3 #include <iostream>
     3 #include <iostream>
     4 #include <vector>
     4 #include <vector>
     5 
     5 
     6 #include "typedefs.h"
     6 #include "typedefs.h"
     7 #include "TypeId.h"
     7 #include "TypeId.h"
       
     8 #include "AttributeMetadata.h"
     8 
     9 
     9 namespace relpipe {
    10 namespace relpipe {
    10 namespace writer {
    11 namespace writer {
    11 
    12 
    12 class RelationalWriter {
    13 class RelationalWriter {
    26 	 * 
    27 	 * 
    27 	 * @param name name of the relation (table)
    28 	 * @param name name of the relation (table)
    28 	 * @param attributes list of attributes (columns) containing their names and types
    29 	 * @param attributes list of attributes (columns) containing their names and types
    29 	 * @param writeHeader header might be omitted – when appending new records to a stream alreaready containing the header
    30 	 * @param writeHeader header might be omitted – when appending new records to a stream alreaready containing the header
    30 	 */
    31 	 */
    31 	virtual void startRelation(string_t name, std::vector<std::pair<string_t, TypeId>> attributes, boolean_t writeHeader) = 0;
    32 	virtual void startRelation(string_t name, std::vector<AttributeMetadata> attributes, boolean_t writeHeader) = 0;
    32 
    33 
    33 	/**
    34 	/**
    34 	 * Writes a single attribute.
    35 	 * Writes a single attribute.
    35 	 * @param value string representation of value of given attribute type as defined in Specification
    36 	 * @param value string representation of value of given attribute type as defined in Specification
    36 	 */
    37 	 */