C# Class BusinessComponents.OperationsComponent

Show file Open project: constantcontact/constantcontact-csharp-tutor

Public Methods

Method Description
AddContactList ( CredentialsDetails credentialsDetail, string name, string &strRequest, string &strResponse ) : ContactListDetails

Method used for adding a new contact list to Constant Contact

Authentification ( CredentialsDetails credentialsDetail, string &strRequest, string &strResponse ) : void

Method used for trying to access the current user root document, if the credentials are fine then an xml response will be brought back else an exception will be thrown

DeleteContactList ( CredentialsDetails credentialsDetail, string listId, string &strRequest, string &strResponse ) : void

Method used for deleting an existing contact list

GetContactLists ( CredentialsDetails credentialsDetail, string &strRequest, string &strResponse ) : List

Gets the contact list collection for the current user

GetContacts ( CredentialsDetails credentialsDetail, string listId, string &strRequest, string &strResponse ) : List

Get the contacts for a given list along with some contact details

UpdateExistingContact ( CredentialsDetails credentialsDetails, ContactDetails contact, string &strRequest, string &strResponse ) : void

Method used for updating an existing contact

Private Methods

Method Description
CreateList ( string name ) : string

Creates the xml for adding a new list to Constant Contact

Method Details

AddContactList() public static method

Method used for adding a new contact list to Constant Contact
public static AddContactList ( CredentialsDetails credentialsDetail, string name, string &strRequest, string &strResponse ) : ContactListDetails
credentialsDetail BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
name string The name of the new contact list
strRequest string The request string representation
strResponse string The response string representation
return BusinessObjects.ContactListDetails

Authentification() public static method

Method used for trying to access the current user root document, if the credentials are fine then an xml response will be brought back else an exception will be thrown
public static Authentification ( CredentialsDetails credentialsDetail, string &strRequest, string &strResponse ) : void
credentialsDetail BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
strRequest string The request string representation
strResponse string The response string representation
return void

DeleteContactList() public static method

Method used for deleting an existing contact list
public static DeleteContactList ( CredentialsDetails credentialsDetail, string listId, string &strRequest, string &strResponse ) : void
credentialsDetail BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
listId string The id of the list to be deleted
strRequest string The request string representation
strResponse string The response string representation
return void

GetContactLists() public static method

Gets the contact list collection for the current user
public static GetContactLists ( CredentialsDetails credentialsDetail, string &strRequest, string &strResponse ) : List
credentialsDetail BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
strRequest string The request string representation
strResponse string The response string representation
return List

GetContacts() public static method

Get the contacts for a given list along with some contact details
public static GetContacts ( CredentialsDetails credentialsDetail, string listId, string &strRequest, string &strResponse ) : List
credentialsDetail BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
listId string The id of the list for witch the contacts will be brought
strRequest string The request string representation
strResponse string The response string representation
return List

UpdateExistingContact() public static method

Method used for updating an existing contact
public static UpdateExistingContact ( CredentialsDetails credentialsDetails, ContactDetails contact, string &strRequest, string &strResponse ) : void
credentialsDetails BusinessObjects.CredentialsDetails An object that encapsulates the Constant Contact credentials
contact BusinessObjects.ContactDetails The contact url
strRequest string The request string representation
strResponse string The response string representation
return void