|
Sparksee 6.1.0
|
Base TypeExporter class. More...
#include <TypeExporter.h>

Public Member Functions | |
| virtual | ~TypeExporter () |
| Destructor. | |
| void | Register (TypeExporterListener &tel) |
| Registers a new listener. | |
| virtual void | Run () throw (sparksee::gdb::IOException, sparksee::gdb::WrongArgumentError, sparksee::gdb::Error) =0 |
| Runs export process. | |
| void | SetRowWriter (RowWriter &rw) |
| Sets the output data destination. | |
| void | SetGraph (sparksee::gdb::Graph &graph) |
| Sets the graph that will be exported. | |
| void | SetType (sparksee::gdb::type_t type) |
| Sets the type to be exported. | |
| void | SetAttributes (sparksee::gdb::AttributeList &attrs) |
| Sets the list of Attributes. | |
| void | SetFrequency (sparksee::gdb::int32_t freq) |
| Sets the frequency of listener notification. | |
| void | SetHeader (sparksee::gdb::bool_t header) |
| Sets the presence of a header row. | |
Protected Member Functions | |
| TypeExporter () | |
| Creates a new instance. | |
| TypeExporter (RowWriter &rw, sparksee::gdb::Graph &g, sparksee::gdb::type_t t, sparksee::gdb::AttributeList &attrs) | |
| Creates a new instance with the minimum common required arguments. | |
| sparksee::gdb::bool_t | CanRun () |
| Checks that all the required settings are ready to run. | |
| void | NotifyListeners (const TypeExporterEvent &ev) |
| Notifies progress to all registered listeners. | |
| void | RunProcess () throw (sparksee::gdb::IOException, sparksee::gdb::WrongArgumentError, sparksee::gdb::Error) |
| Runs export process. | |
| void | SetHeadAttribute (sparksee::gdb::attr_t attr) |
| Sets the attribute that will be used to get the value to be dumped for the head of the edge. | |
| void | SetHeadPosition (sparksee::gdb::int32_t pos) |
| Sets the position (index column) of the head attribute in the exported data. | |
| void | SetTailAttribute (sparksee::gdb::attr_t attr) |
| Sets the attribute that will be used to get the value to be dumped for the tail of the edge. | |
| void | SetTailPosition (sparksee::gdb::int32_t pos) |
| Sets the position (index column) of the tail attribute in the exported data. | |
Base TypeExporter class.
Base class to export a node or edge type from a graph using a RowWriter.
TypeExporterListener can be registered to receive information about the progress of the export process by means of TypeExporterEvent. The default frequency of notification to listeners is 100000.
By default no header row is created.
Check out the 'Data export' section in the SPARKSEE User Manual for more details on this.
|
protected |
|
protected |
Checks that all the required settings are ready to run.
|
protected |
Notifies progress to all registered listeners.
| ev | [in] Progress event to be notified. |
| void TypeExporter::Register | ( | TypeExporterListener & | tel | ) |
Registers a new listener.
| tel | [in] TypeExporterListener to be registered. |
References Register().
Referenced by Register().
|
pure virtual | ||||||||||||||||||||
Runs export process.
| IOException | If bad things happen writting to the RowWriter. |
| WrongArgumentError | In case of bad settings |
| Error | For other issues |
Implemented in EdgeTypeExporter, and NodeTypeExporter.
References Run().
Referenced by Run().
|
protected | ||||||||||||||||||||
Runs export process.
| IOException | If bad things happen writting to the RowWriter. |
| WrongArgumentError | In case of bad settings |
| Error | For other issues |
| void TypeExporter::SetAttributes | ( | sparksee::gdb::AttributeList & | attrs | ) |
Sets the list of Attributes.
| attrs | [in] Attribute identifiers to be exported |
References SetAttributes().
Referenced by SetAttributes().
| void TypeExporter::SetFrequency | ( | sparksee::gdb::int32_t | freq | ) |
Sets the frequency of listener notification.
| freq | [in] Frequency in number of rows managed to notify progress to all listeners |
References SetFrequency().
Referenced by SetFrequency().
| void TypeExporter::SetGraph | ( | sparksee::gdb::Graph & | graph | ) |
Sets the graph that will be exported.
| graph | [in] Graph. |
References SetGraph().
Referenced by SetGraph().
|
protected |
Sets the attribute that will be used to get the value to be dumped for the head of the edge.
This method is protected because only the Edge exporters should have it.
| attr | [in] Head Attribute |
References SetHeadAttribute().
Referenced by EdgeTypeExporter::EdgeTypeExporter(), EdgeTypeExporter::SetHeadAttribute(), and SetHeadAttribute().
| void TypeExporter::SetHeader | ( | sparksee::gdb::bool_t | header | ) |
Sets the presence of a header row.
| header | [in] If TRUE, a header row is dumped with the name of the attributes. |
References END_SPARKSEE_IO_NAMESPACE, and SetHeader().
Referenced by SetHeader().
|
protected |
Sets the position (index column) of the head attribute in the exported data.
This method is protected because only the Edge exporters should have it.
| pos | [in] Head position |
References SetHeadPosition().
Referenced by EdgeTypeExporter::EdgeTypeExporter(), EdgeTypeExporter::SetHeadPosition(), and SetHeadPosition().
| void TypeExporter::SetRowWriter | ( | RowWriter & | rw | ) |
Sets the output data destination.
| rw | [in] Input RowWriter. |
References SetRowWriter().
Referenced by SetRowWriter().
|
protected |
Sets the attribute that will be used to get the value to be dumped for the tail of the edge.
This method is protected because only the Edge exporters should have it.
| attr | [in] Tail Attribute |
References SetTailAttribute().
Referenced by EdgeTypeExporter::EdgeTypeExporter(), EdgeTypeExporter::SetTailAttribute(), and SetTailAttribute().
|
protected |
Sets the position (index column) of the tail attribute in the exported data.
This method is protected because only the Edge exporters should have it.
| pos | [in] Tail position |
References SetTailPosition().
Referenced by EdgeTypeExporter::EdgeTypeExporter(), EdgeTypeExporter::SetTailPosition(), and SetTailPosition().
| void TypeExporter::SetType | ( | sparksee::gdb::type_t | type | ) |