diff --git a/src/main/kotlin/com/cubetiqs/messaging/client/telegram/TelegramFileDocument.kt b/src/main/kotlin/com/cubetiqs/messaging/client/telegram/TelegramFileDocument.kt index 4203660..cf4d5de 100644 --- a/src/main/kotlin/com/cubetiqs/messaging/client/telegram/TelegramFileDocument.kt +++ b/src/main/kotlin/com/cubetiqs/messaging/client/telegram/TelegramFileDocument.kt @@ -3,7 +3,7 @@ package com.cubetiqs.messaging.client.telegram import java.io.Serializable /** - * File Document + * Telegram File Document * * @author sombochea * @since 1.0 @@ -13,4 +13,24 @@ open class TelegramFileDocument ( var name: String? = null, var type: String? = null, var extension: String? = null, -) : Serializable \ No newline at end of file +) : Serializable { + fun setFile(file: ByteArray?) = apply { + this.file = file + } + + fun setName(name: String?) = apply { + this.name = name + } + + fun setType(type: String?) = apply { + this.type = type + } + + fun setExtension(extension: String?) = apply { + this.extension = extension + } + + companion object { + fun create() = TelegramFileDocument() + } +} \ No newline at end of file