uDig

«  Testing Tutorial   ::   Contents   ::   Style Tutorial  »

CSV Renderer Tutorial

This is an advanced workbook showing how torender a comma separated value file.

This workbook is part of our commercial training materials.

Source code:

Introduction

This workbook brings together all your previous work in uDig with one goal - getting your data on the screen.

This workshop covers

  • Implement a Custom Renderer
  • Interacting with the uDig Rendering Workflow

If you would like to create your own styles please review the styleContent extension point. There are also extension points for making StyleConfigurator (user interfaces that are used to modify the style blackboard).

What to Do Next

For better understanding of these facilities please try the following:

ProgressMonitor

The CSV.getSize() method provides a count of the total number of records. Use this information to provide accurate information to the ProgressMonitor (rather than UNKNOWN).

Sidecar File

You will find that several file formats make use of a ”.prj” file (containing Well-Known-Text). Can you create a “cities.prj” file and modify the CSV class to pick it up.

Hint: There is code in geotools to read a PRJ file.

Generate CSV file

Advanced: Can you create an operation to export shapefile as a CSV file? Remember to add the CSV file to the catalog after it is created.

Style

Advanced: Some StyleContents are already available - such as Font. Can you make your Renderer check the style blackboard for the current Font?

Hint: You will need to change CSVGeoResource to resolve to a Font (it will be used as the default value).

Tips, Tricks and Suggestions

The following tips have been provided by the udig-devel list; please stop by and introduce yourself.

Commercial Training Materials

Please contact any of the organisations listed on the main uDig support page for details on uDig training.

The workbooks and slides for the training course are available here:

This is a private svn repository that is open to those who have taken the training course.

Academic Access

The course materials can be made available to those working at academic institutions - we ask for an email from your Professor.

Please ask your professor to email admin@refractions.net with the request.

«  Testing Tutorial   ::   Contents   ::   Style Tutorial  »