Examples of CloudSpacesDescriptor


Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

   * @return the first space available that has no corresponding server
   * instance. If null, no space found that is not already associated with a
   * server instance.
   */
  public CloudSpace getSpaceWithNoServerInstance() {
    CloudSpacesDescriptor descriptor = getCurrentSpacesDescriptor();
    CloudOrgsAndSpaces orgsSpaces = descriptor != null ? descriptor.getOrgsAndSpaces() : null;

    if (orgsSpaces != null) {

      List<CloudFoundryServer> cloudServers = CloudServerUtil.getCloudServers();
      if (cloudServers == null || cloudServers.isEmpty()) {
View Full Code Here

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

   * credentials and URL in the server, are invalid, or failed to retrieve
   * list of spaces
   */
  public CloudSpacesDescriptor resolveDescriptor(String urlText, String userName, String password, boolean selfSigned,
      IRunnableContext context, boolean updateDescriptor) throws CoreException {
    CloudSpacesDescriptor descriptor = null;
    if (updateDescriptor) {
      descriptor = internalUpdateDescriptor(urlText, userName, password, selfSigned, context);
    }

    IStatus status = validateCurrent(getCurrentCloudSpace());
View Full Code Here

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

    if (spacesDescriptor == null) {
      CloudOrgsAndSpaces orgsAndSpaces = CloudUiUtil.getCloudSpaces(userName, password, actualURL, true,
          selfSigned, context);

      if (orgsAndSpaces != null) {
        spacesDescriptor = new CloudSpacesDescriptor(orgsAndSpaces, userName, password, actualURL);
        cachedDescriptors.put(cachedDescriptorID, spacesDescriptor);
      }
    }

    return spacesDescriptor;
View Full Code Here

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

  }

  protected IStatus validateCurrent(CloudSpace currentSpace) {
    int severity = IStatus.OK;
    String validationMessage = Messages.VALID_ACCOUNT;
    CloudSpacesDescriptor descriptor = getCurrentSpacesDescriptor();
    if (descriptor == null || descriptor.getOrgsAndSpaces() == null) {
      validationMessage = Messages.ERROR_CHECK_CONNECTION_NO_SPACES;
      severity = IStatus.ERROR;
    }
    else if (getSpaceWithNoServerInstance() == null) {
      validationMessage = Messages.ERROR_ALL_SPACES_ASSOCIATED_SERVER_INSTANCES;
View Full Code Here

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

    super(cloudServer);
  }

  protected CloudSpacesDescriptor internalUpdateDescriptor(String urlText, String userName, String password,
      boolean selfSigned, IRunnableContext context) throws CoreException {
    CloudSpacesDescriptor spacesDescriptor = super.internalUpdateDescriptor(urlText, userName, password,
        selfSigned, context);
    internalDescriptorChanged();

    return spacesDescriptor;
View Full Code Here

Examples of org.cloudfoundry.ide.eclipse.server.core.internal.spaces.CloudSpacesDescriptor

    public void dispose() {
    }

    public Object[] getChildren(Object parentElement) {
      if (parentElement instanceof CloudOrganization && cloudSpaceServerDelegate != null) {
        CloudSpacesDescriptor spaceDescriptor = cloudSpaceServerDelegate.getCurrentSpacesDescriptor();
        if (spaceDescriptor != null) {
          List<CloudSpace> spaces = spaceDescriptor.getOrgsAndSpaces().getOrgSpaces(
              ((CloudOrganization) parentElement).getName());
          if (spaces != null) {
            return spaces.toArray(new CloudSpace[spaces.size()]);
          }
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.