Dear all,
I have two problem in geotools and geoserver implementation. I am using
shapefile at back end on top of geoserver is used to create wfs and wms. at
the front end i am using geotools. The problems are
1. i am display wms on JMapPane. if i make a transaction on wms it doesnt
update wms.even i close the application and restart it no update show on
wms. But if i see shapefile the update is there. similarly if i view wfs on
JMapPane even then the updates are visible. only wms doesnot show any
updates. The wfs is that if i show wfs on JMapPane and make any transaction
the exception arises uable delete shapefile. it seems that JMapPane lock the
wfs and doesnt allow transaction on it thats y i am display wms on JMapPane
and make transaction on wfs
2. i need to convert wgs cordinate to utm zone 43n coordinates some times it
give me correct result but sometime the result is in negative even though
the wgs coordinate are same
i m using following code
public Point2D coordinateTransform(String srcCoord, String desCoord,
Point2D srcPoint) throws NoSuchAuthorityCodeException, FactoryException,
TransformException,
MismatchedDimensionException {
CoordinateReferenceSystem srcCRS = CRS.decode(srcCoord);
CoordinateReferenceSystem desCRS =CRS.decode(desCoord);
//System.out.println(srcCRS.toWKT());
//System.out.println(desCRS.toWKT());
MathTransform mt = CRS.findMathTransform(srcCRS,desCRS);
DirectPosition srcPt = new DirectPosition2D(srcPoint);
DirectPosition2D desPt = new DirectPosition2D();
mt.transform(srcPt,desPt);
System.out.println("WGS84 X:"+srcPt.getCoordinates()[0]+"
Y:"+srcPt.getCoordinates()[1]);
System.out.println("UTM43N X:"+desPt.getCoordinates()[0]+"
Y:"+desPt.getCoordinates()[1]);
Point2D desPoint = desPt.toPoint2D();//new
DirectPosition2D(desPt).toPoint2D();
return desPoint;
}
Thanking you in anticipation
regards
Ather Ashraf
GIS Engineer
Mobile: 03224785104
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users