FileMessage
open class FileMessage: BaseMessage
Represents a mesage object that contains a file. Derived from BaseMessage
Note
This class doesn’t include a binary data for the file. It is just a URL.-
The file URL.
Declaration
Swift
open var url: String
-
The file URL without the ekey.
Since
3.0.194Declaration
Swift
public let plainURL: String?
-
The name of file.
Declaration
Swift
public let name: String
-
The size of file.
Declaration
Swift
public let size: UInt
-
The type of file.
Declaration
Swift
public let type: String
-
Image thumbnails.
Declaration
Swift
open internal(set) var thumbnails: [Thumbnail]?
-
Default constructor.
Declaration
Swift
public required init(from decoder: Decoder) throws
Parameters
decoder
Decoder
instance -
Encodes this object.
Declaration
Swift
open override func encode(to encoder: Encoder) throws
Parameters
encoder
Encoder
instance -
Undocumented
Declaration
Swift
open func getFileMessageParams() -> FileMessageCreateParams?
-
Disposes of the binary data in the file cache directory. The file message’s pending or failed message could have binary data in the
messageParams
property. The binary data could be used for the message preview or resending a failed message, so the binary data is stored in the file cache directory temporally. The binary data will be removed later automatically. If the binary data is needed to be removed when the pending or the failed file message is not used any more, this method could be called.Since
4.0.14Declaration
Swift
open func dispose()
-
Compares this object with given other object.
Declaration
Swift
public override func isEqual(_ object: Any?) -> Bool
Parameters
object
Any
instanceReturn Value
true
if same otherwisefalse
-
Copies this object
Declaration
Swift
open override func copy(with zone: NSZone? = nil) -> Any
Parameters
zone
optional
NSZone
Return Value
FileMessage
instance