Package net.ballmerlabs.scatterbrainsdk
Class ScatterMessage
-
- All Implemented Interfaces:
-
android.os.Parcelable
public final class ScatterMessage implements Parcelable
Represents a messages sent or received via Scatterbrain.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classScatterMessage.BuilderBuilder class used to construct a ScatterMessage
-
Field Summary
Fields Modifier and Type Field Description public final static Parcelable.Creator<ScatterMessage>CREATORprivate final ByteArraybodyprivate final SharedMemoryshmprivate final UUIDfromFingerprintprivate final UUIDtoFingerprintprivate final Stringapplicationprivate final Stringextensionprivate final Stringmimeprivate final Stringfilenameprivate final DatesendDateprivate final DatereceiveDateprivate final ParcelFileDescriptorfileDescriptorprivate final BooleanisFileprivate final ParcelUuidid
-
Method Summary
Modifier and Type Method Description final ByteArraygetBody()final SharedMemorygetShm()contents of message, null if message is a file final UUIDgetFromFingerprint()identity fingerprint of sender, null if anonymous final UUIDgetToFingerprint()identity fingerprint of recipient. final StringgetApplication()name of application this message belongs to final StringgetExtension()file extension of this message. final StringgetMime()mime type for this message final StringgetFilename()name of file on disk, null if not a file message final DategetSendDate()timestamp when this message was created final DategetReceiveDate()timestamp when this message was received by Scatterbrain final ParcelFileDescriptorgetFileDescriptor()final BooleanisFile()if this message contains a file descriptor, if false message contains inline bytes final ParcelUuidgetId()a unique id referring to this message, valid within the local router only IntegerdescribeContents()UnitwriteToParcel(Parcel parcel, Integer i)-
-
Method Detail
-
getShm
final SharedMemory getShm()
contents of message, null if message is a file
-
getFromFingerprint
final UUID getFromFingerprint()
identity fingerprint of sender, null if anonymous
-
getToFingerprint
final UUID getToFingerprint()
identity fingerprint of recipient. Currently unused
-
getApplication
final String getApplication()
name of application this message belongs to
-
getExtension
final String getExtension()
file extension of this message. Autogenerated if message is not a file
-
getFilename
final String getFilename()
name of file on disk, null if not a file message
-
getSendDate
final Date getSendDate()
timestamp when this message was created
-
getReceiveDate
final Date getReceiveDate()
timestamp when this message was received by Scatterbrain
-
getFileDescriptor
final ParcelFileDescriptor getFileDescriptor()
-
isFile
final Boolean isFile()
if this message contains a file descriptor, if false message contains inline bytes
-
getId
final ParcelUuid getId()
a unique id referring to this message, valid within the local router only
-
describeContents
Integer describeContents()
-
writeToParcel
Unit writeToParcel(Parcel parcel, Integer i)
-
-
-
-