ProfileRestClient class
الفئة الأساسية التي يجب استخدامها (مشتقة من) لتقديم طلبات إلى VSS REST apis
- يمتد
الخصائص
| RESOURCE_AREA_ID |
الأساليب
تفاصيل المنشئ
ProfileRestClient(IVssRestClientOptions)
تفاصيل الخاصية
RESOURCE_AREA_ID
static RESOURCE_AREA_ID: string
قيمة الخاصية
string
تفاصيل الأسلوب
createProfile(CreateProfileContext, boolean)
إنشاء ملف تعريف
function createProfile(createProfileContext: CreateProfileContext, autoCreate?: boolean): Promise<Profile>
المعلمات
- createProfileContext
- CreateProfileContext
سياق إنشاء ملف التعريف
- autoCreate
-
boolean
إنشاء ملف تعريف تلقائيا
المرتجعات
Promise<Profile>
deleteProfileAttribute(string, string)
function deleteProfileAttribute(id: string, descriptor: string): Promise<void>
المعلمات
- id
-
string
- descriptor
-
string
المرتجعات
Promise<void>
getAvatar(string, string, string)
function getAvatar(id: string, size?: string, format?: string): Promise<Avatar>
المعلمات
- id
-
string
- size
-
string
- format
-
string
المرتجعات
Promise<Avatar>
getAvatarPreview(any, string, string, string, string)
function getAvatarPreview(container: any, id: string, size?: string, format?: string, displayName?: string): Promise<Avatar>
المعلمات
- container
-
any
- id
-
string
- size
-
string
- format
-
string
- displayName
-
string
المرتجعات
Promise<Avatar>
getProfile(string, boolean, boolean, string, string, boolean)
الحصول على ملف تعريف المستخدم.
function getProfile(id: string, details?: boolean, withAttributes?: boolean, partition?: string, coreAttributes?: string, forceRefresh?: boolean): Promise<Profile>
المعلمات
- id
-
string
معرف ملف تعريف المستخدم الهدف داخل نفس المؤسسة، أو "أنا" للحصول على ملف تعريف المستخدم الحالي المصادق عليه.
- details
-
boolean
إرجاع معلومات ملف التعريف العام مثل اسم العرض وعنوان البريد الإلكتروني والبلد وما إلى ذلك. إذا كانت خاطئة، يتم تجاهل المعلمة withAttributes.
- withAttributes
-
boolean
إذا كان صحيحا، يحصل على السمات (أزواج قيم المفاتيح المسماة من البيانات العشوائية) المقترنة بملف التعريف. يجب أن تحتوي معلمة القسم أيضا على قيمة.
- partition
-
string
القسم (المجموعة المسماة) من السمات المراد إرجاعها.
- coreAttributes
-
string
قائمة محددة بفاصلة لسمات ملف التعريف الأساسي لإرجاعها. القيم الصالحة هي البريد الإلكتروني والأفاتار و DisplayName و ContactWithOffers.
- forceRefresh
-
boolean
غير مستخدم في هذا الإصدار من واجهة برمجة التطبيقات.
المرتجعات
Promise<Profile>
getProfileAttribute(string, string)
function getProfileAttribute(id: string, descriptor: string): Promise<ProfileAttribute>
المعلمات
- id
-
string
- descriptor
-
string
المرتجعات
Promise<ProfileAttribute>
getProfileAttributes(string, string, string, string, boolean, string)
function getProfileAttributes(id: string, partition: string, modifiedSince?: string, modifiedAfterRevision?: string, withCoreAttributes?: boolean, coreAttributes?: string): Promise<ProfileAttribute[]>
المعلمات
- id
-
string
- partition
-
string
- modifiedSince
-
string
- modifiedAfterRevision
-
string
- withCoreAttributes
-
boolean
- coreAttributes
-
string
المرتجعات
Promise<ProfileAttribute[]>
resetAvatar(string)
function resetAvatar(id: string): Promise<void>
المعلمات
- id
-
string
المرتجعات
Promise<void>
setAvatar(any, string)
function setAvatar(container: any, id: string): Promise<void>
المعلمات
- container
-
any
- id
-
string
المرتجعات
Promise<void>
setProfileAttribute(any, string, string)
function setProfileAttribute(container: any, id: string, descriptor: string): Promise<void>
المعلمات
- container
-
any
- id
-
string
- descriptor
-
string
المرتجعات
Promise<void>
setProfileAttributes(VssJsonCollectionWrapperV<ProfileAttributeBase<any>[]>, string)
function setProfileAttributes(attributesCollection: VssJsonCollectionWrapperV<ProfileAttributeBase<any>[]>, id: string): Promise<void>
المعلمات
- attributesCollection
- id
-
string
المرتجعات
Promise<void>
updateProfile(Profile, string)
تحديث ملف التعريف
function updateProfile(profile: Profile, id: string): Promise<void>
المعلمات
- profile
- Profile
تحديث ملف التعريف
- id
-
string
معرف ملف التعريف
المرتجعات
Promise<void>