Defining the ShapeEditor's applications
We now have a Django project for our overall ShapeEditor system. We next need to break down our project into applications, following Django's design philosophy of having applications be small and relatively self-contained. Looking back at our design for the overall project, we can see several possible candidates for breaking the functionality into separate applications:
Importing and exporting shapefiles
Selecting features
Editing features
The tile map server
We're going to combine the first three into a single application called shapefiles
, which will handle all the shapefile-related logic. We'll then have another application called tms
, which implements our tile map server. Finally, we'll define one more application, which we'll called shared
, to hold the database models and Python modules that are shared across these applications.
For example, we might have a module named utils.py
that is needed by both the shapefile
and tms
applications. We'll place...