Exemplo n.º 1
0
        public IEnumerable <Application> GetApplications()
        {
            var helper = new AppsHelper(proxyUser, credMgr);
            IEnumerable <Application> apps = helper.GetApplications();

            foreach (var app in apps) // TODO not thrilled about this
            {
                app.Parent = cloud;
                app.User   = proxyUser;
            }
            return(apps);
        }
Exemplo n.º 2
0
        public IEnumerable <Application> GetApplications()
        {
            checkLoginStatus();
            var hlpr = new AppsHelper(credMgr);
            IEnumerable <Application> apps = hlpr.GetApplications();

            foreach (var a in apps)
            {
                a.Parent = cloud;
            }                                             // TODO not thrilled about this
            return(apps);
        }
Exemplo n.º 3
0
        public VcapClientResult DeleteUser(string email)
        {
            var appsHelper = new AppsHelper(proxyUser, credMgr);
            foreach (Application a in appsHelper.GetApplications(email))
            {
                appsHelper.Delete(a.Name);
            }

            var servicesHelper = new ServicesHelper(proxyUser, credMgr);
            foreach (ProvisionedService ps in servicesHelper.GetProvisionedServices(email))
            {
                servicesHelper.DeleteService(ps.Name);
            }

            VcapJsonRequest r = base.BuildVcapJsonRequest(Method.DELETE, Constants.USERS_PATH, email);
            IRestResponse response = r.Execute();
            return new VcapClientResult();
        }
Exemplo n.º 4
0
        public void DeleteUser(string email)
        {
            // TODO: doing this causes a "not logged in" failure when the user
            // doesn't exist, which is kind of misleading.

            var appsHelper = new AppsHelper(proxyUser, credMgr);
            foreach (Application a in appsHelper.GetApplications(email))
            {
                appsHelper.Delete(a.Name);
            }

            var servicesHelper = new ServicesHelper(proxyUser, credMgr);
            foreach (ProvisionedService ps in servicesHelper.GetProvisionedServices())
            {
                servicesHelper.DeleteService(ps.Name);
            }

            VcapJsonRequest r = BuildVcapJsonRequest(Method.DELETE, Constants.USERS_PATH, email);
            r.Execute();
        }
Exemplo n.º 5
0
        public VcapClientResult DeleteUser(string email)
        {
            var appsHelper = new AppsHelper(credMgr);

            foreach (Application a in appsHelper.GetApplications(email))
            {
                appsHelper.Delete(a.Name);
            }

            var servicesHelper = new ServicesHelper(credMgr);

            foreach (ProvisionedService ps in servicesHelper.GetProvisionedServices(email))
            {
                servicesHelper.DeleteService(ps.Name);
            }

            var          r        = new VcapJsonRequest(credMgr, Method.DELETE, Constants.USERS_PATH, email);
            RestResponse response = r.Execute();

            return(new VcapClientResult());
        }
Exemplo n.º 6
0
        public void DeleteUser(string email)
        {
            // TODO: doing this causes a "not logged in" failure when the user
            // doesn't exist, which is kind of misleading.

            var appsHelper = new AppsHelper(proxyUser, credMgr);

            foreach (Application a in appsHelper.GetApplications(email))
            {
                appsHelper.Delete(a.Name);
            }

            var servicesHelper = new ServicesHelper(proxyUser, credMgr);

            foreach (ProvisionedService ps in servicesHelper.GetProvisionedServices())
            {
                servicesHelper.DeleteService(ps.Name);
            }

            VcapJsonRequest r = BuildVcapJsonRequest(Method.DELETE, Constants.USERS_PATH, email);

            r.Execute();
        }
Exemplo n.º 7
0
 public IEnumerable<Application> GetApplications()
 {
     CheckLoginStatus();
     var hlpr = new AppsHelper(proxyUser, credMgr);
     IEnumerable<Application> apps = hlpr.GetApplications();
     foreach (var app in apps) // TODO not thrilled about this
     {
         app.Parent = cloud;
         app.User = proxyUser;
     }
     return apps;
 }
Exemplo n.º 8
0
 public IEnumerable<Application> GetApplications()
 {
     checkLoginStatus();
     var hlpr = new AppsHelper(credMgr);
     IEnumerable<Application> apps = hlpr.GetApplications();
     foreach (var a in apps) { a.Parent = cloud; } // TODO not thrilled about this
     return apps;
 }