See what premium Google Developer Program benefits can do for you. Learn more
Stay organized with collections
Save and categorize content based on your preferences.
OpaqueId
class OpaqueId
Immutable class that represents an ID.
Summary
Public methods
hashCode
fun hashCode(): Int
Companion functions
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-31 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-31 UTC."],[[["`OpaqueId` is an immutable class representing an ID, providing methods for comparison and conversion."],["It can be converted to and from `ByteArray` and `ByteString` representations."],["Companion functions allow creation of `OpaqueId` instances from `ByteArray` and `ByteString`."],["Includes standard methods like `equals` and `hashCode` for object comparison."]]],["The `OpaqueId` class is an immutable identifier. It provides methods to convert the `OpaqueId` to a `ByteArray` or `ByteString` via `toByteArray()` and `toByteString()`. The `equals()` and `hashCode()` methods are also available. Companion functions `fromByteArray()` and `fromByteString()` allow the creation of an `OpaqueId` from a `ByteArray` or `ByteString`, respectively.\n"]]