org.whispersystems.signalservice.api.messages.SignalServiceAttachmentPointer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of signal-service-java Show documentation
Show all versions of signal-service-java Show documentation
Signal Service communication library for Java, unofficial fork
/*
* Copyright (C) 2014-2017 Open Whisper Systems
*
* Licensed according to the LICENSE file in this repository.
*/
package org.whispersystems.signalservice.api.messages
import java.util.Optional
import java.util.UUID
/**
* Represents a received SignalServiceAttachment "handle." This
* is a pointer to the actual attachment content, which needs to be
* retrieved using [SignalServiceMessageReceiver.retrieveAttachment]
*
* @author Moxie Marlinspike
*/
class SignalServiceAttachmentPointer(
val cdnNumber: Int,
val remoteId: SignalServiceAttachmentRemoteId,
contentType: String?,
val key: ByteArray?,
val size: Optional,
val preview: Optional,
val width: Int,
val height: Int,
val digest: Optional,
val incrementalDigest: Optional,
val incrementalMacChunkSize: Int,
val fileName: Optional,
val voiceNote: Boolean,
val isBorderless: Boolean,
val isGif: Boolean,
val caption: Optional,
val blurHash: Optional,
val uploadTimestamp: Long,
val uuid: UUID?
) : SignalServiceAttachment(contentType) {
override fun isStream() = false
override fun isPointer() = true
}