Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
IntegrityTokenRequest.Builder
public
static
abstract
class
IntegrityTokenRequest.Builder
extends Object
java.lang.Object
|
↳ |
com.google.android.play.core.integrity.IntegrityTokenRequest.Builder
|
Builder dla IntegrityTokenRequest
.
Podsumowanie
Metody dziedziczone |
Zajęcia
java.lang.Object
boolean
|
equals(Object arg0)
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
Konstruktory publiczne
Budowniczy
public Builder ()
Metody publiczne
setCloudProjectNumber
public abstract IntegrityTokenRequest.Builder setCloudProjectNumber (long cloudProjectNumber)
Numer projektu w chmurze, który ma być połączony z tokenem integralności.
To pole jest wymagane w przypadku aplikacji rozpowszechnianych wyłącznie poza Google Play i pakietów SDK. W przypadku aplikacji rozpowszechnianych w Google Play numer projektu w chmurze jest konfigurowany w Konsoli Play i nie musi być ustawiany w żądaniu.
Numer projektu Google Cloud znajdziesz w informacjach o projekcie w konsoli Google Cloud w przypadku projektu Google Cloud, w którym włączony jest interfejs Play Integrity API.
Wywołania
odszyfrowujące token na serwerze Google muszą być uwierzytelniane za pomocą konta w chmurze, które zostało połączone z tokenem w tej prośbie.
Parametry |
cloudProjectNumber |
long |
setNonce
public abstract IntegrityTokenRequest.Builder setNonce (String nonce)
Wartość nonce, z którą ma być powiązany token integralności.
Musi być zakodowany w formacie Base64 obsługiwanym w internecie i bez zawijania wierszy.
Zobacz szczegóły
dotyczące wymagań i zaleceń związanych z wartością nonce.
Treść strony i umieszczone na niej fragmenty kodu podlegają licencjom opisanym w Licencji na treści. Java i OpenJDK są znakami towarowymi lub zastrzeżonymi znakami towarowymi należącymi do firmy Oracle lub jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-07-27 UTC.
[[["Łatwo zrozumieć","easyToUnderstand","thumb-up"],["Rozwiązało to mój problem","solvedMyProblem","thumb-up"],["Inne","otherUp","thumb-up"]],[["Brak potrzebnych mi informacji","missingTheInformationINeed","thumb-down"],["Zbyt skomplikowane / zbyt wiele czynności do wykonania","tooComplicatedTooManySteps","thumb-down"],["Nieaktualne treści","outOfDate","thumb-down"],["Problem z tłumaczeniem","translationIssue","thumb-down"],["Problem z przykładami/kodem","samplesCodeIssue","thumb-down"],["Inne","otherDown","thumb-down"]],["Ostatnia aktualizacja: 2025-07-27 UTC."],[],[],null,["# IntegrityTokenRequest.Builder\n\nSummary: [Ctors](#pubctors) \\| [Methods](#pubmethods) \\| [Inherited Methods](#inhmethods) \n\nIntegrityTokenRequest.Builder\n=============================\n\n\n`\npublic\nstatic\n\nabstract\nclass\nIntegrityTokenRequest.Builder\n`\n\n\n`\n\nextends `[Object](https://developer.android.com/reference/java/lang/Object.html)`\n\n\n`\n\n`\n\n\n`\n\n|---|----------------------------------------------------------------------|\n| [java.lang.Object](https://developer.android.com/reference/java/lang/Object.html) ||\n| ↳ | com.google.android.play.core.integrity.IntegrityTokenRequest.Builder |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nBuilder for [IntegrityTokenRequest](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.html).\n\nSummary\n-------\n\n| ### Public constructors ||\n|---------------------------------------------------------------------------------------------------------------------------------------|---|\n| ` `[Builder](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html#Builder())`() ` |\n\n| ### Public methods ||\n|-------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract `[IntegrityTokenRequest](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.html) | ` `[build](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html#build())`() ` Builds a [IntegrityTokenRequest](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.html). |\n| ` abstract `[IntegrityTokenRequest.Builder](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html) | ` `[setCloudProjectNumber](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html#setCloudProjectNumber(long))`(long cloudProjectNumber) ` A cloud project number to link to the integrity token. |\n| ` abstract `[IntegrityTokenRequest.Builder](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html) | ` `[setNonce](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html#setNonce(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` nonce) ` A nonce to bind the integrity token to. |\n\n| ### Inherited methods |\n|-----------------------|---|\n| From class ` `[java.lang.Object](https://developer.android.com/reference/java/lang/Object.html)` ` |-------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------| | ` boolean` | ` equals(`[Object](https://developer.android.com/reference/java/lang/Object.html)` arg0) ` | | ` final `[Class](https://developer.android.com/reference/java/lang/Class.html)`\u003c?\u003e` | ` getClass() ` | | ` int` | ` hashCode() ` | | ` final void` | ` notify() ` | | ` final void` | ` notifyAll() ` | | ` `[String](https://developer.android.com/reference/java/lang/String.html) | ` toString() ` | | ` final void` | ` wait(long arg0, int arg1) ` | | ` final void` | ` wait(long arg0) ` | | ` final void` | ` wait() ` | ||\n\nPublic constructors\n-------------------\n\n### Builder\n\n```\npublic Builder ()\n```\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\nPublic methods\n--------------\n\n### build\n\n```\npublic abstract IntegrityTokenRequest build ()\n```\n\nBuilds a [IntegrityTokenRequest](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.html).\n\n\u003cbr /\u003e\n\n| Returns ||\n|---------------------------------------------------------------------------------------------------------------------------|--------|\n| [IntegrityTokenRequest](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.html) | \u003cbr /\u003e |\n\n### setCloudProjectNumber\n\n```\npublic abstract IntegrityTokenRequest.Builder setCloudProjectNumber (long cloudProjectNumber)\n```\n\nA cloud project number to link to the integrity token.\n\nThis field is required for apps exclusively distributed outside of Google Play and SDKs. For\napps distributed on Google Play, the cloud project number is configured in the Play Console and\nneed not be set on the request.\n\nCloud project number can be found in Project info in your Google Cloud Console for the\ncloud project where Play Integrity API is enabled.\n\nCalls to [decrypt the token on Google's server](https://developer.android.com/google/play/integrity/classic#decrypt-verify-google-servers) must be authenticated using the cloud account that\nwas linked to the token in this request.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|----------------------|---------------|\n| `cloudProjectNumber` | `long` \u003cbr /\u003e |\n\n| Returns ||\n|-------------------------------------------------------------------------------------------------------------------------------------------|--------|\n| [IntegrityTokenRequest.Builder](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html) | \u003cbr /\u003e |\n\n### setNonce\n\n```\npublic abstract IntegrityTokenRequest.Builder setNonce (String nonce)\n```\n\nA nonce to bind the integrity token to.\n\nIt must be base64 encoded in web-safe no-wrap form.\n\nSee [details](https://developer.android.com/google/play/integrity/classic#nonce) about the nonce requirements and recommendations.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|---------|-----------------|\n| `nonce` | `String` \u003cbr /\u003e |\n\n| Returns ||\n|-------------------------------------------------------------------------------------------------------------------------------------------|--------|\n| [IntegrityTokenRequest.Builder](../../../../../../../reference/com/google/android/play/core/integrity/IntegrityTokenRequest.Builder.html) | \u003cbr /\u003e |"]]