Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

eu.hansolo.fx:countries

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eu.hansolo.fx:countries

Countries is a JavaFX library containing controls and info for countries and cities

  • 21.0.19
  • Source
  • Maven
  • Socket score

Version published
Maintainers
1
Source

Countries

JFXCentral

Countries is a JavaFX library which contains information about countries like their shape, gps coordinates, cities and airports.

There are three controls you can use

  • WorldPane
  • RegionPane
  • CountryPane

Each of these controls comes with a builder which makes it more convenient to create the objects. And each of those controls has the ability to show a list of points of interest (Poi class) a heatmap as an overlay.

The Poi class has properties are:

  • latitude
  • longitude
  • name
  • info
  • valueObject
  • pointSize
  • fill
  • stroke
  • image
  • svgPath
  • svgPathDim

The heatmap spots are a simple list of Point objects.

Attention: Keep in mind that longitude = x and latitude = y coordinate when using the spots

The central class of the library is the Country class. It has methods to get the shape(s) of the country, it's national flag and also it's capital (if available). The Country class is an enum with the following properties: valueObject;

  • value;
  • fill;
  • stroke;
  • location;
  • displayName;
  • countryPaths;
  • countryBounds;

With the library also comes a City class which contains information about it's location (lat/lon), it's population (if available), the info if it is a capital and the country it belongs to. There is a method getCities() in the Helper class that returns the complete list of cities (~41000). In addition there is also an Airport class which contains 8665 airports with their name, country and IATA code. There is a method getAirports() in the Helper class that returns the coplete list of airports.

The WorldPane simply shows all available countries which gives you the whole world. To get a better understanding on how it works just take a look at the DemoWorldPane class.

DemoWorldPane

The RegionPane shows a region of countries (some of them are already predefined in the BusinessRegion class e.g. European Union, South America, APAC, EMEA etc.). With this you can visualize data based on one of those regions. Just take a look at the DemoRegionPane class to get a better understanding.

DemoRegionPane

The CountryPane shows just one country. To see how to use it please take a look at the DemoCountryPane class.

DemoCountryPane

Credits

Flag icons made by Freepik

World cities are provided by simplemaps

FAQs

Package last updated on 21 Aug 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc