Thanks for your reply.
Yeah I am required to write a custom application. below I am sharing small
piece of code regarding shape file loading as mentioned below:
public static final String[] SHAPEFILES = new String[] { "","","" };
main(){
//getting LayerViewPanel for custom view
final LayerViewPanel view = new LayerViewPanel(new
LayerManager(),
new
LayerViewPanelContext() {
...
...
}
});
// Read shape files
ShapefileReader reader = new ShapefileReader();
//get the feature
List<FeatureCollection> featureList = new LinkedList<FeatureCollection>();
for (int i = 0; i < SHAPEFILES.length; i++) {
FeatureCollection features = reader.read(new
DriverProperties(
SHAPEFILES[i]));
//add features into features list
featureList.add(features);
}
//add layers
for (FeatureCollection features : featureList) {
layer =
view.getLayerManager().addLayer("Category Name",
"Layer Name", features);
}
// Initialize window
JFrame frame = new JFrame("Jump Test");
frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
frame.setSize(new Dimension(600, 600));
frame.add(view, BorderLayout.CENTER);
frame.pack();
frame.setVisible(true);
view.getViewport().zoomToFullExtent();
}
so here I can load shp file into my custom view.
Now I required to add those layers into another panel like as tree & after
changing in layer tree (e.g. check/uncheck) same should reflect into my custom
view. Please give me some hints.
Thanks
Sankar
DISCLAIMER:
-----------------------------------------------------------------------------------------------------------------------
The contents of this e-mail and any attachment(s) are confidential and intended
for the named recipient(s) only.
It shall not attach any liability on the originator or HCL or its affiliates.
Any views or opinions presented in
this email are solely those of the author and may not necessarily reflect the
opinions of HCL or its affiliates.
Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of
this message without the prior written consent of the author of this e-mail is
strictly prohibited. If you have
received this email in error please delete it and notify the sender
immediately. Before opening any mail and
attachments please check them for viruses and defect.
-----------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel