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

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 imageObj
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 imageObj object.
48    *
49    * @param width PARAMETER
50    * @param height PARAMETER
51    */
52   public imageObj(int width, int height)
53   {
540    this(MapScriptJNI.new_imageObj(width, height), true);
550  }
56  
57   /**
58    * Creates a new imageObj object.
59    *
60    * @param cPtr PARAMETER
61    * @param cMemoryOwn PARAMETER
62    */
63   protected imageObj(long cPtr, boolean cMemoryOwn)
640  {
650    swigCMemOwn = cMemoryOwn;
660    swigCPtr = cPtr;
670  }
68  
69   /**
70    * Creates a new imageObj object.
71    */
72   protected imageObj()
73   {
740    this(0, false);
750  }
76  
77   /**
78    * DOCUMENT ME!
79    *
80    * @return RETURN
81    *
82    * @todo METHOD_DESCRIPTION
83    */
84   public int getHeight()
85   {
860    return MapScriptJNI.get_imageObj_height(swigCPtr);
87   }
88  
89   /**
90    * DOCUMENT ME!
91    *
92    * @return RETURN
93    *
94    * @todo METHOD_DESCRIPTION
95    */
96   public String getImagepath()
97   {
980    return MapScriptJNI.get_imageObj_imagepath(swigCPtr);
99   }
100  
101   /**
102    * DOCUMENT ME!
103    *
104    * @return RETURN
105    *
106    * @todo METHOD_DESCRIPTION
107    */
108   public String getImageurl()
109   {
1100    return MapScriptJNI.get_imageObj_imageurl(swigCPtr);
111   }
112  
113   /**
114    * DOCUMENT ME!
115    *
116    * @return RETURN
117    *
118    * @todo METHOD_DESCRIPTION
119    */
120   public int getWidth()
121   {
1220    return MapScriptJNI.get_imageObj_width(swigCPtr);
123   }
124  
125   /**
126    * DOCUMENT ME!
127    *
128    * @todo METHOD_DESCRIPTION
129    */
130   public void delete()
131   {
1320    if ((swigCPtr != 0) && swigCMemOwn)
133     {
1340      MapScriptJNI.delete_imageObj(swigCPtr);
1350      swigCMemOwn = false;
136     }
137  
1380    swigCPtr = 0;
1390  }
140  
141   /**
142    * DOCUMENT ME!
143    *
144    * @param obj PARAMETER
145    *
146    * @return RETURN
147    *
148    * @todo METHOD_DESCRIPTION
149    */
150   public boolean equals(Object obj)
151   {
1520    boolean equal = false;
153  
1540    if (obj instanceof imageObj)
155     {
1560      equal = (((imageObj) obj).swigCPtr == this.swigCPtr);
157     }
158  
1590    return equal;
160   }
161  
162   /**
163    * DOCUMENT ME!
164    *
165    * @todo METHOD_DESCRIPTION
166    */
167   public void free()
168   {
1690    MapScriptJNI.imageObj_free(swigCPtr);
1700  }
171  
172   /**
173    * DOCUMENT ME!
174    *
175    * @param filename PARAMETER
176    * @param type PARAMETER
177    * @param transparent PARAMETER
178    * @param interlace PARAMETER
179    * @param quality PARAMETER
180    *
181    * @return RETURN
182    *
183    * @todo METHOD_DESCRIPTION
184    */
185   public int saveImage(String filename, int type, int transparent,
186     int interlace, int quality)
187   {
1880    return MapScriptJNI.imageObj_saveImage(swigCPtr, filename, type,
189       transparent, interlace, quality);
190   }
191  
192   /**
193    * DOCUMENT ME!
194    *
195    * @param obj PARAMETER
196    *
197    * @return RETURN
198    *
199    * @todo METHOD_DESCRIPTION
200    */
201   protected static long getCPtr(imageObj obj)
202   {
2030    return obj.swigCPtr;
204   }
205  
206   /**
207    * DOCUMENT ME!
208    *
209    * @todo METHOD_DESCRIPTION
210    */
211   protected void finalize()
212   {
2130    delete();
2140  }
215 }

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.