浏览代码

Add full_name method to the raster abstract class to be consistent with the Vector classes, thank you to Stefano Cavallari

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@55051 15284696-431f-4ddb-bdfa-cd5b030d7da7
Pietro Zambelli 12 年之前
父节点
当前提交
51de7d87e0
共有 1 个文件被更改,包括 5 次插入1 次删除
  1. 5 1
      lib/python/pygrass/raster/abstract.py

+ 5 - 1
lib/python/pygrass/raster/abstract.py

@@ -62,7 +62,7 @@ class Info(object):
             range: 56, 156
             proj: 99
             ...
-            
+
         """
         self.name = name
         self.mapset = mapset
@@ -335,6 +335,10 @@ class RasterAbstractBase(object):
             self.close()
         functions.remove(self.name, 'rast')
 
+    def fullname(self):
+        """Return the full name of a raster map: name@mapset"""
+        return "{name}@{mapset}".format(name=self.name, mapset=self.mapset)
+
     def name_mapset(self, name=None, mapset=None):
         """Return the full name of the Raster