Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User関係の型をUserLiteとUserDetailedに整理 #25

Merged
merged 2 commits into from
Jan 27, 2024

Conversation

poppingmoon
Copy link
Contributor

@poppingmoon poppingmoon commented Oct 15, 2023

Userに関するクラスが User, UsersShowResponse, IResponse に重複して存在していることによって、同じ名前のフィールドが一方では String, 他方では Enum として定義されるといったことを解消し、予防するために整理しました

  • 以前の UserUserLite になりました
  • 以前の UsersShowResponseIResponseUserDetailed になりました
    • UserDetailed は 3つのクラスに実装されています
      • UserDetailedNotMe はログインせずに他者に対して users/show を呼んだときの返り値を表しています
      • UserDetailedNotMeWithRelations はログインして他者に対して users/show を呼んだときの返り値を表しています
      • MeDetailedi や自分に対して users/show を呼んだときの返り値を表しています
    • UserDetailed.toJsonUserDetailed を実装したクラスを与えられたMapのキーに応じて返します
  • UserLiteUserDetailedUser を実装しています
    • User.toJsonUser を実装したクラスを与えられたMapのキーに応じて返します
  • Misskey 2023.10.1までの変更等で追加されたフィールドなどの追加は行っていません
  • 関連するメソッドの返り値の型を適切なものに変更しました

poppingmoon added a commit to poppingmoon/miria that referenced this pull request Oct 15, 2023
@poppingmoon poppingmoon force-pushed the user branch 4 times, most recently from 40b5d71 to 20d8572 Compare October 16, 2023 16:02
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Oct 16, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Oct 19, 2023
@poppingmoon poppingmoon force-pushed the user branch 8 times, most recently from 8bcd03a to ff5d367 Compare October 20, 2023 23:23
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Oct 21, 2023
@poppingmoon poppingmoon force-pushed the user branch 2 times, most recently from 21daa77 to 0e76da0 Compare October 30, 2023 20:03
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Oct 30, 2023
@poppingmoon poppingmoon force-pushed the user branch 2 times, most recently from dcab24b to 5f4ca5b Compare November 4, 2023 07:28
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 4, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 4, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 4, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 7, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 11, 2023
@poppingmoon poppingmoon force-pushed the user branch 2 times, most recently from 8c8cc32 to 9295a71 Compare November 20, 2023 17:33
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 24, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Nov 26, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 3, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 4, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 17, 2023
@poppingmoon poppingmoon force-pushed the user branch 3 times, most recently from 0f7117c to ec5aebf Compare December 19, 2023 11:21
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 19, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 22, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 22, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Dec 24, 2023
poppingmoon added a commit to poppingmoon/miria that referenced this pull request Jan 21, 2024
@shiosyakeyakini-info shiosyakeyakini-info merged commit d91ad3b into shiosyakeyakini-info:master Jan 27, 2024
3 checks passed
@poppingmoon poppingmoon deleted the user branch January 27, 2024 23:16
@shiosyakeyakini-info
Copy link
Owner

マージしました!ありがとうございます

poppingmoon added a commit to poppingmoon/miria that referenced this pull request Jan 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants