Title: Automatic Generation of WebBased GISDatabase Applications
1Automatic Generation of Web-Based GIS/Database
Applications
- Nirut Chalainanont
- Junya Sano
- Toshimi Minoura
- Department of Computer Science
- Oregon State University
- Corvallis, Oregon, 97331-4602
- minoura_at_cs.orst.edu
2Outline
- Web-based GIS/database applications
- WebGD Framework
- Automatic generation of Web-form scripts
- Automatic generation of map-layer configuration
files - Conclusions
3Enterprise Resource Management
- Enterprise resource management involves
- Inventory management
- Project management
- Issue tracking
- Personnel management
- Accounting
- Client Relationship Management
4Resource Management Applications with
Location-Based Data
- Transportation
- Water/Sewage
- Electricity
- Gas/Oil
- Freight
- Environmental Resource Management
5Location-Based Datain Resource Management
Applications
- Project sites
- Facility locations
- Points
- Networks
- Polygons
- Incident sites
6WebGD Capabilities
- Geographical features can be inserted, queried,
and deleted from a map interface. - A map interface and Web-forms can be
automatically generated. - Dynamic switching of spatial references is
supported.
7WebGD Capabilities (contd)
- GIS data in an area selected by the user can be
exported as a shapefile. - A treeview can be automatically created.
- A PDF file containing the map image and data
retrieved from the database can be created. - Photo images can be uploaded.
8Natural Heritage Information System
9Search and Automatic Zoom In to a Selected
feature
10Inserting a Property
11Treeview
12PDF File Generation
13Uploading Photo Images
14Components in a Water Distribution Network
- Water mains
- Pumps
- Lateral lines
- Hydrants
- Valves
- Meters
- Storage Units
- etc.
15Water Line Network Zoomed-Out View
16Water Line Network Zoomed-In View
17Database Schema for a Water Distribution Resource
Management System
18WebGD Architecture
PHP scripts create the map object and access the
database.
Web Browser
Defines PHP classes for GIS objects.
PHP
Web Server
PHP/MapScript
Provides functions to manage geospatial data
MapServer
PostGIS
Generates map images.
PostgreSQLDatabase
Stores geospatial and business data.
19PostgreSQL
- The object-relational feature of PostgreSQL
simplifies manipulation of geographical objects
select gid from sites where geom_col
setSRID(BOX2D(10 20, 80 90)box2d,
6010)) select X(geom_col), Y(geom_col) from
sites where gid 100
20Dynamic Switching of Spatial References
- World ?Longitude/Latitude
- North America ? Albers Equal Area
- California ?UTM 10 and 11
- Oregon ? Lambert Conformal Conic
21World in Longitude/Latitude
22North America in Albers Equal Area
23Continental United States in Albers Equal Area
24Oregon in Lambert Conformal Conic
25WebGD Framework
- A collection of scripts common to all WebGD
applications - Customizable with configuration files
- Sever-side scripts written in PHP
- Client-side scripts written in JavaScript
- Some AJAX (Asynchronous JavaScript and XML)
scripts.
26Region Configuration
- Map projection
- Unit distance of measurement
- Name of the map file for the region
- Name of the map layer configuration file
- Name of quick view configuration file
27Region Configuration
28Map Layer Configuration
- The following information is kept for each legend
entry - Spatial reference ID
- Geometry type
- Icon and label for the layer
- Database table associated with the layer
- Actions associated with the layer
29Map Layer Configuration
30Quick View Configuration
- The quick view mechanism allows the user
- to go to a predefined area directly
- Spatial reference for each area
- Extent of each area
- Name of each area
31Quick View Configuration
32WegGD Application Generator
- WebGD-Gen automatically generates a consistent
set of Web scripts from configuration files,
including those for a map interface. - Configuration files are again automatically
generated from a relational database schema. - The cost of application development is greatly
reduced.
33Process of Configuration File Generation
meta meta configuration file for table xxx
meta configuration file for table xxx
configuration file for table xxx
34Process of Web Script Generation
configuration file for table xxx
35WebGen Configuration File
- search_fields for the search script.
- search_fields, select_fields and
search_join_tables for the select script - edit_fields for the edit script
- info_blocks for information script
36Search Form
Client
Server
1) Search request
2) Search Form
Search Form
3) Search parameters
5) Checked search parameters
4) Errors
37Select Form
Client
Server
Select Form
5) Checked search parameters
8) Search Results
6) Query
Select
Script
7) Retrieved records
9) Update Record
Edit Script
10) Insert a new Record
Info Script
11) Show Record
Action Script
13) Delete query
12) IDs for delete
38Edit Form
Server
Client
Select Form
12) Insert/Edit
Edit
Script
13) Insert/Edit
14) Insert/Update/Delete
Edit Form
16) Insert/Update/Delete
Action
15) Error
Script
39Linked Forms
Department Select Form
Department Search Form
Selected ID
Student Edit Form
Department Edit Form
Course Select Form
40search_fields
- search_fieldsarray(
- array("column"gt"student_id",
- "label"gt"Student ID",
- "type"gt"numeric",
- "maxlen"gt"40",
- "size"gt"40"),
-
- array("column"gt"first_name",
- "label"gt"First Name",
- "type"gt"text",
- "maxlen"gt"40",
- "size"gt"40"),
- . . .
- )
41Configuration for a Map Interface
- WebGD-Gen can generate the statements for
inserting, searching, and deleting geographical
features from the following lines in a
configuration file
web_gd MULTIPOLYGON layer_name
grp_eo_py geometry_column the_geom
gid_column gid db_table_srid 6010
42Advantages of the WebGD Approach
- Since the Web scripts for database access are
automatically generated, the database can contain
hundreds of tables. - The database can be incrementally and iteratively
designed. - The cost and time of creating an advanced
Web-based GIS/database application can be greatly
reduced.
43Conclusions
Web-based GIS/database applications have a great
potential for enterprise resource management
applications.
- Users can add geographical features and
associated data with Web browsers. - A WebGD application can be automatically
generated. - The whole world or the entire USA can be
seamlessly covered.
44Acknowledgement
- Dileep Arur
- Haris Gunadi
- Surya Halim
- Hong Gyu Han
- Mariko Imaeda
- Junya Sano
- Akash Sharma
- Hiroshi Tashiro
- Naroot Wanalertlak
- Paphun Wangmutitakul
- Teerawat Wuttiwat
45URL
http//yukon.een.orst.edu/index0.html