UserIdentity Class

Contiene el id., los vales y demás información asociada a un usuario.

Sintaxis


Public NotInheritable Class UserIdentity

Atributos

[MarshalingBehavior(Agile)]
[Version(0x06020000)]

Miembros

UserIdentityClase tiene estos tipos de miembros:

Métodos

The UserIdentity Clase hereda métodos de Object Clase (C#/VB/C++).

Propiedades

UserIdentityClase tiene estas propiedades.

PropiedadTipo de accesoDescripción

FirstName

Solo lecturaContains the first name of the user. This value is available only to Microsoft application partners.

Id

Solo lecturaGets the user's unique Microsoft account identifier. This value is available only to Microsoft application partners.

IsBetaAccount

Solo lecturaIndicates if the user is part of a beta program. This value is available only to Microsoft application partners.

IsConfirmedPC

Solo lecturaIndicates if the user is on a PC that they have confirmed as their PC. This value is available only to Microsoft application partners.

LastName

Solo lecturaContains the user's last name. This value is available only to Microsoft application partners.

SafeCustomerId

Solo lecturaGets an obfuscated customer ID specific to the calling application.

SignInName

Solo lecturaThe sign in name of the user. This value is available only to Microsoft application partners.

Tickets

Solo lecturaContains an array of tickets that identify the user

 

Ejemplos


List<OnlineIdServiceTicketRequest> targetArray = new List<OnlineIdServiceTicketRequest>();
targetArray.Add(new OnlineIdServiceTicketRequest("wl.basic wl.contacts_photos wl.calendars",
        "DELEGATION"));

DebugPrint("Signing in ...");

Windows.Security.Authentication.OnlineId.UserIdentity result = 
        await _authenticator.AuthenticateUserAsync(targetArray, CredentialPromptType.PromptIfNeeded);

if (result.Tickets[0].Value != string.Empty)
{
    DebugPrint("Signed in.");
    IsNotSignedIn = false;
}
else
{
    // Handle errors like bad parameter, misconfigured target, and so on.
    DebugPrint("Unable to get the ticket. Error: " + result.Tickets[0].ErrorCode.ToString());
    IsNotSignedIn = true;
}

Requisitos

Cliente mínimo compatible

Windows 8 [Solo aplicaciones de la Tienda Windows]

Servidor mínimo compatible

Windows Server 2012 [Solo aplicaciones de la Tienda Windows]

Teléfono mínimo compatible

Windows Phone 8

Espacio de nombres

Windows.Security.Authentication.OnlineId
Windows::Security::Authentication::OnlineId [C++]

Metadatos

Windows.winmd

 

 

Mostrar:
© 2015 Microsoft