ContactGroupServices.BeginAddContact Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
BeginAddContact(String, AsyncCallback, Object) |
Begins an asynchronous operation to add a contact. |
BeginAddContact(String, ContactAddOptions, AsyncCallback, Object) |
Begins an asynchronous operation to add a contact. |
BeginAddContact(String, String, Boolean, String, String, Int32[], AsyncCallback, Object) |
Obsolete.
Begins an asynchronous operation to add a contact. |
BeginAddContact(String, AsyncCallback, Object)
Begins an asynchronous operation to add a contact.
public:
IAsyncResult ^ BeginAddContact(System::String ^ contactUri, AsyncCallback ^ userCallback, System::Object ^ state);
public IAsyncResult BeginAddContact (string contactUri, AsyncCallback userCallback, object state);
member this.BeginAddContact : string * AsyncCallback * obj -> IAsyncResult
Public Function BeginAddContact (contactUri As String, userCallback As AsyncCallback, state As Object) As IAsyncResult
Parameters
- contactUri
- String
URI of the contact being added.
- userCallback
- AsyncCallback
The method to be called when the asynchronous operation is completed.
- state
- Object
A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.
Returns
An IAsyncResult that references the asynchronous operation.
Exceptions
Thrown when the subscription state is not idle or subscribed.
Thrown when contactUri
is an invalid sip URI.
Applies to
BeginAddContact(String, ContactAddOptions, AsyncCallback, Object)
Begins an asynchronous operation to add a contact.
public:
IAsyncResult ^ BeginAddContact(System::String ^ contactUri, Microsoft::Rtc::Collaboration::ContactsGroups::ContactAddOptions ^ options, AsyncCallback ^ userCallback, System::Object ^ state);
public IAsyncResult BeginAddContact (string contactUri, Microsoft.Rtc.Collaboration.ContactsGroups.ContactAddOptions options, AsyncCallback userCallback, object state);
member this.BeginAddContact : string * Microsoft.Rtc.Collaboration.ContactsGroups.ContactAddOptions * AsyncCallback * obj -> IAsyncResult
Public Function BeginAddContact (contactUri As String, options As ContactAddOptions, userCallback As AsyncCallback, state As Object) As IAsyncResult
Parameters
- contactUri
- String
URI of the contact being added.
- options
- ContactAddOptions
Optional parameters when creating a contact.
- userCallback
- AsyncCallback
The method to be called when the asynchronous operation is completed.
- state
- Object
A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.
Returns
An IAsyncResult that references the asynchronous operation.
Exceptions
Thrown when the subscription state is not idle or subscribed.
Thrown when contactUri
is an invalid sip URI.
Thrown when options
are null.
Thrown when any of options.GroupIds is negative.
Remarks
If the endpoint is operating in privacy mode then an Access Control Entry will automatically be added to the endpoint owner's Access Control lists or containers. The notifications if this operation is successful can be obtained by wiring ContainerNotificationReceived.
Applies to
BeginAddContact(String, String, Boolean, String, String, Int32[], AsyncCallback, Object)
Caution
This method will be removed from future Versions. Please use BeginAddContact(contactUri, options, userCallback, state) instead.
Begins an asynchronous operation to add a contact.
public:
IAsyncResult ^ BeginAddContact(System::String ^ contactUri, System::String ^ contactName, bool isSubscribed, System::String ^ contactData, System::String ^ contactExtension, cli::array <int> ^ groupIds, AsyncCallback ^ userCallback, System::Object ^ state);
[System.Obsolete("This method will be removed from future Versions. Please use BeginAddContact(contactUri, options, userCallback, state) instead.")]
public IAsyncResult BeginAddContact (string contactUri, string contactName, bool isSubscribed, string contactData, string contactExtension, int[] groupIds, AsyncCallback userCallback, object state);
member this.BeginAddContact : string * string * bool * string * string * int[] * AsyncCallback * obj -> IAsyncResult
Public Function BeginAddContact (contactUri As String, contactName As String, isSubscribed As Boolean, contactData As String, contactExtension As String, groupIds As Integer(), userCallback As AsyncCallback, state As Object) As IAsyncResult
Parameters
- contactUri
- String
URI of the contact being added.
- contactName
- String
Name of the contact being added.
- isSubscribed
- Boolean
True, if this contact also needs to be subscribed.
- contactData
- String
ContactData.
- contactExtension
- String
ContactExtension data needs to be published with this contact.
- groupIds
- Int32[]
List of GroupIds where this contact would be added.
- userCallback
- AsyncCallback
The method to be called when the asynchronous operation is completed.
- state
- Object
A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.
Returns
An IAsyncResult that references the asynchronous operation.
- Attributes
Exceptions
Thrown when any of the groupIds
are less than zero.
Thrown when the subscription state is not idle or subscribed.
Thrown when contactUri
is an invalid sip URI.
Thrown when contactName
or contactData
are null.