39 public abstract boolean setBitmap(com.navigine.image.ImageProvider bitmap);
93 private final long nativeRef;
94 private final AtomicBoolean destroyed =
new AtomicBoolean(
false);
96 private CppProxy(
long nativeRef)
98 if (nativeRef == 0)
throw new RuntimeException(
"nativeRef is zero");
99 this.nativeRef = nativeRef;
102 private native
void nativeDestroy(
long nativeRef);
103 public void _djinni_private_destroy()
105 boolean destroyed = this.destroyed.getAndSet(
true);
106 if (!destroyed) nativeDestroy(this.nativeRef);
108 protected void finalize() throws
java.lang.Throwable
110 _djinni_private_destroy();
117 public boolean setBitmap(com.navigine.image.ImageProvider bitmap)
119 assert !this.destroyed.get() :
"trying to use a destroyed object";
120 return native_setBitmap(this.nativeRef, bitmap);
122 private native
boolean native_setBitmap(
long _nativeRef, com.navigine.image.ImageProvider bitmap);
127 assert !this.destroyed.get() :
"trying to use a destroyed object";
128 native_addListener(this.nativeRef, listener);
135 assert !this.destroyed.get() :
"trying to use a destroyed object";
136 native_removeListener(this.nativeRef, listener);
138 private native
void native_removeListener(
long _nativeRef, ClusterMapObjectListener listener);
141 public LocationPoint getPosition()
143 assert !this.destroyed.get() :
"trying to use a destroyed object";
144 return native_getPosition(this.nativeRef);
146 private native LocationPoint native_getPosition(
long _nativeRef);
149 public int getCount()
151 assert !this.destroyed.get() :
"trying to use a destroyed object";
152 return native_getCount(this.nativeRef);
154 private native
int native_getCount(
long _nativeRef);
157 public ArrayList<IconMapObject> getIconMapObjects()
159 assert !this.destroyed.get() :
"trying to use a destroyed object";
160 return native_getIconMapObjects(this.nativeRef);
162 private native ArrayList<IconMapObject> native_getIconMapObjects(
long _nativeRef);
169 assert !this.destroyed.get() :
"trying to use a destroyed object";
170 return native_getId(this.nativeRef);
172 private native
int native_getId(
long _nativeRef);
175 public MapObjectType getType()
177 assert !this.destroyed.get() :
"trying to use a destroyed object";
178 return native_getType(this.nativeRef);
180 private native MapObjectType native_getType(
long _nativeRef);
183 public byte[] getData()
185 assert !this.destroyed.get() :
"trying to use a destroyed object";
186 return native_getData(this.nativeRef);
188 private native
byte[] native_getData(
long _nativeRef);
191 public boolean setVisible(
boolean visible)
193 assert !this.destroyed.get() :
"trying to use a destroyed object";
194 return native_setVisible(this.nativeRef, visible);
196 private native
boolean native_setVisible(
long _nativeRef,
boolean visible);
199 public boolean setInteractive(
boolean interactive)
201 assert !this.destroyed.get() :
"trying to use a destroyed object";
202 return native_setInteractive(this.nativeRef, interactive);
204 private native
boolean native_setInteractive(
long _nativeRef,
boolean interactive);
207 public void setData(
byte[] data)
209 assert !this.destroyed.get() :
"trying to use a destroyed object";
210 native_setData(this.nativeRef, data);
212 private native
void native_setData(
long _nativeRef,
byte[] data);
215 public boolean setTitle(String title)
217 assert !this.destroyed.get() :
"trying to use a destroyed object";
218 return native_setTitle(this.nativeRef, title);
220 private native
boolean native_setTitle(
long _nativeRef, String title);
223 public boolean setAlpha(
float alpha)
225 assert !this.destroyed.get() :
"trying to use a destroyed object";
226 return native_setAlpha(this.nativeRef, alpha);
228 private native
boolean native_setAlpha(
long _nativeRef,
float alpha);