Bridges-Java 3.5.0-dev1
Bridges(Java API)
Loading...
Searching...
No Matches
Public Member Functions | List of all members
bridges.base.WorldMap Class Reference

This class provides an API to building, displaying and manipulating World maps and countries in BRIDGES. More...

Inheritance diagram for bridges.base.WorldMap:
bridges.base.DataStruct bridges.base.AbstrMap

Public Member Functions

 WorldMap ()
 constructor for drawing the World map as an overlay with default colors
 
 WorldMap (ArrayList< Country > country_data)
 constructor for drawing the World map when countries need to have data mapped onto them
 
String getProjection ()
 
Boolean getOverlay ()
 Gets the map overlay flag.
 
void setCountryData (ArrayList< Country > country_data)
 set country data
 
String getMapRepresentation ()
 Generates the JSON representation of the World map.
 
String getDataStructureRepresentation ()
 get JSON representation of the data structure - a dummy string
 
String getDataStructType ()
 

Additional Inherited Members

- Protected Attributes inherited from bridges.base.DataStruct
String QUOTE = "\""
 
String COMMA = ","
 
String COLON = ":"
 
String OPEN_CURLY = "{"
 
String CLOSE_CURLY = "}"
 
String OPEN_PAREN = "("
 
String CLOSE_PAREN = ")"
 
String OPEN_BOX = "["
 
String CLOSE_BOX = "]"
 

Detailed Description

This class provides an API to building, displaying and manipulating World maps and countries in BRIDGES.

In the current implementation, we can draw a World map with all country boundaries, or specify a set of countries and display the country boundaries.

Functions are provided to access each country county and color its boundary, its interior using stroke and fill color functions. This lets us build map based applications where the fill color can be used to represent different data attributes, such as population counts, election statistics or any attribute at the country level. We stop at the country level as each country has its own subdivisions, such as discticts, states, regions, counties, etc.

The default constructor allows to get a basic map fo the entire world and supports no styling.

See the Maps tutorials for examples of the usage of the World Map API at https://bridgesuncc.github.io/tutorials/Map.html

Authors: Kalpathi Subramanian, Erik Saule

Last modified : June 6, 2025

Constructor & Destructor Documentation

◆ WorldMap() [1/2]

bridges.base.WorldMap.WorldMap ( )

constructor for drawing the World map as an overlay with default colors

◆ WorldMap() [2/2]

bridges.base.WorldMap.WorldMap ( ArrayList< Country >  country_data)

constructor for drawing the World map when countries need to have data mapped onto them

Parameters
country_datalist of country objects

Member Function Documentation

◆ getDataStructType()

String bridges.base.WorldMap.getDataStructType ( )

Reimplemented from bridges.base.DataStruct.

◆ getDataStructureRepresentation()

String bridges.base.WorldMap.getDataStructureRepresentation ( )

get JSON representation of the data structure - a dummy string

Returns
JSON string

Reimplemented from bridges.base.DataStruct.

◆ getMapRepresentation()

String bridges.base.WorldMap.getMapRepresentation ( )

Generates the JSON representation of the World map.

Returns
string

Implements bridges.base.AbstrMap.

◆ getOverlay()

Boolean bridges.base.WorldMap.getOverlay ( )

Gets the map overlay flag.

Implements bridges.base.AbstrMap.

◆ getProjection()

String bridges.base.WorldMap.getProjection ( )

get the world map projection

Returns
projection type

Implements bridges.base.AbstrMap.

◆ setCountryData()

void bridges.base.WorldMap.setCountryData ( ArrayList< Country >  country_data)

set country data

Parameters
country_datalist of country objects

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