From 86b9e3ff3e9e8213fe5147cfe974034e48744091 Mon Sep 17 00:00:00 2001 From: r-ca Date: Sat, 16 Dec 2023 16:48:58 +0900 Subject: [PATCH] =?UTF-8?q?=E3=82=BF=E3=82=A4=E3=83=88=E3=83=AB=E3=81=8B?= =?UTF-8?q?=E3=82=89DocumentMeta=E3=82=92=E3=81=A4=E3=81=8F=E3=82=8C?= =?UTF-8?q?=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/one/nem/lacerta/model/document/DocumentMeta.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/model/src/main/java/one/nem/lacerta/model/document/DocumentMeta.java b/model/src/main/java/one/nem/lacerta/model/document/DocumentMeta.java index 11411c49..aa2bcb97 100644 --- a/model/src/main/java/one/nem/lacerta/model/document/DocumentMeta.java +++ b/model/src/main/java/one/nem/lacerta/model/document/DocumentMeta.java @@ -4,6 +4,7 @@ import java.util.ArrayList; import one.nem.lacerta.model.document.tag.DocumentTag; import java.util.Date; import java.util.List; +import java.util.UUID; /** * ドキュメントのメタデータ @@ -59,6 +60,11 @@ public class DocumentMeta { this.title = title; } + public DocumentMeta(String title) { // title only + this.id = UUID.randomUUID().toString(); // 新規作成時想定なのでコンストラクタで生成してしまう(使う人が楽なので) + this.title = title; + } + // Getter /**