Skip to content
Permalink
Browse files

[processing] Remove ParameterGeometryPredicate

  • Loading branch information
arnaud-morvan committed Dec 12, 2016
1 parent ecb25c4 commit 322a565b8b0b8a8fd70bfaa296f1d0f9fcab95f4
@@ -1525,46 +1525,6 @@ def fromScriptCode(self, line):
[dataobjects.TYPE_VECTOR_POLYGON], isOptional)


class ParameterGeometryPredicate(Parameter):

predicates = ('intersects',
'contains',
'disjoint',
'equals',
'touches',
'overlaps',
'within',
'crosses')

def __init__(self, name='', description='', left=None, right=None,
optional=False, enabledPredicates=None):
Parameter.__init__(self, name, description, None, optional)
self.left = left
self.right = right
self.value = None
self.enabledPredicates = enabledPredicates
if self.enabledPredicates is None:
self.enabledPredicates = self.predicates

def getValueAsCommandLineParameter(self):
return str(self.value)

def setValue(self, value):
if value is None:
if not self.optional:
return False
self.value = None
return True
elif len(value) == 0 and not self.optional:
return False

if isinstance(value, str):
self.value = value.split(';') # relates to ModelerAlgorithm.resolveValue
else:
self.value = value
return True


paramClasses = [c for c in list(sys.modules[__name__].__dict__.values()) if isclass(c) and issubclass(c, Parameter)]


@@ -38,7 +38,6 @@
from qgis.gui import QgsMessageBar

from processing.gui.BatchOutputSelectionPanel import BatchOutputSelectionPanel
from processing.gui.GeometryPredicateSelectionPanel import GeometryPredicateSelectionPanel

from processing.core.parameters import ParameterFile
from processing.core.parameters import ParameterRaster
@@ -50,7 +49,6 @@
from processing.core.parameters import ParameterSelection
from processing.core.parameters import ParameterFixedTable
from processing.core.parameters import ParameterMultipleInput
from processing.core.parameters import ParameterGeometryPredicate

pluginPath = os.path.split(os.path.dirname(__file__))[0]
WIDGET, BASE = uic.loadUiType(

This file was deleted.

@@ -73,7 +73,6 @@
from processing.gui.FixedTablePanel import FixedTablePanel
from processing.gui.ExtentSelectionPanel import ExtentSelectionPanel
from processing.gui.StringInputPanel import StringInputPanel
from processing.gui.GeometryPredicateSelectionPanel import GeometryPredicateSelectionPanel


DIALOG_STANDARD = 'standard'

0 comments on commit 322a565

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