Coverage details for edu.umn.gis.mapscript.imp.mapObj

LineHitsSource
1 // A Java MapScript module for MapServer.
2 // See <http://mapserver.gis.umn.edu> for information on MapServer.
3 //
4 // Copyright (C) 2003 Andrew Collins <andrewrcollins@yahoo.com>
5 //
6 // This library is free software; you can redistribute it
7 // and/or modify it under the terms of the GNU Lesser General
8 // Public License as published by the Free Software Foundation;
9 // either version 2.1 of the License, or (at your option) any
10 // later version.
11 //
12 // This library is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty
14 // of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15 // See the GNU Lesser General Public License for more details.
16 //
17 // You should have received a copy of the GNU Lesser General
18 // Public License along with this library; if not, write to
19 // the Free Software Foundation, Inc., 59 Temple Place,
20 // Suite 330, Boston, MA 02111-1307 USA
21 package edu.umn.gis.mapscript.imp;
22  
23 /**
24  * DOCUMENT ME!
25  *
26  * @author <a href="mailto:ADDRESS">NAME</a>
27  *
28  * @todo CLASS_DESCRIPTION
29  */
30 public class mapObj
31 {
32   /**
33    * DOCUMENT ME!
34    *
35    * @todo FIELD_DESCRIPTION
36    */
37   protected boolean swigCMemOwn;
38  
39   /**
40    * DOCUMENT ME!
41    *
42    * @todo FIELD_DESCRIPTION
43    */
44   private long swigCPtr;
45  
46   /**
47    * Creates a new mapObj object.
48    *
49    * @param filename PARAMETER
50    */
51   public mapObj(String filename)
52   {
530    this(MapScriptJNI.new_mapObj(filename), true);
540  }
55  
56   /**
57    * Creates a new mapObj object.
58    *
59    * @param cPtr PARAMETER
60    * @param cMemoryOwn PARAMETER
61    */
62   protected mapObj(long cPtr, boolean cMemoryOwn)
630  {
640    swigCMemOwn = cMemoryOwn;
650    swigCPtr = cPtr;
660  }
67  
68   /**
69    * Creates a new mapObj object.
70    */
71   protected mapObj()
72   {
730    this(0, false);
740  }
75  
76   /**
77    * DOCUMENT ME!
78    *
79    * @param cellsize PARAMETER
80    *
81    * @todo METHOD_DESCRIPTION
82    */
83   public void setCellsize(double cellsize)
84   {
850    MapScriptJNI.set_mapObj_cellsize(swigCPtr, cellsize);
860  }
87  
88   /**
89    * DOCUMENT ME!
90    *
91    * @return RETURN
92    *
93    * @todo METHOD_DESCRIPTION
94    */
95   public double getCellsize()
96   {
970    return MapScriptJNI.get_mapObj_cellsize(swigCPtr);
98   }
99  
100   /**
101    * DOCUMENT ME!
102    *
103    * @param extent PARAMETER
104    *
105    * @todo METHOD_DESCRIPTION
106    */
107   public void setExtent(rectObj extent)
108   {
1090    MapScriptJNI.set_mapObj_extent(swigCPtr, rectObj.getCPtr(extent));
1100  }
111  
112   /**
113    * DOCUMENT ME!
114    *
115    * @return RETURN
116    *
117    * @todo METHOD_DESCRIPTION
118    */
119   public rectObj getExtent()
120   {
1210    return new rectObj(MapScriptJNI.get_mapObj_extent(swigCPtr), false);
122   }
123  
124   /**
125    * DOCUMENT ME!
126    *
127    * @param szFileName PARAMETER
128    *
129    * @return RETURN
130    *
131    * @todo METHOD_DESCRIPTION
132    */
133   public int setFontSet(String szFileName)
134   {
1350    return MapScriptJNI.mapObj_setFontSet(swigCPtr, szFileName);
136   }
137  
138   /**
139    * DOCUMENT ME!
140    *
141    * @param height PARAMETER
142    *
143    * @todo METHOD_DESCRIPTION
144    */
145   public void setHeight(int height)
146   {
1470    MapScriptJNI.set_mapObj_height(swigCPtr, height);
1480  }
149  
150   /**
151    * DOCUMENT ME!
152    *
153    * @return RETURN
154    *
155    * @todo METHOD_DESCRIPTION
156    */
157   public int getHeight()
158   {
1590    return MapScriptJNI.get_mapObj_height(swigCPtr);
160   }
161  
162   /**
163    * DOCUMENT ME!
164    *
165    * @param image PARAMETER
166    * @param varname PARAMETER
167    *
168    * @return RETURN
169    *
170    * @todo METHOD_DESCRIPTION
171    */
172   public int getImageToVar(imageObj image, String varname)
173   {
1740    return MapScriptJNI.mapObj_getImageToVar(swigCPtr, imageObj.getCPtr(image),
175       varname);
176   }
177  
178   /**
179    * DOCUMENT ME!
180    *
181    * @param imagecolor PARAMETER
182    *
183    * @todo METHOD_DESCRIPTION
184    */
185   public void setImagecolor(colorObj imagecolor)
186   {
1870    MapScriptJNI.set_mapObj_imagecolor(swigCPtr, colorObj.getCPtr(imagecolor));
1880  }
189  
190   /**
191    * DOCUMENT ME!
192    *
193    * @return RETURN
194    *
195    * @todo METHOD_DESCRIPTION
196    */
197   public colorObj getImagecolor()
198   {
1990    return new colorObj(MapScriptJNI.get_mapObj_imagecolor(swigCPtr), false);
200   }
201  
202   /**
203    * DOCUMENT ME!
204    *
205    * @param imagequality PARAMETER
206    *
207    * @todo METHOD_DESCRIPTION
208    */
209   public void setImagequality(int imagequality)
210   {
2110    MapScriptJNI.set_mapObj_imagequality(swigCPtr, imagequality);
2120  }
213  
214   /**
215    * DOCUMENT ME!
216    *
217    * @return RETURN
218    *
219    * @todo METHOD_DESCRIPTION
220    */
221   public int getImagequality()
222   {
2230    return MapScriptJNI.get_mapObj_imagequality(swigCPtr);
224   }
225  
226   /**
227    * DOCUMENT ME!
228    *
229    * @param imagetype PARAMETER
230    *
231    * @todo METHOD_DESCRIPTION
232    */
233   public void setImagetype(int imagetype)
234   {
2350    MapScriptJNI.set_mapObj_imagetype(swigCPtr, imagetype);
2360  }
237  
238   /**
239    * DOCUMENT ME!
240    *
241    * @return RETURN
242    *
243    * @todo METHOD_DESCRIPTION
244    */
245   public int getImagetype()
246   {
2470    return MapScriptJNI.get_mapObj_imagetype(swigCPtr);
248   }
249  
250   /**
251    * DOCUMENT ME!
252    *
253    * @param interlace PARAMETER
254    *
255    * @todo METHOD_DESCRIPTION
256    */
257   public void setInterlace(int interlace)
258   {
2590    MapScriptJNI.set_mapObj_interlace(swigCPtr, interlace);
2600  }
261  
262   /**
263    * DOCUMENT ME!
264    *
265    * @return RETURN
266    *
267    * @todo METHOD_DESCRIPTION
268    */
269   public int getInterlace()
270   {
2710    return MapScriptJNI.get_mapObj_interlace(swigCPtr);
272   }
273  
274   /**
275    * DOCUMENT ME!
276    *
277    * @param labelcache PARAMETER
278    *
279    * @todo METHOD_DESCRIPTION
280    */
281   public void setLabelcache(labelCacheObj labelcache)
282   {
2830    MapScriptJNI.set_mapObj_labelcache(swigCPtr,
284       labelCacheObj.getCPtr(labelcache));
2850  }
286  
287   /**
288    * DOCUMENT ME!
289    *
290    * @return RETURN
291    *
292    * @todo METHOD_DESCRIPTION
293    */
294   public labelCacheObj getLabelcache()
295   {
2960    return new labelCacheObj(MapScriptJNI.get_mapObj_labelcache(swigCPtr), false);
297   }
298  
299   /**
300    * DOCUMENT ME!
301    *
302    * @param i PARAMETER
303    *
304    * @return RETURN
305    *
306    * @todo METHOD_DESCRIPTION
307    */
308   public layerObj getLayer(int i)
309   {
3100    return new layerObj(MapScriptJNI.mapObj_getLayer(swigCPtr, i), false);
311   }
312  
313   /**
314    * DOCUMENT ME!
315    *
316    * @param name PARAMETER
317    *
318    * @return RETURN
319    *
320    * @todo METHOD_DESCRIPTION
321    */
322   public layerObj getLayerByName(String name)
323   {
3240    return new layerObj(MapScriptJNI.mapObj_getLayerByName(swigCPtr, name),
325       false);
326   }
327  
328   /**
329    * DOCUMENT ME!
330    *
331    * @param layerorder PARAMETER
332    *
333    * @todo METHOD_DESCRIPTION
334    */
335   public void setLayerorder(SWIGTYPE_p_int layerorder)
336   {
3370    MapScriptJNI.set_mapObj_layerorder(swigCPtr,
338       SWIGTYPE_p_int.getCPtr(layerorder));
3390  }
340  
341   /**
342    * DOCUMENT ME!
343    *
344    * @return RETURN
345    *
346    * @todo METHOD_DESCRIPTION
347    */
348   public SWIGTYPE_p_int getLayerorder()
349   {
3500    return new SWIGTYPE_p_int(MapScriptJNI.get_mapObj_layerorder(swigCPtr),
351       false);
352   }
353  
354   /**
355    * DOCUMENT ME!
356    *
357    * @param layers PARAMETER
358    *
359    * @todo METHOD_DESCRIPTION
360    */
361   public void setLayers(layerObj layers)
362   {
3630    MapScriptJNI.set_mapObj_layers(swigCPtr, layerObj.getCPtr(layers));
3640  }
365  
366   /**
367    * DOCUMENT ME!
368    *
369    * @return RETURN
370    *
371    * @todo METHOD_DESCRIPTION
372    */
373   public layerObj getLayers()
374   {
3750    return new layerObj(MapScriptJNI.get_mapObj_layers(swigCPtr), false);
376   }
377  
378   /**
379    * DOCUMENT ME!
380    *
381    * @param panIndexes PARAMETER
382    *
383    * @return RETURN
384    *
385    * @todo METHOD_DESCRIPTION
386    */
387   public int setLayersdrawingOrder(SWIGTYPE_p_int panIndexes)
388   {
3890    return MapScriptJNI.mapObj_setLayersdrawingOrder(swigCPtr,
390       SWIGTYPE_p_int.getCPtr(panIndexes));
391   }
392  
393   /**
394    * DOCUMENT ME!
395    *
396    * @return RETURN
397    *
398    * @todo METHOD_DESCRIPTION
399    */
400   public SWIGTYPE_p_int getLayersdrawingOrder()
401   {
4020    return new SWIGTYPE_p_int(MapScriptJNI.mapObj_getLayersdrawingOrder(
403         swigCPtr), false);
404   }
405  
406   /**
407    * DOCUMENT ME!
408    *
409    * @param legend PARAMETER
410    *
411    * @todo METHOD_DESCRIPTION
412    */
413   public void setLegend(legendObj legend)
414   {
4150    MapScriptJNI.set_mapObj_legend(swigCPtr, legendObj.getCPtr(legend));
4160  }
417  
418   /**
419    * DOCUMENT ME!
420    *
421    * @return RETURN
422    *
423    * @todo METHOD_DESCRIPTION
424    */
425   public legendObj getLegend()
426   {
4270    return new legendObj(MapScriptJNI.get_mapObj_legend(swigCPtr), false);
428   }
429  
430   /**
431    * DOCUMENT ME!
432    *
433    * @param name PARAMETER
434    * @param value PARAMETER
435    *
436    * @return RETURN
437    *
438    * @todo METHOD_DESCRIPTION
439    */
440   public int setMetaData(String name, String value)
441   {
4420    return MapScriptJNI.mapObj_setMetaData(swigCPtr, name, value);
443   }
444  
445   /**
446    * DOCUMENT ME!
447    *
448    * @param name PARAMETER
449    *
450    * @return RETURN
451    *
452    * @todo METHOD_DESCRIPTION
453    */
454   public String getMetaData(String name)
455   {
4560    return MapScriptJNI.mapObj_getMetaData(swigCPtr, name);
457   }
458  
459   /**
460    * DOCUMENT ME!
461    *
462    * @param name PARAMETER
463    *
464    * @todo METHOD_DESCRIPTION
465    */
466   public void setName(String name)
467   {
4680    MapScriptJNI.set_mapObj_name(swigCPtr, name);
4690  }
470  
471   /**
472    * DOCUMENT ME!
473    *
474    * @return RETURN
475    *
476    * @todo METHOD_DESCRIPTION
477    */
478   public String getName()
479   {
4800    return MapScriptJNI.get_mapObj_name(swigCPtr);
481   }
482  
483   /**
484    * DOCUMENT ME!
485    *
486    * @return RETURN
487    *
488    * @todo METHOD_DESCRIPTION
489    */
490   public int getNumlayers()
491   {
4920    return MapScriptJNI.get_mapObj_numlayers(swigCPtr);
493   }
494  
495   /**
496    * DOCUMENT ME!
497    *
498    * @param palette PARAMETER
499    *
500    * @todo METHOD_DESCRIPTION
501    */
502   public void setPalette(SWIGTYPE_p_paletteObj palette)
503   {
5040    MapScriptJNI.set_mapObj_palette(swigCPtr,
505       SWIGTYPE_p_paletteObj.getCPtr(palette));
5060  }
507  
508   /**
509    * DOCUMENT ME!
510    *
511    * @return RETURN
512    *
513    * @todo METHOD_DESCRIPTION
514    */
515   public SWIGTYPE_p_paletteObj getPalette()
516   {
5170    return new SWIGTYPE_p_paletteObj(MapScriptJNI.get_mapObj_palette(swigCPtr),
518       true);
519   }
520  
521   /**
522    * DOCUMENT ME!
523    *
524    * @param string PARAMETER
525    *
526    * @return RETURN
527    *
528    * @todo METHOD_DESCRIPTION
529    */
530   public int setProjection(String string)
531   {
5320    return MapScriptJNI.mapObj_setProjection(swigCPtr, string);
533   }
534  
535   /**
536    * DOCUMENT ME!
537    *
538    * @return RETURN
539    *
540    * @todo METHOD_DESCRIPTION
541    */
542   public String getProjection()
543   {
5440    return MapScriptJNI.mapObj_getProjection(swigCPtr);
545   }
546  
547   /**
548    * DOCUMENT ME!
549    *
550    * @param querymap PARAMETER
551    *
552    * @todo METHOD_DESCRIPTION
553    */
554   public void setQuerymap(queryMapObj querymap)
555   {
5560    MapScriptJNI.set_mapObj_querymap(swigCPtr, queryMapObj.getCPtr(querymap));
5570  }
558  
559   /**
560    * DOCUMENT ME!
561    *
562    * @return RETURN
563    *
564    * @todo METHOD_DESCRIPTION
565    */
566   public queryMapObj getQuerymap()
567   {
5680    return new queryMapObj(MapScriptJNI.get_mapObj_querymap(swigCPtr), false);
569   }
570  
571   /**
572    * DOCUMENT ME!
573    *
574    * @param reference PARAMETER
575    *
576    * @todo METHOD_DESCRIPTION
577    */
578   public void setReference(referenceMapObj reference)
579   {
5800    MapScriptJNI.set_mapObj_reference(swigCPtr,
581       referenceMapObj.getCPtr(reference));
5820  }
583  
584   /**
585    * DOCUMENT ME!
586    *
587    * @return RETURN
588    *
589    * @todo METHOD_DESCRIPTION
590    */
591   public referenceMapObj getReference()
592   {
5930    return new referenceMapObj(MapScriptJNI.get_mapObj_reference(swigCPtr),
594       false);
595   }
596  
597   /**
598    * DOCUMENT ME!
599    *
600    * @param resolution PARAMETER
601    *
602    * @todo METHOD_DESCRIPTION
603    */
604   public void setResolution(int resolution)
605   {
6060    MapScriptJNI.set_mapObj_resolution(swigCPtr, resolution);
6070  }
608  
609   /**
610    * DOCUMENT ME!
611    *
612    * @return RETURN
613    *
614    * @todo METHOD_DESCRIPTION
615    */
616   public int getResolution()
617   {
6180    return MapScriptJNI.get_mapObj_resolution(swigCPtr);
619   }
620  
621   /**
622    * DOCUMENT ME!
623    *
624    * @param scale PARAMETER
625    *
626    * @todo METHOD_DESCRIPTION
627    */
628   public void setScale(double scale)
629   {
6300    MapScriptJNI.set_mapObj_scale(swigCPtr, scale);
6310  }
632  
633   /**
634    * DOCUMENT ME!
635    *
636    * @return RETURN
637    *
638    * @todo METHOD_DESCRIPTION
639    */
640   public double getScale()
641   {
6420    return MapScriptJNI.get_mapObj_scale(swigCPtr);
643   }
644  
645   /**
646    * DOCUMENT ME!
647    *
648    * @param scalebar PARAMETER
649    *
650    * @todo METHOD_DESCRIPTION
651    */
652   public void setScalebar(scalebarObj scalebar)
653   {
6540    MapScriptJNI.set_mapObj_scalebar(swigCPtr, scalebarObj.getCPtr(scalebar));
6550  }
656  
657   /**
658    * DOCUMENT ME!
659    *
660    * @return RETURN
661    *
662    * @todo METHOD_DESCRIPTION
663    */
664   public scalebarObj getScalebar()
665   {
6660    return new scalebarObj(MapScriptJNI.get_mapObj_scalebar(swigCPtr), false);
667   }
668  
669   /**
670    * DOCUMENT ME!
671    *
672    * @param shapepath PARAMETER
673    *
674    * @todo METHOD_DESCRIPTION
675    */
676   public void setShapepath(String shapepath)
677   {
6780    MapScriptJNI.set_mapObj_shapepath(swigCPtr, shapepath);
6790  }
680  
681   /**
682    * DOCUMENT ME!
683    *
684    * @return RETURN
685    *
686    * @todo METHOD_DESCRIPTION
687    */
688   public String getShapepath()
689   {
6900    return MapScriptJNI.get_mapObj_shapepath(swigCPtr);
691   }
692  
693   /**
694    * DOCUMENT ME!
695    *
696    * @param status PARAMETER
697    *
698    * @todo METHOD_DESCRIPTION
699    */
700   public void setStatus(int status)
701   {
7020    MapScriptJNI.set_mapObj_status(swigCPtr, status);
7030  }
704  
705   /**
706    * DOCUMENT ME!
707    *
708    * @return RETURN
709    *
710    * @todo METHOD_DESCRIPTION
711    */
712   public int getStatus()
713   {
7140    return MapScriptJNI.get_mapObj_status(swigCPtr);
715   }
716  
717   /**
718    * DOCUMENT ME!
719    *
720    * @param name PARAMETER
721    *
722    * @return RETURN
723    *
724    * @todo METHOD_DESCRIPTION
725    */
726   public int getSymbolByName(String name)
727   {
7280    return MapScriptJNI.mapObj_getSymbolByName(swigCPtr, name);
729   }
730  
731   /**
732    * DOCUMENT ME!
733    *
734    * @param szFileName PARAMETER
735    *
736    * @return RETURN
737    *
738    * @todo METHOD_DESCRIPTION
739    */
740   public int setSymbolSet(String szFileName)
741   {
7420    return MapScriptJNI.mapObj_setSymbolSet(swigCPtr, szFileName);
743   }
744  
745   /**
746    * DOCUMENT ME!
747    *
748    * @param transparent PARAMETER
749    *
750    * @todo METHOD_DESCRIPTION
751    */
752   public void setTransparent(int transparent)
753   {
7540    MapScriptJNI.set_mapObj_transparent(swigCPtr, transparent);
7550  }
756  
757   /**
758    * DOCUMENT ME!
759    *
760    * @return RETURN
761    *
762    * @todo METHOD_DESCRIPTION
763    */
764   public int getTransparent()
765   {
7660    return MapScriptJNI.get_mapObj_transparent(swigCPtr);
767   }
768  
769   /**
770    * DOCUMENT ME!
771    *
772    * @param units PARAMETER
773    *
774    * @todo METHOD_DESCRIPTION
775    */
776   public void setUnits(int units)
777   {
7780    MapScriptJNI.set_mapObj_units(swigCPtr, units);
7790  }
780  
781   /**
782    * DOCUMENT ME!
783    *
784    * @return RETURN
785    *
786    * @todo METHOD_DESCRIPTION
787    */
788   public int getUnits()
789   {
7900    return MapScriptJNI.get_mapObj_units(swigCPtr);
791   }
792  
793   /**
794    * DOCUMENT ME!
795    *
796    * @param web PARAMETER
797    *
798    * @todo METHOD_DESCRIPTION
799    */
800   public void setWeb(webObj web)
801   {
8020    MapScriptJNI.set_mapObj_web(swigCPtr, webObj.getCPtr(web));
8030  }
804  
805   /**
806    * DOCUMENT ME!
807    *
808    * @return RETURN
809    *
810    * @todo METHOD_DESCRIPTION
811    */
812   public webObj getWeb()
813   {
8140    return new webObj(MapScriptJNI.get_mapObj_web(swigCPtr), false);
815   }
816  
817   /**
818    * DOCUMENT ME!
819    *
820    * @param width PARAMETER
821    *
822    * @todo METHOD_DESCRIPTION
823    */
824   public void setWidth(int width)
825   {
8260    MapScriptJNI.set_mapObj_width(swigCPtr, width);
8270  }
828  
829   /**
830    * DOCUMENT ME!
831    *
832    * @return RETURN
833    *
834    * @todo METHOD_DESCRIPTION
835    */
836   public int getWidth()
837   {
8380    return MapScriptJNI.get_mapObj_width(swigCPtr);
839   }
840  
841   /**
842    * DOCUMENT ME!
843    *
844    * @param r PARAMETER
845    * @param g PARAMETER
846    * @param b PARAMETER
847    *
848    * @return RETURN
849    *
850    * @todo METHOD_DESCRIPTION
851    */
852   public int addColor(int r, int g, int b)
853   {
8540    return MapScriptJNI.mapObj_addColor(swigCPtr, r, g, b);
855   }
856  
857   /**
858    * DOCUMENT ME!
859    *
860    * @todo METHOD_DESCRIPTION
861    */
862   public void delete()
863   {
8640    if ((swigCPtr != 0) && swigCMemOwn)
865     {
8660      MapScriptJNI.delete_mapObj(swigCPtr);
8670      swigCMemOwn = false;
868     }
869  
8700    swigCPtr = 0;
8710  }
872  
873   /**
874    * DOCUMENT ME!
875    *
876    * @return RETURN
877    *
878    * @todo METHOD_DESCRIPTION
879    */
880   public imageObj draw()
881   {
8820    return new imageObj(MapScriptJNI.mapObj_draw(swigCPtr), false);
883   }
884  
885   /**
886    * DOCUMENT ME!
887    *
888    * @param image PARAMETER
889    *
890    * @return RETURN
891    *
892    * @todo METHOD_DESCRIPTION
893    */
894   public int drawLabelCache(imageObj image)
895   {
8960    return MapScriptJNI.mapObj_drawLabelCache(swigCPtr, imageObj.getCPtr(image));
897   }
898  
899   /**
900    * DOCUMENT ME!
901    *
902    * @return RETURN
903    *
904    * @todo METHOD_DESCRIPTION
905    */
906   public imageObj drawLegend()
907   {
9080    return new imageObj(MapScriptJNI.mapObj_drawLegend(swigCPtr), false);
909   }
910  
911   /**
912    * DOCUMENT ME!
913    *
914    * @return RETURN
915    *
916    * @todo METHOD_DESCRIPTION
917    */
918   public imageObj drawQuery()
919   {
9200    return new imageObj(MapScriptJNI.mapObj_drawQuery(swigCPtr), false);
921   }
922  
923   /**
924    * DOCUMENT ME!
925    *
926    * @return RETURN
927    *
928    * @todo METHOD_DESCRIPTION
929    */
930   public imageObj drawReferenceMap()
931   {
9320    return new imageObj(MapScriptJNI.mapObj_drawReferenceMap(swigCPtr), false);
933   }
934  
935   /**
936    * DOCUMENT ME!
937    *
938    * @return RETURN
939    *
940    * @todo METHOD_DESCRIPTION
941    */
942   public imageObj drawScalebar()
943   {
9440    return new imageObj(MapScriptJNI.mapObj_drawScalebar(swigCPtr), false);
945   }
946  
947   /**
948    * DOCUMENT ME!
949    *
950    * @param image PARAMETER
951    *
952    * @return RETURN
953    *
954    * @todo METHOD_DESCRIPTION
955    */
956   public int embedLegend(imageObj image)
957   {
9580    return MapScriptJNI.mapObj_embedLegend(swigCPtr, imageObj.getCPtr(image));
959   }
960  
961   /**
962    * DOCUMENT ME!
963    *
964    * @param image PARAMETER
965    *
966    * @return RETURN
967    *
968    * @todo METHOD_DESCRIPTION
969    */
970   public int embedScalebar(imageObj image)
971   {
9720    return MapScriptJNI.mapObj_embedScalebar(swigCPtr, imageObj.getCPtr(image));
973   }
974  
975   /**
976    * DOCUMENT ME!
977    *
978    * @param obj PARAMETER
979    *
980    * @return RETURN
981    *
982    * @todo METHOD_DESCRIPTION
983    */
984   public boolean equals(Object obj)
985   {
9860    boolean equal = false;
987  
9880    if (obj instanceof mapObj)
989     {
9900      equal = (((mapObj) obj).swigCPtr == this.swigCPtr);
991     }
992  
9930    return equal;
994   }
995  
996   /**
997    * DOCUMENT ME!
998    *
999    * @return RETURN
1000    *
1001    * @todo METHOD_DESCRIPTION
1002    */
1003   public int mapObj_getNumSymbols()
1004   {
10050    return MapScriptJNI.mapObj_mapObj_getNumSymbols(swigCPtr);
1006   }
1007  
1008   /**
1009    * DOCUMENT ME!
1010    *
1011    * @param layerindex PARAMETER
1012    *
1013    * @return RETURN
1014    *
1015    * @todo METHOD_DESCRIPTION
1016    */
1017   public int moveLayerdown(int layerindex)
1018   {
10190    return MapScriptJNI.mapObj_moveLayerdown(swigCPtr, layerindex);
1020   }
1021  
1022   /**
1023    * DOCUMENT ME!
1024    *
1025    * @param layerindex PARAMETER
1026    *
1027    * @return RETURN
1028    *
1029    * @todo METHOD_DESCRIPTION
1030    */
1031   public int moveLayerup(int layerindex)
1032   {
10330    return MapScriptJNI.mapObj_moveLayerup(swigCPtr, layerindex);
1034   }
1035  
1036   /**
1037    * DOCUMENT ME!
1038    *
1039    * @return RETURN
1040    *
1041    * @todo METHOD_DESCRIPTION
1042    */
1043   public labelCacheMemberObj nextLabel()
1044   {
10450    return new labelCacheMemberObj(MapScriptJNI.mapObj_nextLabel(swigCPtr),
1046       false);
1047   }
1048  
1049   /**
1050    * DOCUMENT ME!
1051    *
1052    * @return RETURN
1053    *
1054    * @todo METHOD_DESCRIPTION
1055    */
1056   public imageObj prepareImage()
1057   {
10580    return new imageObj(MapScriptJNI.mapObj_prepareImage(swigCPtr), false);
1059   }
1060  
1061   /**
1062    * DOCUMENT ME!
1063    *
1064    * @todo METHOD_DESCRIPTION
1065    */
1066   public void prepareQuery()
1067   {
10680    MapScriptJNI.mapObj_prepareQuery(swigCPtr);
10690  }
1070  
1071   /**
1072    * DOCUMENT ME!
1073    *
1074    * @param names PARAMETER
1075    * @param values PARAMETER
1076    * @param numentries PARAMETER
1077    *
1078    * @return RETURN
1079    *
1080    * @todo METHOD_DESCRIPTION
1081    */
1082   public String processLegendTemplate(SWIGTYPE_p_p_char names,
1083     SWIGTYPE_p_p_char values, int numentries)
1084   {
10850    return MapScriptJNI.mapObj_processLegendTemplate(swigCPtr,
1086       SWIGTYPE_p_p_char.getCPtr(names), SWIGTYPE_p_p_char.getCPtr(values),
1087       numentries);
1088   }
1089  
1090   /**
1091    * DOCUMENT ME!
1092    *
1093    * @param names PARAMETER
1094    * @param values PARAMETER
1095    * @param numentries PARAMETER
1096    *
1097    * @return RETURN
1098    *
1099    * @todo METHOD_DESCRIPTION
1100    */
1101   public String processQueryTemplate(SWIGTYPE_p_p_char names,
1102     SWIGTYPE_p_p_char values, int numentries)
1103   {
11040    return MapScriptJNI.mapObj_processQueryTemplate(swigCPtr,
1105       SWIGTYPE_p_p_char.getCPtr(names), SWIGTYPE_p_p_char.getCPtr(values),
1106       numentries);
1107   }
1108  
1109   /**
1110    * DOCUMENT ME!
1111    *
1112    * @param bGenerateImages PARAMETER
1113    * @param names PARAMETER
1114    * @param values PARAMETER
1115    * @param numentries PARAMETER
1116    *
1117    * @return RETURN
1118    *
1119    * @todo METHOD_DESCRIPTION
1120    */
1121   public String processTemplate(int bGenerateImages, SWIGTYPE_p_p_char names,
1122     SWIGTYPE_p_p_char values, int numentries)
1123   {
11240    return MapScriptJNI.mapObj_processTemplate(swigCPtr, bGenerateImages,
1125       SWIGTYPE_p_p_char.getCPtr(names), SWIGTYPE_p_p_char.getCPtr(values),
1126       numentries);
1127   }
1128  
1129   /**
1130    * DOCUMENT ME!
1131    *
1132    * @param slayer PARAMETER
1133    *
1134    * @return RETURN
1135    *
1136    * @todo METHOD_DESCRIPTION
1137    */
1138   public int queryByFeatures(int slayer)
1139   {
11400    return MapScriptJNI.mapObj_queryByFeatures(swigCPtr, slayer);
1141   }
1142  
1143   /**
1144    * DOCUMENT ME!
1145    *
1146    * @param point PARAMETER
1147    * @param mode PARAMETER
1148    * @param buffer PARAMETER
1149    *
1150    * @return RETURN
1151    *
1152    * @todo METHOD_DESCRIPTION
1153    */
1154   public int queryByPoint(pointObj point, int mode, double buffer)
1155   {
11560    return MapScriptJNI.mapObj_queryByPoint(swigCPtr, pointObj.getCPtr(point),
1157       mode, buffer);
1158   }
1159  
1160   /**
1161    * DOCUMENT ME!
1162    *
1163    * @param rect PARAMETER
1164    *
1165    * @return RETURN
1166    *
1167    * @todo METHOD_DESCRIPTION
1168    */
1169   public int queryByRect(rectObj rect)
1170   {
11710    return MapScriptJNI.mapObj_queryByRect(swigCPtr, rectObj.getCPtr(rect));
1172   }
1173  
1174   /**
1175    * DOCUMENT ME!
1176    *
1177    * @param shape PARAMETER
1178    *
1179    * @return RETURN
1180    *
1181    * @todo METHOD_DESCRIPTION
1182    */
1183   public int queryByShape(shapeObj shape)
1184   {
11850    return MapScriptJNI.mapObj_queryByShape(swigCPtr, shapeObj.getCPtr(shape));
1186   }
1187  
1188   /**
1189    * DOCUMENT ME!
1190    *
1191    * @param filename PARAMETER
1192    *
1193    * @return RETURN
1194    *
1195    * @todo METHOD_DESCRIPTION
1196    */
1197   public int save(String filename)
1198   {
11990    return MapScriptJNI.mapObj_save(swigCPtr, filename);
1200   }
1201  
1202   /**
1203    * DOCUMENT ME!
1204    *
1205    * @param filename PARAMETER
1206    *
1207    * @return RETURN
1208    *
1209    * @todo METHOD_DESCRIPTION
1210    */
1211   public int saveQuery(String filename)
1212   {
12130    return MapScriptJNI.mapObj_saveQuery(swigCPtr, filename);
1214   }
1215  
1216   /**
1217    * DOCUMENT ME!
1218    *
1219    * @param filename PARAMETER
1220    *
1221    * @return RETURN
1222    *
1223    * @todo METHOD_DESCRIPTION
1224    */
1225   public int saveQueryAsGML(String filename)
1226   {
12270    return MapScriptJNI.mapObj_saveQueryAsGML(swigCPtr, filename);
1228   }
1229  
1230   /**
1231    * DOCUMENT ME!
1232    *
1233    * @param factor PARAMETER
1234    * @param point PARAMETER
1235    * @param width PARAMETER
1236    * @param height PARAMETER
1237    * @param current PARAMETER
1238    * @param maximum PARAMETER
1239    *
1240    * @todo METHOD
1241    */
1242   public void zoomPoint(int factor, pointObj point, int width, int height,
1243     rectObj current, rectObj maximum)
1244   {
1245     /* -------------------------------------------------------------------- */
1246     /* check the validity of the parameters. */
1247     /* -------------------------------------------------------------------- */
12480    if ((factor == 0) || (point == null) || (width <= 0) || (height <= 0) ||
1249         (current == null) || (maximum == null))
1250     {
12510      System.out.println("zoomPoint failed : invald arguments");
1252  
12530      return;
1254     }
1255  
12560    System.out.println(Double.toString(current.getMinx()));
12570    System.out.println(Double.toString(current.getMaxx()));
12580    System.out.println(Double.toString(current.getMiny()));
12590    System.out.println(Double.toString(current.getMaxy()));
1260  
12610    System.out.println(Double.toString(maximum.getMinx()));
12620    System.out.println(Double.toString(maximum.getMaxx()));
12630    System.out.println(Double.toString(maximum.getMiny()));
12640    System.out.println(Double.toString(maximum.getMaxy()));
1265  
1266     /* -------------------------------------------------------------------- */
1267     /* check if the values passed are consistent min > max. */
1268     /* -------------------------------------------------------------------- */
12690    if (current.getMinx() >= current.getMaxx())
1270     {
12710      System.out.println(
1272         "zoomPoint failed : Georeferenced coordinates minx >= maxx");
1273  
12740      return;
1275     }
1276  
12770    if (current.getMiny() >= current.getMaxy())
1278     {
12790      System.out.println(
1280         "zoomPoint failed : Georeferenced coordinates miny >= maxy");
1281  
12820      return;
1283     }
1284  
12850    if (maximum.getMinx() >= maximum.getMaxx())
1286     {
12870      System.out.println(
1288         "zoomPoint failed : Max Georeferenced coordinates minx >= maxx");
1289     }
1290  
12910    if (maximum.getMiny() >= maximum.getMaxy())
1292     {
12930      System.out.println(
1294         "zoomPoint failed : Max Georeferenced coordinates miny >= maxy");
1295     }
1296  
12970    double newMaxScale = MapScript.CalculateScale(maximum, this.getUnits(),
1298         width, height, getResolution());
1299  
13000    System.out.println("newMaxScale=[" + newMaxScale + "]");
1301  
13020    webObj web = getWeb();
13030    web.setMaxscale(newMaxScale);
13040    web.setMinscale(5000);
1305  
13060    int x = (int) point.getX();
13070    int y = (int) point.getY();
1308  
13090    System.out.println("x=[" + x + "]");
13100    System.out.println("width=[" + width + "]");
13110    System.out.println("current.getMinx()=[" + current.getMinx() + "]");
13120    System.out.println("current.getMaxx()=[" + current.getMaxx() + "]");
1313  
13140    System.out.println("y=[" + y + "]");
13150    System.out.println("height=[" + height + "]");
13160    System.out.println("current.getMiny()=[" + current.getMiny() + "]");
13170    System.out.println("current.getMaxy()=[" + current.getMaxy() + "]");
1318  
13190    double dfGeoPosX = MapScript.Pix2Georef(x, 0, width, current.getMinx(),
1320         current.getMaxx(), false);
13210    double dfGeoPosY = MapScript.Pix2Georef(y, 0, height, current.getMiny(),
1322         current.getMaxy(), true);
1323  
13240    double dfDeltaX = current.getMaxx() - current.getMinx();
13250    double dfDeltaY = current.getMaxy() - current.getMiny();
1326  
13270    System.out.println("dfGeoPosX=[" + Double.toString(dfGeoPosX) + "]");
13280    System.out.println("dfGeoPosY=[" + Double.toString(dfGeoPosY) + "]");
13290    System.out.println("dfDeltaX=[" + Double.toString(dfDeltaX) + "]");
13300    System.out.println("dfDeltaY=[" + Double.toString(dfDeltaY) + "]");
1331  
13320    rectObj newExtents = new rectObj();
1333  
1334     /* -------------------------------------------------------------------- */
1335     /* zoom in */
1336     /* -------------------------------------------------------------------- */
13370    if (factor > 1)
1338     {
13390      newExtents.setMinx(dfGeoPosX - (dfDeltaX / (2 * factor)));
13400      newExtents.setMiny(dfGeoPosY - (dfDeltaY / (2 * factor)));
13410      newExtents.setMaxx(dfGeoPosX + (dfDeltaX / (2 * factor)));
13420      newExtents.setMaxy(dfGeoPosY + (dfDeltaY / (2 * factor)));
1343     }
1344  
1345     /* -------------------------------------------------------------------- */
1346     /* zoom out */
1347     /* -------------------------------------------------------------------- */
13480    if (factor < 0)
1349     {
13500      newExtents.setMinx(dfGeoPosX - ((dfDeltaX / 2) * (Math.abs(factor))));
13510      newExtents.setMiny(dfGeoPosY - ((dfDeltaY / 2) * (Math.abs(factor))));
13520      newExtents.setMaxx(dfGeoPosX + ((dfDeltaX / 2) * (Math.abs(factor))));
13530      newExtents.setMaxy(dfGeoPosY + ((dfDeltaY / 2) * (Math.abs(factor))));
1354     }
1355  
1356     /* -------------------------------------------------------------------- */
1357     /* re-center */
1358     /* -------------------------------------------------------------------- */
13590    if (factor == 1)
1360     {
13610      newExtents.setMinx(dfGeoPosX - (dfDeltaX / 2));
13620      newExtents.setMiny(dfGeoPosY - (dfDeltaY / 2));
13630      newExtents.setMaxx(dfGeoPosX + (dfDeltaX / 2));
13640      newExtents.setMaxy(dfGeoPosY + (dfDeltaY / 2));
1365     }
1366  
1367     /* -------------------------------------------------------------------- */
1368     /* if the min and max scale are set in the map file, we will */
1369     /* use them to test before zooming. */
1370     /* -------------------------------------------------------------------- */
13710    MapScript.AdjustExtent(newExtents, width, height);
1372  
13730    double newScale = MapScript.CalculateScale(newExtents, this.getUnits(),
1374         width, height, getResolution());
1375  
13760    double maxScale = web.getMaxscale();
1377  
13780    System.out.println("factor=[" + factor + "]");
13790    System.out.println("newScale=[" + Double.toString(newScale) + "]");
13800    System.out.println("maxScale=[" + Double.toString(maxScale) + "]");
1381  
13820    if (maxScale > 0)
1383     {
13840      if ((factor < 0) && (newScale > maxScale))
1385       {
13860        double dfDeltaExt = MapScript.GetDeltaExtentsUsingScale(maxScale,
1387             this.getUnits(), width, getResolution());
1388  
13890        if (dfDeltaExt > 0.0)
1390         {
13910          newExtents.setMinx(dfGeoPosX - (dfDeltaExt / 2));
13920          newExtents.setMiny(dfGeoPosY - (dfDeltaExt / 2));
13930          newExtents.setMaxx(dfGeoPosX + (dfDeltaExt / 2));
13940          newExtents.setMaxy(dfGeoPosY + (dfDeltaExt / 2));
1395         }
1396         else
1397         {
13980          return;
1399         }
1400       }
1401     }
1402  
1403     /* ==================================================================== */
1404     /* we do a spcial case for zoom in : we try to zoom as much as */
1405     /* possible using the mincale set in the .map. */
1406     /* ==================================================================== */
14070    double minScale = web.getMinscale();
1408  
14090    if ((minScale > 0) && (newScale < minScale) && (factor > 1))
1410     {
14110      double dfDeltaExt = MapScript.GetDeltaExtentsUsingScale(minScale,
1412           this.getUnits(), width, getResolution());
1413  
14140      if (dfDeltaExt > 0.0)
1415       {
14160        newExtents.setMinx(dfGeoPosX - (dfDeltaExt / 2));
14170        newExtents.setMiny(dfGeoPosY - (dfDeltaExt / 2));
14180        newExtents.setMaxx(dfGeoPosX + (dfDeltaExt / 2));
14190        newExtents.setMaxy(dfGeoPosY + (dfDeltaExt / 2));
1420       }
1421       else
1422       {
14230        return;
1424       }
1425     }
1426  
1427     /* -------------------------------------------------------------------- */
1428     /* If the buffer is set, make sure that the extents do not go */
1429     /* beyond the buffer. */
1430     /* -------------------------------------------------------------------- */
14310    dfDeltaX = newExtents.getMaxx() - newExtents.getMinx();
14320    dfDeltaY = newExtents.getMaxy() - newExtents.getMiny();
1433  
1434     /* Make sure Current georef extents is not bigger than max extents */
14350    if (dfDeltaX > (maximum.getMaxx() - maximum.getMinx()))
1436     {
14370      dfDeltaX = maximum.getMaxx() - maximum.getMinx();
1438     }
1439  
14400    if (dfDeltaY > (maximum.getMaxy() - maximum.getMiny()))
1441     {
14420      dfDeltaY = maximum.getMaxy() - maximum.getMiny();
1443     }
1444  
14450    if (newExtents.getMinx() < maximum.getMinx())
1446     {
14470      newExtents.setMinx(maximum.getMinx());
14480      newExtents.setMaxx(newExtents.getMinx() + dfDeltaX);
1449     }
1450  
14510    if (newExtents.getMaxx() > maximum.getMaxx())
1452     {
14530      newExtents.setMaxx(maximum.getMaxx());
14540      newExtents.setMinx(newExtents.getMaxx() - dfDeltaX);
1455     }
1456  
14570    if (newExtents.getMiny() < maximum.getMiny())
1458     {
14590      newExtents.setMiny(maximum.getMiny());
14600      newExtents.setMaxy(newExtents.getMiny() + dfDeltaY);
1461     }
1462  
14630    if (newExtents.getMaxy() > maximum.getMaxy())
1464     {
14650      newExtents.setMaxy(maximum.getMaxy());
14660      newExtents.setMiny(newExtents.getMaxy() - dfDeltaY);
1467     }
1468  
1469     /* -------------------------------------------------------------------- */
1470     /* set the map extents with new values. */
1471     /* -------------------------------------------------------------------- */
14720    MapScriptJNI.set_mapObj_extent(swigCPtr, rectObj.getCPtr(newExtents));
14730  }
1474  
1475   /**
1476    * DOCUMENT ME!
1477    *
1478    * @param rectangle PARAMETER
1479    * @param width PARAMETER
1480    * @param height PARAMETER
1481    * @param current PARAMETER
1482    * @param maximum PARAMETER
1483    *
1484    * @todo METHOD
1485    */
1486   public void zoomRectangle(rectObj rectangle, int width, int height,
1487     rectObj current, rectObj maximum)
1488   {
1489     /* -------------------------------------------------------------------- */
1490     /* check the validity of the parameters. */
1491     /* -------------------------------------------------------------------- */
14920    if ((rectangle == null) || (width <= 0) || (height <= 0) ||
1493         (current == null) || (maximum == null))
1494     {
14950      System.out.println("zoomRectangle failed : invald arguments");
1496  
14970      return;
1498     }
1499  
1500     /* -------------------------------------------------------------------- */
1501     /* check if the values passed are consistent min > max. */
1502     /* -------------------------------------------------------------------- */
15030    if (current.getMinx() >= current.getMaxx())
1504     {
15050      System.out.println(
1506         "zoomRectangle failed : Georeferenced coordinates minx >= maxx");
1507  
15080      return;
1509     }
1510  
15110    if (current.getMiny() >= current.getMaxy())
1512     {
15130      System.out.println(
1514         "zoomRectangle failed : Georeferenced coordinates miny >= maxy");
1515  
15160      return;
1517     }
1518  
15190    if (maximum.getMinx() >= maximum.getMaxx())
1520     {
15210      System.out.println(
1522         "zoomRectangle failed : Max Georeferenced coordinates minx >= maxx");
1523     }
1524  
15250    if (maximum.getMiny() >= maximum.getMaxy())
1526     {
15270      System.out.println(
1528         "zoomRectangle failed : Max Georeferenced coordinates miny >= maxy");
1529     }
1530  
15310    double newMaxScale = MapScript.CalculateScale(maximum, this.getUnits(),
1532         width, height, getResolution());
1533  
15340    System.out.println("newMaxScale=[" + newMaxScale + "]");
1535  
15360    webObj web = getWeb();
15370    web.setMaxscale(newMaxScale);
15380    web.setMinscale(5000);
1539  
15400    rectObj newExtents = new rectObj();
1541  
15420    newExtents.setMinx(MapScript.Pix2Georef((int) rectangle.getMinx(), 0,
1543         width, current.getMinx(), current.getMaxx(), false));
15440    newExtents.setMaxx(MapScript.Pix2Georef((int) rectangle.getMaxx(), 0,
1545         width, current.getMinx(), current.getMaxx(), false));
15460    newExtents.setMiny(MapScript.Pix2Georef((int) rectangle.getMiny(), 0,
1547         height, current.getMiny(), current.getMaxy(), true));
15480    newExtents.setMaxy(MapScript.Pix2Georef((int) rectangle.getMaxy(), 0,
1549         height, current.getMiny(), current.getMaxy(), true));
1550  
1551     /* -------------------------------------------------------------------- */
1552     /* if the min and max scale are set in the map file, we will */
1553     /* use them to test before setting extents. */
1554     /* -------------------------------------------------------------------- */
15550    MapScript.AdjustExtent(newExtents, width, height);
1556  
15570    double newScale = MapScript.CalculateScale(newExtents, this.getUnits(),
1558         width, height, getResolution());
1559  
15600    double maxScale = web.getMaxscale();
1561  
15620    System.out.println("newScale=[" + Double.toString(newScale) + "]");
15630    System.out.println("maxScale=[" + Double.toString(maxScale) + "]");
1564  
15650    if ((maxScale > 0) && (newScale > maxScale))
1566     {
15670      System.out.println("Resizing to maxScale=[" + Double.toString(maxScale) +
1568         "]");
1569  
15700      double dfDeltaExt = MapScript.GetDeltaExtentsUsingScale(maxScale,
1571           this.getUnits(), width, getResolution());
1572  
15730      double dfMiddleX = newExtents.getMinx() +
1574         ((newExtents.getMaxx() - newExtents.getMinx()) / 2);
15750      double dfMiddleY = newExtents.getMiny() +
1576         ((newExtents.getMaxy() - newExtents.getMiny()) / 2);
1577  
15780      if (dfDeltaExt > 0.0)
1579       {
15800        newExtents.setMinx(dfMiddleX - (dfDeltaExt / 2));
15810        newExtents.setMiny(dfMiddleY - (dfDeltaExt / 2));
15820        newExtents.setMaxx(dfMiddleX + (dfDeltaExt / 2));
15830        newExtents.setMaxy(dfMiddleY + (dfDeltaExt / 2));
1584       }
1585       else
1586       {
15870        System.out.println("Oh no...");
1588  
15890        return;
1590       }
1591     }
1592  
15930    double minScale = web.getMinscale();
1594  
15950    System.out.println("newScale=[" + Double.toString(newScale) + "]");
15960    System.out.println("minScale=[" + Double.toString(minScale) + "]");
1597  
15980    if ((minScale > 0) && (newScale < minScale))
1599     {
16000      System.out.println("Resizing to minScale=[" + Double.toString(minScale) +
1601         "]");
1602  
16030      double dfDeltaExt = MapScript.GetDeltaExtentsUsingScale(minScale,
1604           this.getUnits(), width, getResolution());
1605  
16060      double dfMiddleX = newExtents.getMinx() +
1607         ((newExtents.getMaxx() - newExtents.getMinx()) / 2);
16080      double dfMiddleY = newExtents.getMiny() +
1609         ((newExtents.getMaxy() - newExtents.getMiny()) / 2);
1610  
16110      if (dfDeltaExt > 0.0)
1612       {
16130        newExtents.setMinx(dfMiddleX - (dfDeltaExt / 2));
16140        newExtents.setMiny(dfMiddleY - (dfDeltaExt / 2));
16150        newExtents.setMaxx(dfMiddleX + (dfDeltaExt / 2));
16160        newExtents.setMaxy(dfMiddleY + (dfDeltaExt / 2));
1617       }
1618       else
1619       {
16200        System.out.println("Oh no...");
1621  
16220        return;
1623       }
1624     }
1625  
1626     /* -------------------------------------------------------------------- */
1627     /* If the buffer is set, make sure that the extents do not go */
1628     /* beyond the buffer. */
1629     /* -------------------------------------------------------------------- */
16300    double dfDeltaX = newExtents.getMaxx() - newExtents.getMinx();
16310    double dfDeltaY = newExtents.getMaxy() - newExtents.getMiny();
1632  
1633     /* Make sure Current georef extents is not bigger than max extents */
16340    if (dfDeltaX > (maximum.getMaxx() - maximum.getMinx()))
1635     {
16360      dfDeltaX = maximum.getMaxx() - maximum.getMinx();
1637     }
1638  
16390    if (dfDeltaY > (maximum.getMaxy() - maximum.getMiny()))
1640     {
16410      dfDeltaY = maximum.getMaxy() - maximum.getMiny();
1642     }
1643  
16440    if (newExtents.getMinx() < maximum.getMinx())
1645     {
16460      newExtents.setMinx(maximum.getMinx());
16470      newExtents.setMaxx(newExtents.getMinx() + dfDeltaX);
1648     }
1649  
16500    if (newExtents.getMaxx() > maximum.getMaxx())
1651     {
16520      newExtents.setMaxx(maximum.getMaxx());
16530      newExtents.setMinx(newExtents.getMaxx() - dfDeltaX);
1654     }
1655  
16560    if (newExtents.getMiny() < maximum.getMiny())
1657     {
16580      newExtents.setMiny(maximum.getMiny());
16590      newExtents.setMaxy(newExtents.getMiny() + dfDeltaY);
1660     }
1661  
16620    if (newExtents.getMaxy() > maximum.getMaxy())
1663     {
16640      newExtents.setMaxy(maximum.getMaxy());
16650      newExtents.setMiny(newExtents.getMaxy() - dfDeltaY);
1666     }
1667  
1668     /* -------------------------------------------------------------------- */
1669     /* set the map extents with new values. */
1670     /* -------------------------------------------------------------------- */
16710    MapScriptJNI.set_mapObj_extent(swigCPtr, rectObj.getCPtr(newExtents));
1672  
16730    rectObj selfExtents = getExtent();
1674  
16750    dfDeltaX = selfExtents.getMaxx() - selfExtents.getMinx();
16760    dfDeltaY = selfExtents.getMaxy() - selfExtents.getMiny();
1677  
16780    if (selfExtents.getMinx() < maximum.getMinx())
1679     {
16800      selfExtents.setMinx(maximum.getMinx());
16810      selfExtents.setMaxx(selfExtents.getMinx() + dfDeltaX);
1682     }
1683  
16840    if (selfExtents.getMaxx() > maximum.getMaxx())
1685     {
16860      selfExtents.setMaxx(maximum.getMaxx());
16870      selfExtents.setMinx(selfExtents.getMaxx() - dfDeltaX);
1688     }
1689  
16900    if (selfExtents.getMiny() < maximum.getMiny())
1691     {
16920      selfExtents.setMiny(maximum.getMiny());
16930      selfExtents.setMaxy(selfExtents.getMiny() + dfDeltaY);
1694     }
1695  
16960    if (selfExtents.getMaxy() > maximum.getMaxy())
1697     {
16980      selfExtents.setMaxy(maximum.getMaxy());
16990      selfExtents.setMiny(selfExtents.getMaxy() - dfDeltaY);
1700     }
17010  }
1702  
1703   /**
1704    * DOCUMENT ME!
1705    *
1706    * @param obj PARAMETER
1707    *
1708    * @return RETURN
1709    *
1710    * @todo METHOD_DESCRIPTION
1711    */
1712   protected static long getCPtr(mapObj obj)
1713   {
17140    return obj.swigCPtr;
1715   }
1716  
1717   /**
1718    * DOCUMENT ME!
1719    *
1720    * @todo METHOD_DESCRIPTION
1721    */
1722   protected void finalize()
1723   {
17240    delete();
17250  }
1726 }

this report was generated by version 1.0.2 of jcoverage.
visit www.jcoverage.com for updates.

copyright © 2003, jcoverage ltd. all rights reserved.
Java is a trademark of Sun Microsystems, Inc. in the United States and other countries.