mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Most important changes: - introduced feature iterator for QgsVectorLayer - vector editing moved to QgsVectorEditBuffer - complete rework of undo/redo commands for vector layers - geometry cache separated from editing (QgsVectorLayerCache) - non-essential editing functionality moved to QgsVectorLayerEditUtils
43 lines
1.4 KiB
Plaintext
43 lines
1.4 KiB
Plaintext
class QgsVectorLayerJoinBuffer
|
|
{
|
|
%TypeHeaderCode
|
|
#include <qgsvectorlayerjoinbuffer.h>
|
|
%End
|
|
public:
|
|
QgsVectorLayerJoinBuffer();
|
|
~QgsVectorLayerJoinBuffer();
|
|
|
|
/**Joins another vector layer to this layer
|
|
@param joinInfo join object containing join layer id, target and source field */
|
|
void addJoin( QgsVectorJoinInfo joinInfo );
|
|
|
|
/**Removes a vector layer join*/
|
|
void removeJoin( const QString& joinLayerId );
|
|
|
|
/**Updates field map with joined attributes
|
|
@param fields map to append joined attributes
|
|
*/
|
|
void updateFields( QgsFields& fields );
|
|
|
|
/**Calls cacheJoinLayer() for all vector joins*/
|
|
void createJoinCaches();
|
|
|
|
/**Saves mVectorJoins to xml under the layer node*/
|
|
void writeXml( QDomNode& layer_node, QDomDocument& document ) const;
|
|
|
|
/**Reads joins from project file*/
|
|
void readXml( const QDomNode& layer_node );
|
|
|
|
/**Quick way to test if there is any join at all*/
|
|
bool containsJoins() const;
|
|
|
|
const QList< QgsVectorJoinInfo >& vectorJoins() const;
|
|
|
|
/**Finds the vector join for a layer field index.
|
|
@param index this layers attribute index
|
|
@param fields fields of the vector layer (including joined fields)
|
|
@param sourceFieldIndex Output: field's index in source layer */
|
|
const QgsVectorJoinInfo* joinForFieldIndex( int index, const QgsFields& fields, int& sourceFieldIndex /Out/ ) const;
|
|
|
|
};
|