All Downloads are FREE. Search and download functionalities are using the official Maven repository.

pl.allegro.tech.hermes.domain.topic.preview.MessagePreview Maven / Gradle / Ivy

There is a newer version: 2.6.21
Show newest version
package pl.allegro.tech.hermes.domain.topic.preview;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;

public class MessagePreview {

    private final byte[] content;

    private final boolean truncated;

    @JsonCreator
    public MessagePreview(@JsonProperty("content") byte[] content, @JsonProperty("truncated") boolean truncated) {
        this.content = content;
        this.truncated = truncated;
    }

    public MessagePreview(byte[] content) {
        this(content, false);
    }

    public byte[] getContent() {
        return content;
    }

    public boolean isTruncated() {
        return truncated;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy