Loading...
Searching...
No Matches
com.navigine.idl.java.internal.PolygonMapObjectBinding Class Reference
+ Inheritance diagram for com.navigine.idl.java.internal.PolygonMapObjectBinding:

Public Member Functions

native boolean isValid ()
 
boolean setPolygon (LocationPolygon polygon)
 Method is used to specify the source polygon of the object.
 
boolean setColor (float red, float green, float blue, float alpha)
 Method is used to specify the color of the object.
 
boolean setOrder (int order)
 Method is used to specify the rendering order of the object.
 
int getId ()
 Gets the unique identifier of the map object.
 
MapObjectType getType ()
 Gets the type of the map object.
 
byte[] getData ()
 Gets the user-defined data associated with the map object.
 
boolean setVisible (boolean visible)
 Method is used to specify the visibility of the map object.
 
boolean setInteractive (boolean interactive)
 Method is used to specify whether the map object can be interacted with.
 
void setData (byte[] data)
 Method is used to set user-defined data for the map object.
 
boolean setTitle (String title)
 Method is used to set the title of the map object.
 
boolean setAlpha (float alpha)
 Method is used to set the opacity of the map object.
 

Detailed Description

Definition at line 12 of file PolygonMapObjectBinding.java.

Member Function Documentation

◆ getData()

byte[] com.navigine.idl.java.internal.PolygonMapObjectBinding.getData ( )
inline

Gets the user-defined data associated with the map object.

Returns
The data stored in the map object.

Java code snippet:

// Get custom data
Map<String, String> retrievedData = circleMapObject.getData();
System.out.println("Circle custom data: " + retrievedData);

Kotlin code snippet:

// Get custom data
val retrievedData = circleMapObject!!.data
println("Circle custom data: $retrievedData")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 64 of file PolygonMapObjectBinding.java.

◆ getId()

int com.navigine.idl.java.internal.PolygonMapObjectBinding.getId ( )
inline

Gets the unique identifier of the map object.

Returns
The unique identifier of the map object.

Java code snippet:

// Get object ID
int objectId = circleMapObject.getId();
System.out.println("Circle object ID: " + objectId);

Kotlin code snippet:

// Get object ID
val objectId = circleMapObject!!.id
println("Circle object ID: $objectId")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 50 of file PolygonMapObjectBinding.java.

◆ getType()

MapObjectType com.navigine.idl.java.internal.PolygonMapObjectBinding.getType ( )
inline

Gets the type of the map object.

Returns
The type of the map object MapObjectType.

Java code snippet:

// Get object type
String objectTypeString = circleMapObject.getType();
System.out.println("Circle object type: " + objectTypeString);

Kotlin code snippet:

// Get object type
val objectTypeString = circleMapObject!!.type
println("Circle object type: $objectTypeString")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 57 of file PolygonMapObjectBinding.java.

◆ isValid()

native boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.isValid ( )

Tells if this PolygonMapObject is valid or not. Any other method (except for this one) called on an invalid PolygonMapObject will throw java.lang.RuntimeException.

Reimplemented from com.navigine.idl.java.PolygonMapObject.

◆ setAlpha()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setAlpha ( float alpha)
inline

Method is used to set the opacity of the map object.

Parameters
alphaOpacity multiplier. Values below 0 will be set to 0. Values above 1 will be set to 1. Default: 1.
Returns
true if the operation is successful, false otherwise.

Java code snippet:

// Set alpha transparency
boolean alphaSuccess = circleMapObject.setAlpha(0.7);
System.out.println("Set circle alpha to 0.7: " + alphaSuccess);

Kotlin code snippet:

// Set alpha transparency
val alphaSuccess = circleMapObject!!.setAlpha(0.7)
println("Set circle alpha to 0.7: $alphaSuccess")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 99 of file PolygonMapObjectBinding.java.

◆ setColor()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setColor ( float red,
float green,
float blue,
float alpha )
inline

Method is used to specify the color of the object.

Parameters
redRed RGBA component.
greenGreen RGBA component.
blueBlue RGBA component.
alphaOpacity multiplier. Values below 0 will be set to 0. Default: 1.
Returns
true if success, false otherwise.

Java code snippet:

// Set polygon color
boolean colorSuccess = polygonMapObject.setColor(0.0, 1.0, 0.0, 0.7);
System.out.println("Set polygon color to green with 70% opacity: " + colorSuccess);

Kotlin code snippet:

// Set polygon color
val colorSuccess = polygonMapObject!!.setColor(0.0, 1.0, 0.0, 0.7)
println("Set polygon color to green with 70% opacity: $colorSuccess")

Reimplemented from com.navigine.idl.java.PolygonMapObject.

Definition at line 34 of file PolygonMapObjectBinding.java.

◆ setData()

