Settings
Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
google.maps.Settings
Kurs
Einstellungen, die das Verhalten der Maps JavaScript API insgesamt steuern.
Rufe const {Settings} = await google.maps.importLibrary("core")
auf, um auf die Daten zuzugreifen. Weitere Informationen finden Sie unter Bibliotheken in der Maps JavaScript API.
Statische Methoden |
getInstance |
getInstance()
Parameter:Keine
Gibt die Singleton-Instanz von google.maps.Settings zurück. |
Attribute |
experienceIds
|
Eine Sammlung eindeutiger Experience-IDs, denen Maps JS API-Aufrufe zugeordnet werden sollen. Der zurückgegebene Wert ist eine Kopie des internen Werts, der in der Singleton-Instanz der Klasse Settings gespeichert ist. Vorgänge auf google.maps.Settings.getInstance().experienceIds ändern daher nur die Kopie und nicht den internen Wert.
Um den internen Wert zu aktualisieren, setzen Sie die Property auf den neuen Wert in der Singleton-Instanz (z. B. google.maps.Settings.getInstance().experienceIds = [experienceId]; ). |
fetchAppCheckToken |
Gibt ein Versprechen zurück, das in einem Firebase App Check-Token-Ergebnis aufgelöst wird. Das Token wird gRPC-Anfragen als HTTP-Header „X-Firebase-AppCheck“ angehängt. Wenn das Token leer ist, wird der Header nicht angehängt. |
google.maps.MapsAppCheckTokenResult
Benutzeroberfläche
Beschreibt ein Firebase App Check-Tokenergebnis.
Sofern nicht anders angegeben, sind die Inhalte dieser Seite unter der Creative Commons Attribution 4.0 License und Codebeispiele unter der Apache 2.0 License lizenziert. Weitere Informationen finden Sie in den Websiterichtlinien von Google Developers. Java ist eine eingetragene Marke von Oracle und/oder seinen Partnern.
Zuletzt aktualisiert: 2024-12-22 (UTC).
[null,null,["Zuletzt aktualisiert: 2024-12-22 (UTC)."],[],[],null,["# Settings\n\nThe documentation for has moved to a different page.\n\nThe documentation for the linked item could not be found. \n\n[Settings](#Settings)\nclass\n---------------------------\n\n\ngoogle.maps`.`Settings\nclass\n\nSettings which control the behavior of the Maps JavaScript API as a whole.\n\nAccess by calling `const {Settings} = await google.maps.importLibrary(\"core\")`. \nSee [Libraries in the Maps JavaScript API](/maps/documentation/javascript/libraries).\n\n| ### Static Methods ||\n|--------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [getInstance](#Settings.getInstance) | `getInstance()` **Parameters:** None **Return Value:** [Settings](/maps/documentation/javascript/reference/settings#Settings) Returns the singleton instance of `google.maps.Settings`. |\n\n| ### Properties ||\n|----------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [experienceIds](#Settings.experienceIds) | **Notice:** Available only in the [v=beta channel](/maps/documentation/javascript/versions#choosing-the-beta-channel). **Type:** [Iterable](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Iteration_protocols#the_iterable_protocol)`\u003cstring\u003e` A collection of unique experience IDs to which to attribute Maps JS API calls. The returned value is a copy of the internal value that is stored in the `Settings` class singleton instance. Operations on `google.maps.Settings.getInstance().experienceIds` will therefore only modify the copy and not the internal value. To update the internal value, set the property equal to the new value on the singleton instance (ex: `google.maps.Settings.getInstance().experienceIds = [experienceId];`). |\n| [fetchAppCheckToken](#Settings.fetchAppCheckToken) | **Type:** `function(): `[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)`\u003c`[MapsAppCheckTokenResult](/maps/documentation/javascript/reference/settings#MapsAppCheckTokenResult)`\u003e` Set this property to a function that returns a promise which resolves to a Firebase App Check token result. |\n\n[MapsAppCheckTokenResult](#MapsAppCheckTokenResult)\ninterface\n-------------------------------------------------------------\n\n\ngoogle.maps`.`MapsAppCheckTokenResult\ninterface\n\nDescribes a Firebase App Check token result."]]