Skip to content

Class Sublocation

Pavel Tychinin edited this page Mar 27, 2024 · 4 revisions

Sublocation class is used for storing sublocation parameters: identifier, name, width, heigth, etc. The list of sublocations for the current location can be obtained from Location class using public method Location.getSublocations.

Referenced from: Location.

Public methods

Function getId

public abstract int getId();

Function returns the sublocation's identifier.

Function getLocation

public abstract int getLocation();

Function returns the location's identifier.

Function getName

public abstract String getName();

Function returns the sublocation's name.

Function getWidth

public abstract float getWidth();

Function returns the sublocation's width (in meters).

Function getHeight

public abstract float getHeight();

Function returns the sublocation's height (in meters).

Function getAltitude

public abstract float getAltitude();

Function returns the sublocation's altitude (in meters).

Function getAzimuth

public abstract float getAzimuth();

Function returns the sublocation's azimuth angle (in degrees, clockwise).

Function getOriginPoint

public abstract GlobalPoint getOriginPoint();

Function returns the sublocation's origin point (in lat, lon).

Function getLevelId

public abstract String getLevelId();

Function returns the sublocation's level id.

Function getExternalId

public abstract String getExternalId();

Function returns the sublocation's external id.

Function getBeacons

public abstract ArrayList<Beacon> getBeacons();

Function returns the list of beacons, attached to this sublocation (see Beacon class).

Function getEddystones

public abstract ArrayList<Eddystone> getEddystones();

Function returns the list of eddystones, attached to this sublocation (see Eddystone class).

Function getWifis

public abstract ArrayList<Wifi> getWifis();

Function returns the list of wifis, attached to this sublocation (see Wifi class).

Function getVenues

public abstract ArrayList<Venue> getVenues();

Function returns the list of venues, attached to this sublocation (see Venue class).

Function getZones

public abstract ArrayList<Zone> getZones();

Function returns the list of zones from this sublocation (see Zone class).

Function getImage

public abstract android.graphics.Bitmap getImage(Integer maxTextureSize);

Function returns the origin sublocation image with specified maxTextureSize.

Parameters
  • maxTextureSize — scale parameter. Could be zero
Return value

android.graphics.Bitmap image — sublocation image.

Function localToGlobal

public abstract GlobalPoint localToGlobal(LocationPoint localPoint);

Function is used for converting the local sublocation coordinates to the global geographic coordinates (latitude and longitude) using the geographic binding of the sublocation.

Parameters
  • localPoint — the sublocation's local point.
Return value

Global point — the geographical latitude and longitude, corresponding to the specified position within the sublocation.

Function globalToLocal

public abstract LocationPoint globalToLocal(GlobalPoint globalPoint);

Function is used for converting the global geographic coordinates (latitude and longitude) to the local sublocation coordinates (x and y) using the geographic binding of the sublocation.

Parameters
  • globalPoint — the sublocation's global point.
Return value

The location point within the sublocation corresponding to the specified global point.

Function getVenueById

public abstract Venue getVenueById(int id);
Parameters
  • id — the identifier of the venue.
Return value

Function returns the venue (within the current sublocation) with the specified identifier or null if no such venue exists.

Function getZoneById

public abstract Zone getZoneById(int id);
Parameters
  • id — the identifier of the zone.
Return value

Function returns the zone (within the current sublocation) with the specified identifier or null if no such zone exists.

Function getGraph

public abstract Graph getGraph(String tag);
Parameters
  • tag — graph tag
Return value

Function returns graph (within the current sublocation) with the specified identifier or null if no such graph.

Clone this wiki locally