Example #1
0
 /// <summary>
 /// Add the reference to the service manager to the logged service list.
 /// </summary>
 /// <param name="serviceId">the service id</param>
 /// <param name="service">the service manager</param>
 public void AddLoggedService(int serviceId, Auth.ILoginService service)
 {
     try
     {
         _loggedServices.Add(serviceId, service);
     }
     catch (Exception) { }
 }
Example #2
0
 /// <summary>
 /// Retrieve all contacts from a service.
 /// </summary>
 /// <param name="serviceId">the service id</param>
 /// <returns>a list of contacts</returns>
 public List <Contact> ImportContacts(int serviceId)
 {
     if (!_registered)
     {
         return(null);
     }
     Auth.ILoginService serv = null;
     try
     {
         serv = _loggedServices[serviceId];
     }
     catch (Exception) { return(null); }
     if (serv == null)
     {
         return(new List <Contact>());
     }
     return(serv.getContactList());
 }