reading and deleting annotation features in mapscript

mikiet mike.talbutt at DOTTEDEYES.COM
Thu Aug 31 09:11:34 PDT 2006


Thanks for that, I've now successfully got my shape, however you statement
saying deleteing is not supported, does this mean that there is no way of
removing a feature from a layer ?


Umberto Nicoletti wrote:
> 
> On 8/31/06, Mike Talbutt <mike.talbutt at dottedeyes.com> wrote:
>>
>>
>> Hi all,
>>
>> A quick question from a mapserver newbie
>>
>> Using java mapscript I am creating annonations on a new map layer by
>> creating polygon features in a new layer,
>>
>> when I do a query on that layer to retreive the features I have created I
>> am
>> unable to get at the shape objects as the following line of code fails
>>
>> shapeObj shape2 = m_Layer.getFeature(resultMember.getShapeindex(),
>> resultMember.getTileindex());
> 
> try:
> 
> shapeObj shape2 = m_Layer.getFeature( featIndex ,-1);
> 
> and you can use featIndex to access the list where features are stored
> like you would if you were accessing an array.
> I don't think you even need to query the layer, just use getFeature().
> Inline layers do not need to opened.
> 
>>
>> , I noticed the tile index and shape index properties in the
>> resultCacheMemberObj object are both -1. Can someone tell me how to get
>> hold
>> of the shape objects, as I need provide some sort of delete annotation
>> functionality, and I dont want to simply drop the entire layer
>>
> 
> As of deleting that is not supported.
> 
> Umberto
> 
>> Email has been scanned for viruses and spam by Altman Technologies' email
>> management service
> 
> 

-- 
View this message in context: http://www.nabble.com/reading-and-deleting-annotation-features-in-mapscript-tf2197247.html#a6082722
Sent from the Mapserver - User forum at Nabble.com.



More information about the MapServer-users mailing list