ข้อมูลผู้ใช้
public final class UserInfo
extends Object
java.lang.Object | |
เ | com.android.tradefed.device.UserInfo |
คล้ายกับคลาส UserInfo จากแพลตฟอร์ม
นี้มีวัตถุประสงค์เพื่อให้คล้ายกับ android.content.pm.UserInfo
เก็บข้อมูลและตรรกะพื้นฐานรอบๆ ข้อมูลสำหรับผู้ใช้หนึ่งราย
สรุป
คลาสที่ซ้อนกัน | |
---|---|
enum | UserInfo.UserType ตัวแปรประเภทผู้ใช้ที่รองรับใน API ภายนอก |
ค่าคงที่ | |
---|---|
int | FLAGS_NOT_SECONDARY |
int | FLAG_EPHEMERAL |
int | FLAG_GUEST |
int | FLAG_MANAGED_PROFILE |
int | FLAG_PRIMARY |
int | FLAG_RESTRICTED |
int | USER_SYSTEM
|
ผู้สร้างสาธารณะ | |
---|---|
UserInfo (int userId, String userName, int flag, boolean isRunning) |
วิธีการสาธารณะ | |
---|---|
int | flag () |
boolean | isEphemeral () |
boolean | isGuest () |
boolean | isManagedProfile () |
boolean | isPrimary () |
boolean | isRunning () |
boolean | isSecondary () |
boolean | isSystem () |
boolean | isUserType ( UserInfo.UserType userType, int currentUserId) ส่งคืนว่าอินสแตนซ์นี้เป็นประเภทที่ระบุหรือไม่ |
int | userId () |
String | userName () |
ค่าคงที่
FLAGS_NOT_SECONDARY
public static final int FLAGS_NOT_SECONDARY
ค่าคงที่: 45 (0x0000002d)
FLAG_EPHEMERAL
public static final int FLAG_EPHEMERAL
ค่าคงที่: 256 (0x000000100)
FLAG_GUEST
public static final int FLAG_GUEST
ค่าคงที่: 4 (0x00000004)
FLAG_MANAGED_PROFILE
public static final int FLAG_MANAGED_PROFILE
ค่าคงที่: 32 (0x00000020)
FLAG_PRIMARY
public static final int FLAG_PRIMARY
ค่าคงที่: 1 (0x00000001)
FLAG_RESTRICTED
public static final int FLAG_RESTRICTED
ค่าคงที่: 8 (0x00000008)
USER_SYSTEM
public static final int USER_SYSTEM
ค่าคงที่: 0 (0x00000000)
ผู้สร้างสาธารณะ
ข้อมูลผู้ใช้
public UserInfo (int userId, String userName, int flag, boolean isRunning)
พารามิเตอร์ | |
---|---|
userId | int |
userName | String |
flag | int |
isRunning | boolean |
วิธีการสาธารณะ
ธง
public int flag ()
คืนสินค้า | |
---|---|
int |
เป็นชั่วคราว
public boolean isEphemeral ()
คืนสินค้า | |
---|---|
boolean |
isGuest
public boolean isGuest ()
คืนสินค้า | |
---|---|
boolean |
isManagedProfile
public boolean isManagedProfile ()
คืนสินค้า | |
---|---|
boolean |
เป็นประถม
public boolean isPrimary ()
คืนสินค้า | |
---|---|
boolean |
กำลังวิ่ง
public boolean isRunning ()
คืนสินค้า | |
---|---|
boolean |
เป็นรอง
public boolean isSecondary ()
คืนสินค้า | |
---|---|
boolean |
isSystem
public boolean isSystem ()
คืนสินค้า | |
---|---|
boolean |
isUserType
public boolean isUserType (UserInfo.UserType userType, int currentUserId)
ส่งคืนว่าอินสแตนซ์นี้เป็นประเภทที่ระบุหรือไม่
พารามิเตอร์ | |
---|---|
userType | UserInfo.UserType |
currentUserId | int |
คืนสินค้า | |
---|---|
boolean |
รหัสผู้ใช้
public int userId ()
คืนสินค้า | |
---|---|
int |
ชื่อผู้ใช้
public String userName ()
คืนสินค้า | |
---|---|
String |
ตัวอย่างเนื้อหาและโค้ดในหน้าเว็บนี้ขึ้นอยู่กับใบอนุญาตที่อธิบายไว้ในใบอนุญาตการใช้เนื้อหา Java และ OpenJDK เป็นเครื่องหมายการค้าหรือเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2022-08-15 UTC
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"ไม่มีข้อมูลที่ฉันต้องการ"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"ซับซ้อนเกินไป/มีหลายขั้นตอนมากเกินไป"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"ล้าสมัย"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"ปัญหาเกี่ยวกับการแปล"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"ตัวอย่าง/ปัญหาเกี่ยวกับโค้ด"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"อื่นๆ"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"เข้าใจง่าย"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"แก้ปัญหาของฉันได้"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"อื่นๆ"
}]