[mapserver-users] Re: Fwd: Hiding Layers in OGC Web Services ¶

tellett thomas.ellett at statkart.no
Thu Dec 16 04:05:03 EST 2010


Hi Tanya,

You have a couple of options here depending on whether you want the
individual layer metadata to be visible in the capabilities file or not. 

The first option is to assign no NAME attribute to the individual layers but
have a GROUP attribute. This would allow the individual layers to be seen in
the capabilities file, with all their associated metadata (metadata which
the group layer would not have), but they would not be queryable in an OGC
request.

Option 2 is to use the "ows_hidden_layer" "true" attribute and code. This is
slightly different in that you use this with the REQUIRES attribute to 'tie'
layers together. This has the downside that no group layer is created as
such, just a kind of 'master' layer that all other layers are tied to, so
that if the 'master' layer is requested all other layers tied to it are
automatically requested.That probably made no sense so an example:

LAYER
     NAME "master"
     .....
     .....
END

LAYER
     NAME "sublayer1"
     .......
     REQUIRES "[master]"
        METADATA
             "ows_hidden_layer" "true"
        END
END

LAYER
     NAME "sublayer2"
     .....
     REQUIRES "[master]"
        METADATA
             "ows_hidden_layer" "true"
        END
END


In this example, "sublayer1" and "sublayer2" will not be seen in a
capabilities file and cannot be queried. However, they are 'tied' to the
"master" layer so that if this layer is requested, "sublayer1" and
"sublayer2" are also requested.

Hope this might help a bit!!

To be honest we're not that happy with the options available for hiding
layers and the control over nested layers, especially as the current options
don't fulfill our needs over here in Europe with regards the INSPIRE
specifications. So we've written an RFC if you're interested with regards
container layers that would give you a lot more control over layer
behaviour, we're still hoping someone is interested enough to make the, not
insignificant, coding changes!

http://osgeo-org.1803224.n2.nabble.com/INSPIRE-compliancy-A-request-for-comments-on-a-possible-RFC-td5661761.html#a5661761
'

http://trac.osgeo.org/mapserver/ticket/3608 

Cheers

Tom

-- 
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Fwd-Hiding-Layers-in-OGC-Web-Services-tp5840585p5841309.html
Sent from the Mapserver - User mailing list archive at Nabble.com.


More information about the mapserver-users mailing list