Module it.auties.cobalt
Record Class SignalSignedKeyPair
java.lang.Object
java.lang.Record
it.auties.whatsapp.model.signal.keypair.SignalSignedKeyPair
- All Implemented Interfaces:
it.auties.protobuf.model.ProtobufMessage,it.auties.protobuf.model.ProtobufObject,ISignalKeyPair
public record SignalSignedKeyPair(int id, SignalKeyPair keyPair, byte[] signature)
extends Record
implements ISignalKeyPair, it.auties.protobuf.model.ProtobufMessage
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final intThe field for theidrecord component.private final SignalKeyPairThe field for thekeyPairrecord component.private final byte[]The field for thesignaturerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionSignalSignedKeyPair(int id, SignalKeyPair keyPair, byte[] signature) Creates an instance of aSignalSignedKeyPairrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intid()Returns the value of theidrecord component.keyPair()Returns the value of thekeyPairrecord component.static SignalSignedKeyPairof(int id, SignalKeyPair identityKeyPair) static Optional<SignalSignedKeyPair> byte[]byte[]byte[]Returns the value of thesignaturerecord component.toNode()final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface it.auties.whatsapp.model.signal.keypair.ISignalKeyPair
encodedId, signalPublicKey
-
Field Details
-
id
private final int idThe field for theidrecord component. -
keyPair
The field for thekeyPairrecord component. -
signature
private final byte[] signatureThe field for thesignaturerecord component.
-
-
Constructor Details
-
SignalSignedKeyPair
Creates an instance of aSignalSignedKeyPairrecord class.- Parameters:
id- the value for theidrecord componentkeyPair- the value for thekeyPairrecord componentsignature- the value for thesignaturerecord component
-
-
Method Details
-
of
-
of
-
privateKey
public byte[] privateKey()- Specified by:
privateKeyin interfaceISignalKeyPair
-
toNode
- Specified by:
toNodein interfaceISignalKeyPair
-
toGenericKeyPair
- Specified by:
toGenericKeyPairin interfaceISignalKeyPair
-
publicKey
public byte[] publicKey()- Specified by:
publicKeyin interfaceISignalKeyPair
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
id
public int id()Returns the value of theidrecord component.- Specified by:
idin interfaceISignalKeyPair- Returns:
- the value of the
idrecord component
-
keyPair
Returns the value of thekeyPairrecord component.- Returns:
- the value of the
keyPairrecord component
-
signature
public byte[] signature()Returns the value of thesignaturerecord component.- Returns:
- the value of the
signaturerecord component
-