Skip to content
Permalink
Browse files

add Factory annotation to clone() methods

  • Loading branch information
3nids committed May 30, 2017
1 parent 736e303 commit 2c56f42482f2a4e3fdd34c874052977bf41d4430
@@ -137,7 +137,7 @@ Takes ownership of the provided node
:rtype: list of str
%End

QgsExpressionNode::NodeList *clone() const;
QgsExpressionNode::NodeList *clone() const /Factory/;
%Docstring
Creates a deep copy of this list. Ownership is transferred to the caller
:rtype: QgsExpressionNode.NodeList
@@ -49,7 +49,7 @@ class QgsExpressionNodeUnaryOperator : QgsExpressionNode
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;

virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

@@ -131,7 +131,7 @@ class QgsExpressionNodeBinaryOperator : QgsExpressionNode
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

int precedence() const;
@@ -187,7 +187,7 @@ class QgsExpressionNodeInOperator : QgsExpressionNode
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

};
@@ -225,7 +225,7 @@ class QgsExpressionNodeFunction : QgsExpressionNode
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

static bool validateParams( int fnIndex, QgsExpressionNode::NodeList *args, QString &error );
@@ -259,7 +259,7 @@ The value of the literal.
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

};
@@ -288,7 +288,7 @@ The name of the column.
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;

virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

};
@@ -315,7 +315,7 @@ class QgsExpressionNodeCondition : QgsExpressionNode
~WhenThen();


QgsExpressionNodeCondition::WhenThen *clone() const;
QgsExpressionNodeCondition::WhenThen *clone() const /Factory/;
%Docstring
Get a deep copy of this WhenThen combination.
:rtype: QgsExpressionNodeCondition.WhenThen
@@ -342,7 +342,7 @@ class QgsExpressionNodeCondition : QgsExpressionNode
virtual QSet<QString> referencedColumns() const;
virtual QSet<QString> referencedVariables() const;
virtual bool needsGeometry() const;
virtual QgsExpressionNode *clone() const;
virtual QgsExpressionNode *clone() const /Factory/;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const;

};
@@ -155,7 +155,7 @@ Creates a new QgsColorRamp from a map of properties
virtual QColor color( double value ) const;
virtual QString type() const;
virtual void invert();
virtual QgsGradientColorRamp *clone() const;
virtual QgsGradientColorRamp *clone() const /Factory/;
virtual QgsStringMap properties() const;

QColor color1() const;
@@ -345,7 +345,7 @@ class QgsGenericNumericTransformer : QgsPropertyTransformer
%End

virtual Type transformerType() const;
virtual QgsGenericNumericTransformer *clone();
virtual QgsGenericNumericTransformer *clone() /Factory/;
virtual QVariant toVariant() const;
virtual bool loadVariant( const QVariant &definition );
virtual QVariant transform( const QgsExpressionContext &context, const QVariant &value ) const;
@@ -143,7 +143,7 @@ class CORE_EXPORT QgsExpressionNode SIP_ABSTRACT
QStringList names() const { return mNameList; }

//! Creates a deep copy of this list. Ownership is transferred to the caller
QgsExpressionNode::NodeList *clone() const;
QgsExpressionNode::NodeList *clone() const SIP_FACTORY;

virtual QString dump() const;

@@ -57,7 +57,7 @@ class CORE_EXPORT QgsExpressionNodeUnaryOperator : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;

virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

@@ -140,7 +140,7 @@ class CORE_EXPORT QgsExpressionNodeBinaryOperator : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

int precedence() const;
@@ -198,7 +198,7 @@ class CORE_EXPORT QgsExpressionNodeInOperator : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

private:
@@ -232,7 +232,7 @@ class CORE_EXPORT QgsExpressionNodeFunction : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

//! Tests whether the provided argument list is valid for the matching function
@@ -264,7 +264,7 @@ class CORE_EXPORT QgsExpressionNodeLiteral : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

private:
@@ -293,7 +293,7 @@ class CORE_EXPORT QgsExpressionNodeColumnRef : public QgsExpressionNode
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;

virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

private:
@@ -324,7 +324,7 @@ class CORE_EXPORT QgsExpressionNodeCondition : public QgsExpressionNode
/**
* Get a deep copy of this WhenThen combination.
*/
QgsExpressionNodeCondition::WhenThen *clone() const;
QgsExpressionNodeCondition::WhenThen *clone() const SIP_FACTORY;

private:
#ifdef SIP_RUN
@@ -360,7 +360,7 @@ class CORE_EXPORT QgsExpressionNodeCondition : public QgsExpressionNode
virtual QSet<QString> referencedColumns() const override;
virtual QSet<QString> referencedVariables() const override;
virtual bool needsGeometry() const override;
virtual QgsExpressionNode *clone() const override;
virtual QgsExpressionNode *clone() const override SIP_FACTORY;
virtual bool isStatic( QgsExpression *parent, const QgsExpressionContext *context ) const override;

