From 8620a4de6430ad8f2a69bba0b7f60bd2962e3c8f Mon Sep 17 00:00:00 2001 From: nero Date: Mon, 15 Jan 2024 16:06:01 +0900 Subject: [PATCH] =?UTF-8?q?DocumentMeta=E3=83=AA=E3=82=B9=E3=83=88?= =?UTF-8?q?=E3=82=92LibraryItemPage=E3=81=AB=E5=A4=89=E6=8F=9B=E3=81=99?= =?UTF-8?q?=E3=82=8B=E3=83=A6=E3=83=BC=E3=83=86=E3=82=A3=E3=83=AA=E3=83=86?= =?UTF-8?q?=E3=82=A3=E3=83=A1=E3=82=BD=E3=83=83=E3=83=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../feature/library/LibraryTopFragment.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/feature/library/src/main/java/one/nem/lacerta/feature/library/LibraryTopFragment.java b/feature/library/src/main/java/one/nem/lacerta/feature/library/LibraryTopFragment.java index 563181fe..4328c293 100644 --- a/feature/library/src/main/java/one/nem/lacerta/feature/library/LibraryTopFragment.java +++ b/feature/library/src/main/java/one/nem/lacerta/feature/library/LibraryTopFragment.java @@ -124,4 +124,19 @@ public class LibraryTopFragment extends Fragment { // Use a LinearLayoutManager to specify the layout return view; } + // DocumentMetaリストをLibraryItemPageに変換するユーティリティメソッド + private ArrayList convertToLibraryItems(List metas) { + ArrayList libraryItems = new ArrayList<>(); + for (DocumentMeta meta : metas) { + // ListItemの作成と設定 + ListItem listItem = new ListItem(); + listItem.setTitle(meta.getTitle()); + listItem.setDescription(meta.getTitle()); + // 他の必要な情報もListItemに設定する + + // ListItemをリストに追加 + libraryItems.add(listItem); + } + return libraryItems; + } }