/** * <p> * A <code>Source</code> object that specifies the app repository. * </p> * * @param appSource * A <code>Source</code> object that specifies the app repository. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateAppRequest withAppSource(Source appSource) { setAppSource(appSource); return this; }
/** * <p> * An <code>SslConfiguration</code> object with the SSL configuration. * </p> * * @param sslConfiguration * An <code>SslConfiguration</code> object with the SSL configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateAppRequest withSslConfiguration(SslConfiguration sslConfiguration) { setSslConfiguration(sslConfiguration); return this; }
/** * <p> * The app type. * </p> * * @param type * The app type. * @see AppType */ public void setType(AppType type) { withType(type); }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAppId() == null) ? 0 : getAppId().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getDataSources() == null) ? 0 : getDataSources().hashCode()); hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getAppSource() == null) ? 0 : getAppSource().hashCode()); hashCode = prime * hashCode + ((getDomains() == null) ? 0 : getDomains().hashCode()); hashCode = prime * hashCode + ((getEnableSsl() == null) ? 0 : getEnableSsl().hashCode()); hashCode = prime * hashCode + ((getSslConfiguration() == null) ? 0 : getSslConfiguration().hashCode()); hashCode = prime * hashCode + ((getAttributes() == null) ? 0 : getAttributes().hashCode()); hashCode = prime * hashCode + ((getEnvironment() == null) ? 0 : getEnvironment().hashCode()); return hashCode; }
public void execute() { checkParams(); AWSOpsWorksClient client = getOrCreateClient(AWSOpsWorksClient.class); UpdateAppRequest updateAppRequest = new UpdateAppRequest() .withName(name).withType(type).withEnableSsl(enableSsl) .withAppId(appId).withDescription(description) .withDataSources(dataSources).withDomains(domains) .withAttributes(attributes); if (repoType != null && repoUrl != null) { Source appSource = new Source().withType(repoType).withUrl(repoUrl) .withSshKey(repoSshKey).withRevision(repoRevision) .withPassword(repoPassword).withUsername(repoUsername); updateAppRequest.setAppSource(appSource); .withCertificate(sslCertificate).withChain(sslChain) .withPrivateKey(sslPrivateKey); updateAppRequest.setSslConfiguration(sslConfiguration);
return false; UpdateAppRequest other = (UpdateAppRequest) obj; if (other.getAppId() == null ^ this.getAppId() == null) return false; if (other.getAppId() != null && other.getAppId().equals(this.getAppId()) == false) return false; if (other.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getDataSources() == null ^ this.getDataSources() == null) return false; if (other.getDataSources() != null && other.getDataSources().equals(this.getDataSources()) == false) return false; if (other.getType() == null ^ this.getType() == null) return false; if (other.getType() != null && other.getType().equals(this.getType()) == false) return false; if (other.getAppSource() == null ^ this.getAppSource() == null) return false; if (other.getAppSource() != null && other.getAppSource().equals(this.getAppSource()) == false) return false; if (other.getDomains() == null ^ this.getDomains() == null) return false; if (other.getDomains() != null && other.getDomains().equals(this.getDomains()) == false)
StringBuilder sb = new StringBuilder(); sb.append("{"); if (getAppId() != null) sb.append("AppId: ").append(getAppId()).append(","); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getDataSources() != null) sb.append("DataSources: ").append(getDataSources()).append(","); if (getType() != null) sb.append("Type: ").append(getType()).append(","); if (getAppSource() != null) sb.append("AppSource: ").append(getAppSource()).append(","); if (getDomains() != null) sb.append("Domains: ").append(getDomains()).append(","); if (getEnableSsl() != null) sb.append("EnableSsl: ").append(getEnableSsl()).append(","); if (getSslConfiguration() != null) sb.append("SslConfiguration: ").append(getSslConfiguration()).append(","); if (getAttributes() != null) sb.append("Attributes: ").append(getAttributes()).append(","); if (getEnvironment() != null) sb.append("Environment: ").append(getEnvironment()); sb.append("}"); return sb.toString();
/** * <p> * The app type. * </p> * * @param type * The app type. * @see AppType */ public void setType(AppType type) { withType(type); }
/** * <p> * A <code>Source</code> object that specifies the app repository. * </p> * * @param appSource * A <code>Source</code> object that specifies the app repository. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateAppRequest withAppSource(Source appSource) { setAppSource(appSource); return this; }
/** * <p> * An <code>SslConfiguration</code> object with the SSL configuration. * </p> * * @param sslConfiguration * An <code>SslConfiguration</code> object with the SSL configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateAppRequest withSslConfiguration(SslConfiguration sslConfiguration) { setSslConfiguration(sslConfiguration); return this; }
/** * Marshall the given parameter object. */ public void marshall(UpdateAppRequest updateAppRequest, ProtocolMarshaller protocolMarshaller) { if (updateAppRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(updateAppRequest.getAppId(), APPID_BINDING); protocolMarshaller.marshall(updateAppRequest.getName(), NAME_BINDING); protocolMarshaller.marshall(updateAppRequest.getDescription(), DESCRIPTION_BINDING); protocolMarshaller.marshall(updateAppRequest.getDataSources(), DATASOURCES_BINDING); protocolMarshaller.marshall(updateAppRequest.getType(), TYPE_BINDING); protocolMarshaller.marshall(updateAppRequest.getAppSource(), APPSOURCE_BINDING); protocolMarshaller.marshall(updateAppRequest.getDomains(), DOMAINS_BINDING); protocolMarshaller.marshall(updateAppRequest.getEnableSsl(), ENABLESSL_BINDING); protocolMarshaller.marshall(updateAppRequest.getSslConfiguration(), SSLCONFIGURATION_BINDING); protocolMarshaller.marshall(updateAppRequest.getAttributes(), ATTRIBUTES_BINDING); protocolMarshaller.marshall(updateAppRequest.getEnvironment(), ENVIRONMENT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAppId() == null) ? 0 : getAppId().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getDataSources() == null) ? 0 : getDataSources().hashCode()); hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getAppSource() == null) ? 0 : getAppSource().hashCode()); hashCode = prime * hashCode + ((getDomains() == null) ? 0 : getDomains().hashCode()); hashCode = prime * hashCode + ((getEnableSsl() == null) ? 0 : getEnableSsl().hashCode()); hashCode = prime * hashCode + ((getSslConfiguration() == null) ? 0 : getSslConfiguration().hashCode()); hashCode = prime * hashCode + ((getAttributes() == null) ? 0 : getAttributes().hashCode()); hashCode = prime * hashCode + ((getEnvironment() == null) ? 0 : getEnvironment().hashCode()); return hashCode; }
return false; UpdateAppRequest other = (UpdateAppRequest) obj; if (other.getAppId() == null ^ this.getAppId() == null) return false; if (other.getAppId() != null && other.getAppId().equals(this.getAppId()) == false) return false; if (other.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getDataSources() == null ^ this.getDataSources() == null) return false; if (other.getDataSources() != null && other.getDataSources().equals(this.getDataSources()) == false) return false; if (other.getType() == null ^ this.getType() == null) return false; if (other.getType() != null && other.getType().equals(this.getType()) == false) return false; if (other.getAppSource() == null ^ this.getAppSource() == null) return false; if (other.getAppSource() != null && other.getAppSource().equals(this.getAppSource()) == false) return false; if (other.getDomains() == null ^ this.getDomains() == null) return false; if (other.getDomains() != null && other.getDomains().equals(this.getDomains()) == false)
StringBuilder sb = new StringBuilder(); sb.append("{"); if (getAppId() != null) sb.append("AppId: ").append(getAppId()).append(","); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getDataSources() != null) sb.append("DataSources: ").append(getDataSources()).append(","); if (getType() != null) sb.append("Type: ").append(getType()).append(","); if (getAppSource() != null) sb.append("AppSource: ").append(getAppSource()).append(","); if (getDomains() != null) sb.append("Domains: ").append(getDomains()).append(","); if (getEnableSsl() != null) sb.append("EnableSsl: ").append(getEnableSsl()).append(","); if (getSslConfiguration() != null) sb.append("SslConfiguration: ").append(getSslConfiguration()).append(","); if (getAttributes() != null) sb.append("Attributes: ").append(getAttributes()).append(","); if (getEnvironment() != null) sb.append("Environment: ").append(getEnvironment()); sb.append("}"); return sb.toString();
/** * Marshall the given parameter object. */ public void marshall(UpdateAppRequest updateAppRequest, ProtocolMarshaller protocolMarshaller) { if (updateAppRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(updateAppRequest.getAppId(), APPID_BINDING); protocolMarshaller.marshall(updateAppRequest.getName(), NAME_BINDING); protocolMarshaller.marshall(updateAppRequest.getDescription(), DESCRIPTION_BINDING); protocolMarshaller.marshall(updateAppRequest.getDataSources(), DATASOURCES_BINDING); protocolMarshaller.marshall(updateAppRequest.getType(), TYPE_BINDING); protocolMarshaller.marshall(updateAppRequest.getAppSource(), APPSOURCE_BINDING); protocolMarshaller.marshall(updateAppRequest.getDomains(), DOMAINS_BINDING); protocolMarshaller.marshall(updateAppRequest.getEnableSsl(), ENABLESSL_BINDING); protocolMarshaller.marshall(updateAppRequest.getSslConfiguration(), SSLCONFIGURATION_BINDING); protocolMarshaller.marshall(updateAppRequest.getAttributes(), ATTRIBUTES_BINDING); protocolMarshaller.marshall(updateAppRequest.getEnvironment(), ENVIRONMENT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }