Skip to content

Commit

Permalink
[processing] add group id to GDAL algorithms
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbruy committed Dec 14, 2017
1 parent 5e157c9 commit 53bc147
Show file tree
Hide file tree
Showing 51 changed files with 153 additions and 0 deletions.
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/AssignProjection.py
Expand Up @@ -70,6 +70,9 @@ def icon(self):
def group(self):
return self.tr('Raster projections')

def group(self):
return 'rasterprojections'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
fileName = inLayer.source()
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/Buffer.py
Expand Up @@ -95,6 +95,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ClipRasterByExtent.py
Expand Up @@ -99,6 +99,9 @@ def displayName(self):
def group(self):
return self.tr('Raster extraction')

def groupId(self):
return 'rasterextraction'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'raster-clip.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ClipRasterByMask.py
Expand Up @@ -116,6 +116,9 @@ def icon(self):
def group(self):
return self.tr('Raster extraction')

def groupId(self):
return 'rasterextraction'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ClipVectorByExtent.py
Expand Up @@ -71,6 +71,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ClipVectorByMask.py
Expand Up @@ -70,6 +70,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ColorRelief.py
Expand Up @@ -92,6 +92,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = ['color-relief']
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/Dissolve.py
Expand Up @@ -106,6 +106,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ExecuteSql.py
Expand Up @@ -82,6 +82,9 @@ def displayName(self):
def group(self):
return self.tr('Vector miscellaneous')

def groupId(self):
return 'vectormiscellaneous'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
ogrLayer, layerName = self.getOgrCompatibleSource(self.INPUT, parameters, context, feedback, executing)
sql = self.parameterAsString(parameters, self.SQL, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/GridAverage.py
Expand Up @@ -132,6 +132,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'grid.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/GridDataMetrics.py
Expand Up @@ -149,6 +149,9 @@ def icon(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
ogrLayer, layerName = self.getOgrCompatibleSource(self.INPUT, parameters, context, feedback, executing)

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/GridInverseDistance.py
Expand Up @@ -152,6 +152,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'grid.png'))

Expand Down
Expand Up @@ -139,6 +139,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'grid.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/GridLinear.py
Expand Up @@ -114,6 +114,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'grid.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/GridNearestNeighbor.py
Expand Up @@ -127,6 +127,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'grid.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/OffsetCurve.py
Expand Up @@ -78,6 +78,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/OgrToPostGis.py
Expand Up @@ -162,6 +162,9 @@ def displayName(self):
def group(self):
return self.tr('Vector miscellaneous')

def groupId(self):
return 'vectormiscellaneous'

def getConnectionString(self, parameters, context):
host = self.parameterAsString(parameters, self.HOST, context)
port = self.parameterAsString(parameters, self.PORT, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/OneSideBuffer.py
Expand Up @@ -104,6 +104,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/PointsAlongLines.py
Expand Up @@ -83,6 +83,9 @@ def displayName(self):
def group(self):
return self.tr('Vector geoprocessing')

def groupId(self):
return 'vectorgeoprocessing'

def commandName(self):
return 'ogr2ogr'

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/aspect.py
Expand Up @@ -93,6 +93,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = ['aspect']
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/buildvrt.py
Expand Up @@ -100,6 +100,9 @@ def icon(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = []
arguments.append('-resolution')
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/contour.py
Expand Up @@ -118,6 +118,9 @@ def icon(self):
def group(self):
return self.tr('Raster extraction')

def groupId(self):
return 'rasterextraction'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
fieldName = self.parameterAsString(parameters, self.FIELD_NAME, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/extractprojection.py
Expand Up @@ -63,6 +63,9 @@ def icon(self):
def group(self):
return self.tr('Raster projections')

def groupId(self):
return 'rasterprojections'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
return ["extractprojection"]

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/fillnodata.py
Expand Up @@ -86,6 +86,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = []
arguments.append('-md')
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdal2tiles.py
Expand Up @@ -153,6 +153,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = []

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdal2xyz.py
Expand Up @@ -69,6 +69,9 @@ def displayName(self):
def group(self):
return self.tr('Raster conversion')

def groupId(self):
return 'rasterconversion'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = []
arguments = []
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdaladdo.py
Expand Up @@ -99,6 +99,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'raster-overview.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdalcalc.py
Expand Up @@ -102,6 +102,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
out = self.getOutputValue(self.OUTPUT)
extra = self.getParameterValue(self.EXTRA)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdalinfo.py
Expand Up @@ -80,6 +80,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'raster-info.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/gdaltindex.py
Expand Up @@ -111,6 +111,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'tiles.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/hillshade.py
Expand Up @@ -120,6 +120,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def getConsoleCommands(self, parameters, context, feedback, executing=True):
arguments = ['hillshade']
inLayer = self.parameterAsRasterLayer(parameters, self.INPUT, context)
Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/merge.py
Expand Up @@ -98,6 +98,9 @@ def displayName(self):
def group(self):
return self.tr('Raster miscellaneous')

def groupId(self):
return 'rastermiscellaneous'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'merge.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/nearblack.py
Expand Up @@ -86,6 +86,9 @@ def displayName(self):
def group(self):
return self.tr('Raster analysis')

def groupId(self):
return 'rasteranalysis'

def icon(self):
return QIcon(os.path.join(pluginPath, 'images', 'gdaltools', 'nearblack.png'))

Expand Down
3 changes: 3 additions & 0 deletions python/plugins/processing/algs/gdal/ogr2ogr.py
Expand Up @@ -68,6 +68,9 @@ def displayName(self):
def group(self):
return self.tr('Vector conversion')

def groupId(self):
return 'vectorconversion'

def commandName(self):