PeerCollaboration.SignIn(PeerScope) メソッド

定義

指定された PeerScope でコラボレーション インフラストラクチャへのピアに署名します。

public:
 static void SignIn(System::Net::PeerToPeer::Collaboration::PeerScope peerScope);
[System.Security.SecurityCritical]
public static void SignIn (System.Net.PeerToPeer.Collaboration.PeerScope peerScope);
[<System.Security.SecurityCritical>]
static member SignIn : System.Net.PeerToPeer.Collaboration.PeerScope -> unit
Public Shared Sub SignIn (peerScope As PeerScope)

パラメーター

peerScope
PeerScope

PeerCollaboration アクティビティを結合するためにピアが使用しているスコープ。

属性

例外

peerScopeNone に設定されます。

peerScope パラメーターに正しくない列挙値が含まれています。

SignIn(PeerScope) 操作を完了できませんでした。

次のコード例は、コラボレーション インフラストラクチャにユーザーをサインインさせる方法を示しています。

//This function signs the users into the Collaboration Infrastructure.
public static bool PeerCollabSignin()
{
    bool result = false;
    try
    {
        PeerCollaboration.SignIn(PeerScope.All);
        result = true;
    }
    catch(Exception ex)
    {
        Console.WriteLine("Error signing in: {0}", ex.Message);
    }
    return result;
}

注釈

表示名は必ずしも一意ではありません。 ユーザーは、コラボレーションの招待を受け入れる前に、電子メール、電話、または人による表示名を使用して、ユーザーの ID を確認する必要があります。

この関数は、ユーザーをコラボレーション インフラストラクチャにサインインします。

このメソッドにアクセスするには、 の UnrestrictedPermissionState必要です。 この状態は、コラボレーション セッションの開始時に Peer 作成されます。

適用対象

こちらもご覧ください