-
-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fetch user profile card (OpenShamrock)
- Loading branch information
Showing
5 changed files
with
124 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
onebot/src/main/java/cn/evole/onebot/sdk/response/misc/UserInfoResp.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
package cn.evole.onebot.sdk.response.misc; | ||
|
||
import com.google.gson.annotations.SerializedName; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* Created on 2022/12/6. | ||
* | ||
* @author MrXiaoM | ||
*/ | ||
@Data | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
public class UserInfoResp { | ||
|
||
@SerializedName("user_id") | ||
long uin; | ||
@SerializedName("user_name") | ||
String name; | ||
@SerializedName("user_displayname") | ||
String displayName; | ||
@SerializedName("user_remark") | ||
String remark; | ||
@SerializedName("mail") | ||
String mail; | ||
@SerializedName("find_method") | ||
String findMethod; | ||
@SerializedName("max_vote_cnt") | ||
short maxVoteCnt; | ||
@SerializedName("have_vote_cnt") | ||
short haveVoteCnt; | ||
@SerializedName("vip_list") | ||
List<VipInfo> vipList; | ||
@SerializedName("hobby_entry") | ||
String hobbyEntry; | ||
@SerializedName("level") | ||
int level; | ||
@SerializedName("birthday") | ||
long birthday; | ||
@SerializedName("login_day") | ||
long loginDay; | ||
@SerializedName("vote_cnt") | ||
long voteCnt; | ||
@SerializedName("qid") | ||
String qid; | ||
@SerializedName("is_school_verified") | ||
Boolean schoolVerified; | ||
@SerializedName("location") | ||
Location location; | ||
@SerializedName("cookie") | ||
byte[] cookie; | ||
@Data | ||
public static class VipInfo { | ||
/** | ||
* QQ_VIP, | ||
* SUPER_QQ, | ||
* SUPER_VIP, | ||
* QQ_VIDEO, | ||
* QQ_READING, | ||
* BIG_VIP, | ||
* YELLOW_VIP | ||
*/ | ||
String type; | ||
int level; | ||
@SerializedName("vip_type") | ||
int vipType; | ||
@SerializedName("template_id") | ||
long templateId; | ||
} | ||
@Data | ||
public static class Location { | ||
String city; | ||
String company; | ||
String country; | ||
String province; | ||
String hometown; | ||
String school; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
overflow-core/src/main/kotlin/top/mrxiaom/overflow/internal/data/UserProfileImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package top.mrxiaom.overflow.internal.data | ||
|
||
import net.mamoe.mirai.data.UserProfile | ||
|
||
class UserProfileImpl( | ||
override val age: Int, | ||
override val email: String, | ||
override val friendGroupId: Int, | ||
override val nickname: String, | ||
override val qLevel: Int, | ||
override val sex: UserProfile.Sex, | ||
override val sign: String | ||
) : UserProfile |