@fruitsjs/core
Version:
Principal package with functions and models for building Fruits Eco-Blockchain applications.
27 lines • 934 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.AttachmentEncryptedMessage = exports.AttachmentMessage = exports.Attachment = void 0;
class Attachment {
constructor(type) {
this.type = type;
}
}
exports.Attachment = Attachment;
class AttachmentMessage extends Attachment {
constructor(data = {}) {
super('message');
this.messageIsText = data.messageIsText || false;
this.message = data.message || undefined;
}
}
exports.AttachmentMessage = AttachmentMessage;
class AttachmentEncryptedMessage extends Attachment {
constructor(data = {}) {
super('encrypted_message');
this.data = data.data || undefined;
this.nonce = data.nonce || undefined;
this.isText = data.isText || false;
}
}
exports.AttachmentEncryptedMessage = AttachmentEncryptedMessage;
//# sourceMappingURL=attachment.js.map