Home > @magiclane/maps-sdk > ExternalInfo > hasWikiInfo

ExternalInfo.hasWikiInfo() method

Checks if the landmark has Wikipedia info

Requests all the wikipedia info at once (page title/url, page summary, and list of pictures - only urls of the pictures) - returns true if request successfully made, false if something went wrong. [ProgressListener] will notifyComplete with [GemError.success] once all the results are received from the Wikipedia API. It will request the info in the language of the device, and will fallback to English if a page in the main language doesn't exist. If neither the main language nor the English version exist, [ProgressListener] will notifyComplete with [GemError.general], and the request will be canceled.

Signature:

hasWikiInfo(landmark: Landmark): boolean;

Parameters

Parameter

Type

Description

landmark

Landmark

Landmark for which the check will be done.

Returns:

boolean

True if the landmark has Wikipedia info, false otherwise

Exceptions

An exception if it fails.