void com.navigine.idl.java.internal.PolygonMapObjectBinding.setData ( byte[] data)
inline

Method is used to set user-defined data for the map object.

Parameters
dataData to store in the map object.

Java code snippet:

// Set custom data
Map<String, String> customData = new HashMap<>();
customData.put("key", "value");
customData.put("number", "42");
boolean dataSuccess = circleMapObject.setData(customData);
System.out.println("Set circle custom data: " + dataSuccess);

Kotlin code snippet:

// Set custom data
val customData = mapOf("key" to "value", "number" to "42")
val dataSuccess = circleMapObject!!.setData(customData)
println("Set circle custom data: $dataSuccess")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 85 of file PolygonMapObjectBinding.java.

◆ setInteractive()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setInteractive ( boolean interactive)
inline

Method is used to specify whether the map object can be interacted with.

Parameters
interactiveSpecifies whether the object can be picked in the pickMapObjectAt method (true) or not (false). Default: false.
Returns
true if the operation is successful, false otherwise.

Java code snippet:

// Set interactive mode
boolean interactiveSuccess = circleMapObject.setInteractive(true);
System.out.println("Set circle interactive to true: " + interactiveSuccess);

Kotlin code snippet:

// Set interactive mode
val interactiveSuccess = circleMapObject!!.setInteractive(true)
println("Set circle interactive to true: $interactiveSuccess")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 78 of file PolygonMapObjectBinding.java.

◆ setOrder()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setOrder ( int order)
inline

Method is used to specify the rendering order of the object.

Parameters
orderThe rendering order value. Default: 0.
Returns
true if success, false otherwise.

Java code snippet:

// Set polygon rendering order
boolean orderSuccess = polygonMapObject.setOrder(2);
System.out.println("Set polygon rendering order to 2: " + orderSuccess);

Kotlin code snippet:

// Set polygon rendering order
val orderSuccess = polygonMapObject!!.setOrder(2)
println("Set polygon rendering order to 2: $orderSuccess")

Reimplemented from com.navigine.idl.java.PolygonMapObject.

Definition at line 41 of file PolygonMapObjectBinding.java.

◆ setPolygon()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setPolygon ( LocationPolygon polygon)
inline

Method is used to specify the source polygon of the object.

Parameters
polygonMetrics coordinates of the polygon LocationPolygon.
Returns
true if success, false otherwise.

Java code snippet:

// Set polygon geometry
List<Point> points = Arrays.asList(
new Point(100.0, 200.0),
new Point(150.0, 250.0),
new Point(200.0, 200.0),
new Point(150.0, 150.0)
);
Polygon metricPolygon = new Polygon(points);
LocationPolygon polygon = new LocationPolygon(metricPolygon, 1, 0);
boolean success = polygonMapObject.setPolygon(polygon);
System.out.println("Set polygon with " + points.size() + " points: " + success);

Kotlin code snippet:

// Set polygon geometry
val points = listOf(
Point(50.0, 60.0),
Point(55.0, 65.0),
Point(60.0, 60.0),
Point(55.0, 55.0)
)
val metricPolygon = Polygon(points)
val polygon = LocationPolygon(metricPolygon, 1, 0)
val success = polygonMapObject!!.setPolygon(polygon)
println("Set polygon with ${points.size} points: $success")

Reimplemented from com.navigine.idl.java.PolygonMapObject.

Definition at line 27 of file PolygonMapObjectBinding.java.

◆ setTitle()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setTitle ( String title)
inline

Method is used to set the title of the map object.

Parameters
titleThe title to display on the location view.
Returns
true if the operation is successful, false otherwise.

Java code snippet:

// Set title
boolean titleSuccess = circleMapObject.setTitle("Circle Object");
System.out.println("Set circle title to 'Circle Object': " + titleSuccess);

Kotlin code snippet:

// Set title
val titleSuccess = circleMapObject!!.setTitle("Circle Object")
println("Set circle title to 'Circle Object': $titleSuccess")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 92 of file PolygonMapObjectBinding.java.

◆ setVisible()

boolean com.navigine.idl.java.internal.PolygonMapObjectBinding.setVisible ( boolean visible)
inline

Method is used to specify the visibility of the map object.

Parameters
visibleSpecifies whether the object is visible (true) or hidden (false). Default: true.
Returns
true if the operation is successful, false otherwise.

Java code snippet:

// Set visibility
boolean visibleSuccess = circleMapObject.setVisible(true);
System.out.println("Set circle visibility to true: " + visibleSuccess);

Kotlin code snippet:

// Set visibility
val visibleSuccess = circleMapObject!!.setVisible(true)
println("Set circle visibility to true: $visibleSuccess")

Reimplemented from com.navigine.idl.java.MapObject.

Definition at line 71 of file PolygonMapObjectBinding.java.


The documentation for this class was generated from the following file: