Package com.microsoft.tfs.core

Examples of com.microsoft.tfs.core.TFSTeamProjectCollection


                e.printStackTrace();
            }

            ConnectionAdvisor advisor = new DefaultConnectionAdvisor(Locale.getDefault(), TimeZone.getDefault());

            TFSTeamProjectCollection projects = new TFSTeamProjectCollection(uri, credentials, advisor);
            addProxy(projects.getHTTPClient());

            try {
                client = projects.getWorkItemClient();
                lastStatus = client == null ? ConnectionStatus.INVALID : ConnectionStatus.VALID;
            } catch (UnauthorizedException | TFSUnauthorizedException e) {
                LOG.warn("TFSUnauthorizedException encountered, unable to connect to TFS. " +
                        "Check credentials and endpoint.");
            }
View Full Code Here


        } catch (URISyntaxException e) {
            LOG.warn("Invalid syntax for the URL.",e);
            return ConnectionStatus.INVALID;
        }

        TFSTeamProjectCollection projects = new TFSTeamProjectCollection(uri,
                credentials);

        addProxy(projects.getHTTPClient());

        try {
            projects.getWorkItemClient().getProjects();
            //projects.getWorkItemClient();
            LOG.info("No UnauthorizedException was thrown when attempting to connect with blank credentials.");
            return ConnectionStatus.VALID;
        } catch (UnauthorizedException | TFSUnauthorizedException e) {
            LOG.info("Got an UnauthorizedException, which means that the TFS url was good.");
View Full Code Here

TOP

Related Classes of com.microsoft.tfs.core.TFSTeamProjectCollection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.