Package madrona :: Package staticmap :: Module models :: Class MapConfig
[hide private]

Class MapConfig

source code

django.contrib.gis.db.models.Model --+
                                     |
                                    MapConfig

Model used for representing a map (ie a collection of styled map layers)

======================  ==============================================
Attribute               Description
======================  ==============================================

``mapname``             Name of the map. Will be refered to by URL so 
                        use http friendly names (no spaces, slashes, etc)

``mapfile``             Mapnik xml configuration file that defines data 
                        sources and styles. All paths within xml must be 
                        relative to media/staticmap/

``default_x1``          LL X coordinate

``default_y1``          LL Y coordinate

``default_x2``          UR X coordinate

``default_y2``          UR Y coordinate

``default_width``       Default image width (pixels)

``default_height``      Default image height (pixels)
======================  ==============================================

Instance Methods [hide private]
 
__unicode__(self) source code
Class Variables [hide private]
  mapname = models.CharField(max_length= 50, unique= True)
  mapfile = models.FileField(upload_to= 'staticmap/', help_text=...
  default_x1 = models.FloatField(help_text= "Lower-left X coordi...
  default_y1 = models.FloatField(help_text= "Lower-left Y coordi...
  default_x2 = models.FloatField(help_text= "Upper-right X coord...
  default_y2 = models.FloatField(help_text= "Upper-right Y coord...
  default_width = models.IntegerField(help_text= "Default map im...
  default_height = models.IntegerField(help_text= "Default map i...
  default_srid = models.IntegerField(help_text= "Spatial Referen...
Class Variable Details [hide private]

mapfile

Value:
models.FileField(upload_to= 'staticmap/', help_text= """
        Mapnik xml configuration file that defines data sources and st\
yles. 
        All paths within xml must be relative to media/staticmap/
    """, blank= False, max_length= 510)

default_x1

Value:
models.FloatField(help_text= "Lower-left X coordinate of default map e\
xtent. Units and spatial reference system are defined in the mapnik xm\
l.")

default_y1

Value:
models.FloatField(help_text= "Lower-left Y coordinate of default map e\
xtent. Units and spatial reference system are defined in the mapnik xm\
l.")

default_x2

Value:
models.FloatField(help_text= "Upper-right X coordinate of default map \
extent. Units and spatial reference system are defined in the mapnik x\
ml.")

default_y2

Value:
models.FloatField(help_text= "Upper-right Y coordinate of default map \
extent. Units and spatial reference system are defined in the mapnik x\
ml.")

default_width

Value:
models.IntegerField(help_text= "Default map image width in pixels")

default_height

Value:
models.IntegerField(help_text= "Default map image height in pixels")

default_srid

Value:
models.IntegerField(help_text= "Spatial Reference ID of the output map\
", default= 4326)