QGIS/python/analysis/network/qgsgraphdirector.sip

51 lines
1.3 KiB
Plaintext
Raw Normal View History

2011-06-02 19:02:20 +06:00
%ModuleHeaderCode
#include <qgslinevectorlayerdirector.h>
%End
/**
* \ingroup analysis
2011-06-02 19:02:20 +06:00
* \class QgsGraphDirector
* \brief Determine making the graph. QgsGraphBuilder and QgsGraphDirector is a builder patter.
*/
class QgsGraphDirector : QObject
{
%TypeHeaderCode
#include <qgsgraphbuilder.h>
%End
%ConvertToSubClassCode
if ( dynamic_cast< QgsLineVectorLayerDirector* > ( sipCpp ) != NULL )
sipType = sipType_QgsLineVectorLayerDirector;
2011-06-02 19:02:20 +06:00
else
sipType = NULL;
2011-06-02 19:02:20 +06:00
%End
2011-06-02 19:02:20 +06:00
signals:
void buildProgress( int, int ) const;
void buildMessage( const QString& ) const;
2011-06-02 19:02:20 +06:00
public:
//! Destructor
virtual ~QgsGraphDirector();
/**
* Make a graph using QgsGraphBuilder
2011-06-02 19:02:20 +06:00
*
* @param builder the graph builder
* @param additionalPoints list of points that should be snapped to the graph
* @param tiedPoints list of snapped points
* @note if tiedPoints[i] == QgsPoint(0.0,0.0) then snapping failed.
2011-06-02 19:02:20 +06:00
*/
virtual void makeGraph( QgsGraphBuilderInterface *builder,
const QVector< QgsPoint > &additionalPoints,
QVector< QgsPoint > &snappedPoints /Out/ ) const;
//! Add optimization strategy
void addStrategy( QgsStrategy* prop /Transfer/);
//! Returns director name
2011-06-02 19:02:20 +06:00
virtual QString name() const = 0;
};