org.incode.module.minio.docclient.archive.ArchiveArgs Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of incode-module-minio-docclient Show documentation
Show all versions of incode-module-minio-docclient Show documentation
Facade for accessing Document Server (the Apache Isis application)
The newest version!
package org.incode.module.minio.docclient.archive;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.ObjectWriter;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
@NoArgsConstructor
@AllArgsConstructor
public class ArchiveArgs {
private static final ObjectWriter writer;
static {
final ObjectMapper mapper = new ObjectMapper();
writer = mapper.writer().withDefaultPrettyPrinter();
}
@Getter @Setter
StringValue docBookmark;
@Getter @Setter
StringValue externalUrl;
public String asJson() {
try {
return writer.writeValueAsString(this);
} catch (JsonProcessingException e) {
throw new RuntimeException(e);
}
}
@Override
public String toString() {
return "ArchiveArgs{" +
"docBookmark=" + docBookmark +
", externalUrl=" + externalUrl +
'}';
}
}