Skip to content
Permalink
Browse files

Merge pull request #3102 from rldhont/bugfix_processing_rscript_crs

[BUGFIX][Processing][Rscript] Use CRS Parameter
  • Loading branch information
volaya committed May 25, 2016
2 parents 94d88e6 + f470c53 commit 1cddf8db0061d77eb3c6a7df8d57d1ff330670bf
Showing with 5 additions and 0 deletions.
  1. +5 −0 python/plugins/processing/algs/r/RAlgorithm.py
@@ -43,6 +43,7 @@
from processing.core.parameters import ParameterSelection
from processing.core.parameters import ParameterTableField
from processing.core.parameters import ParameterExtent
from processing.core.parameters import ParameterCrs
from processing.core.parameters import ParameterFile
from processing.core.parameters import ParameterPoint
from processing.core.outputs import OutputTable
@@ -200,6 +201,8 @@ def processParameterLine(self, line):
param = ParameterTableField(tokens[0], tokens[0], field)
elif tokens[1].lower().strip() == 'extent':
param = ParameterExtent(tokens[0], desc)
elif tokens[1].lower().strip() == 'crs':
param = ParameterCrs(tokens[0], desc)
elif tokens[1].lower().strip() == 'point':
param = ParameterPoint(tokens[0], desc)
elif tokens[1].lower().strip() == 'file':
@@ -350,6 +353,8 @@ def getImportCommands(self):
commands.append(param.name + ' = extent(' + tokens[0] + ',' + tokens[2] + ',' + tokens[1] + ',' + tokens[3] + ')')
else:
commands.append(param.name + ' = NULL')
elif isinstance(param, ParameterCrs):
commands.append(param.name + ' = "' + param.value + '"')
elif isinstance(param, (ParameterTableField, ParameterString,
ParameterFile)):
commands.append(param.name + '="' + param.value + '"')

0 comments on commit 1cddf8d

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