Hello Don,
This is with regard to a query in this list on providing colors with the link layer ... there were a couple of things I needed help in figuring out ... this long mail is a fallout of that ... !
>that is, it takes a csv file to organize to a shape >file. Specifying the shape file, and the
>csv file, can take place on the server side. You >could also have the properties on how you want the >areas colored simply read in on the server side.
Woud this be similar to what the AreaHandler does for AreaShapeLayer ... , viz. From what I could understand of the AreaHandler ... upon initialising, it seems to be reading the csvfile (using CSVShapeInfoFile) records and storing the tokens ( ID ) for the areas property (for which the special attributes are being set) onto a vector (areaItems).
At the same time the AreaHandler seems to use a DrawingAttributes object to load the specialised attributes for each ID onto a HashTable ( drawingParams ), the key being the the ID for the area and the AreaDrawParams object as the value for that key.
The getGraphics method in AreaHandler reads in records from the shapefile and for each record creates a new Vector with the fields in that record - ( Vector info = infoFile.getRecord(recordNumber-1); ) . A keyIndex obtained earlier would then be used to extract from this vector the ID for the area.
This ID would then be used to fetch the corresponding AreaDrawParams object ( value ) from the hashtable. This AreaDrawParams object would then be added to the OMGraphicsList for that record and the record number is saved in setAppObj() ...
Would these deductions be accurate as far as the AreaHandler goes ... ?!
Coming back to the LinkLayer or rather the ShapeLinkServer, could the same mechanism be used to read the file? If so, how would the Properties be set afterwards. For when you say - have the server read in the properties does it mean read from a local properties file or from the link ? Either way, the writeLinkGraphics method of ESRILinkRecord writes the record to the LinkGraphicList param it receives ... would preceding this step with "esrilinkrec.addOMGraphics(recList, drawParams.drawingAttributes); " as in the AreaHandler do the trick with the ShapeLinkServer too ... and can the DrawingAttribute and AreaDrawParams objects be used like this by the ShapeLinkServer.
ShapeLinkServer seems to be reading in properties from the link based on the LinkPropertiesConstants, if the interpretation of reading from the link is right, would it be possible to read in other specialized attributes also from the link and set these in the LinkGraphicsList ? Would new link property constants need to be defined to support this ... ?
Regards,
Pradeep.
Get 250 color business cards for FREE!
http://businesscards.lycos.com/vp/fastpath/
-- [To unsubscribe to this list send an email to "majdart@bbn.com" with the following text in the BODY of the message "unsubscribe openmap-users"]Received on Wed May 23 09:54:30 2001
This archive was generated by hypermail 2.1.8 : Thu May 12 2005 - 07:18:31 EDT