[Geoprisma-dev] config.xml ideas : automatism

Stephen Woodbridge woodbri at swoodbridge.com
Thu Dec 17 12:01:23 EST 2009


Alexandre,

I'm all for more simplicity, but that said I'm a newbie and as if figure 
things out I'm a little worried about what flexibility I would be 
loosing. So some discussion of what we would loose might be helpful.

Overall, it is my newbie opinion that there appears to be a lot of 
duplication. I would like to describe more datastore or resource once 
probably in more detail and then only reference it by name elsewhere.

Having a datastore with 10 layers that might be used for either WMS or 
WFS via featureserver should only require me to define it all in detail 
in one place. Then things like featurepanel_form and layertree, etc 
should look at that and configure themselves based on the information 
available.

For example, I find doing a querybyclick and a featurepanel_form to be 
extremely redundant. These should be the same widget for display and one 
supports updates. This way people expect to see data presented on a 
common way.

Anyway, my two cents as someone very new to the project as a user.

-Steve

Alexandre Dube wrote:
> Hey,
> 
>  I need opinions.
> 
>  Here's an example use case.  Currently, in the config.xml, when you 
> want to add edition on a Resource (for example) you need to :
> 
>  - setup a DS with <fields>
>  - setup an editfeature widget
>  - setup an featurepanel widget
>  - setup a layer node in the map object with needed options
>  - be sure that you think to set a min/max Scale or Resolution so that 
> your vector layer is not always visible
>  - also set it in the tree
>  - set some styling
>  - etc.
> 
>  What really pisses me off is to have to think to all that.  For that, 
> I'd propose to *automatize* as much stuff as possible.  The main 
> downside : less customization possible.
> 
>  My first idea is to  automatize the layer creation.  No more <layer> 
> node needed is my main objective.  The resources defined with their 
> datastore have to be enough.  For that, a couple options / behavior 
> would be needed :
> 
>  - Vector layers are *only* added if a widget use it.  No options.  This 
> is the only behavior.
> 
>  - By default, only one of these type of layer is added : tilecache or 
> wms.  If set to false, all layer types are added.
>      <singleLayer>true</singleLayer>
>  - By default, tilecache is added first.
>      <layerPriorities>
>        <layer>tilecache</layer>
>        <type>wms</type>
>      </layerPriorities>
>  - By default, wms layers are automatically merged if they share the 
> same service, but you can turn that option off
>      <mergeWMSLayers>true<mergeWMSLayers>
> 
>   (for the above options, no one needs to be defined.  They all have a 
> 'default' value.  If you want a different behavior, change it.)  All the 
> above options are part of the <application> node.
> 
>  - Layers are automatically added to the layertree with a single option 
> in the resource : <layerTreePath>/my/path/</layerTreePath>
> 
> 
>  Again, the price to pay is : less customization, but more simplicity to 
> use.
> 
>  That's the main thing I'm aiming and that's what I want you to tell me 
> : does this makes sense ?
> 




More information about the Geoprisma-dev mailing list