private:
@@ -149,7 +149,7 @@ class CORE_EXPORT QgsGradientColorRamp : public QgsColorRamp
virtual QColor color( double value ) const override;
virtual QString type() const override { return QStringLiteral( "gradient" ); }
virtual void invert() override;
virtual QgsGradientColorRamp *clone() const override;
virtual QgsGradientColorRamp *clone() const override SIP_FACTORY;
virtual QgsStringMap properties() const override;

/** Returns the gradient start color.
@@ -367,7 +367,7 @@ class CORE_EXPORT QgsGenericNumericTransformer : public QgsPropertyTransformer
QgsGenericNumericTransformer &operator=( const QgsGenericNumericTransformer &other );

virtual Type transformerType() const override { return GenericNumericTransformer; }
virtual QgsGenericNumericTransformer *clone() override;
virtual QgsGenericNumericTransformer *clone() override SIP_FACTORY;
virtual QVariant toVariant() const override;
virtual bool loadVariant( const QVariant &definition ) override;
virtual QVariant transform( const QgsExpressionContext &context, const QVariant &value ) const override;
@@ -42,7 +42,7 @@ class CORE_EXPORT Qgs25DRenderer : public QgsFeatureRenderer
void stopRender( QgsRenderContext &context ) override;

QSet<QString> usedAttributes( const QgsRenderContext &context ) const override;
QgsFeatureRenderer *clone() const override;
QgsFeatureRenderer *clone() const override SIP_FACTORY;

virtual QgsSymbol *symbolForFeature( QgsFeature &feature, QgsRenderContext &context ) override;
virtual QgsSymbolList symbols( QgsRenderContext &context ) override;
@@ -661,7 +661,7 @@ class CORE_EXPORT QgsRasterFillSymbolLayer: public QgsImageFillSymbolLayer
void startRender( QgsSymbolRenderContext &context ) override;
void stopRender( QgsSymbolRenderContext &context ) override;
QgsStringMap properties() const override;
QgsRasterFillSymbolLayer *clone() const override;
QgsRasterFillSymbolLayer *clone() const override SIP_FACTORY;
virtual double estimateMaxBleed( const QgsRenderContext &context ) const override;

//override QgsImageFillSymbolLayer's support for sub symbols
@@ -51,7 +51,7 @@ class CORE_EXPORT QgsGeometryGeneratorSymbolLayer : public QgsSymbolLayer

void stopRender( QgsSymbolRenderContext &context ) override;

QgsSymbolLayer *clone() const override;
QgsSymbolLayer *clone() const override SIP_FACTORY;

QgsStringMap properties() const override;

@@ -201,7 +201,7 @@ class CORE_EXPORT QgsMarkerLineSymbolLayer : public QgsLineSymbolLayer

QgsStringMap properties() const override;

QgsMarkerLineSymbolLayer *clone() const override;
QgsMarkerLineSymbolLayer *clone() const override SIP_FACTORY;

void toSld( QDomDocument &doc, QDomElement &element, const QgsStringMap &props ) const override;

@@ -33,7 +33,7 @@ class CORE_EXPORT QgsPointClusterRenderer: public QgsPointDistanceRenderer

QgsPointClusterRenderer();

QgsPointClusterRenderer *clone() const override;
QgsPointClusterRenderer *clone() const override SIP_FACTORY;
virtual void startRender( QgsRenderContext &context, const QgsFields &fields ) override;
void stopRender( QgsRenderContext &context ) override;
QDomElement save( QDomDocument &doc, const QgsReadWriteContext &context ) override;
@@ -43,7 +43,7 @@ class CORE_EXPORT QgsPointDisplacementRenderer: public QgsPointDistanceRenderer
*/
QgsPointDisplacementRenderer( const QString &labelAttributeName = QString() );

QgsPointDisplacementRenderer *clone() const override;
QgsPointDisplacementRenderer *clone() const override SIP_FACTORY;
virtual void startRender( QgsRenderContext &context, const QgsFields &fields ) override;
void stopRender( QgsRenderContext &context ) override;
QDomElement save( QDomDocument &doc, const QgsReadWriteContext &context ) override;
@@ -254,7 +254,7 @@ class CORE_EXPORT QgsRuleBasedRenderer : public QgsFeatureRenderer
void setActive( bool state ) { mIsActive = state; }

//! clone this rule, return new instance
Rule *clone() const;
Rule *clone() const SIP_FACTORY;

void toSld( QDomDocument &doc, QDomElement &element, QgsStringMap props ) const;

@@ -71,7 +71,7 @@ class SERVER_EXPORT QgsAccessControl : public QgsFeatureFilterProvider
/** Return a clone of the object
* \returns A clone
*/
QgsFeatureFilterProvider *clone() const;
QgsFeatureFilterProvider *clone() const SIP_FACTORY;

/** Return an additional subset string (typically SQL) filter
* \param layer the layer to control

0 comments on commit 2c56f42

Please sign in to comment.
You can’t perform that action at this time.