com.amazonaws.services.ec2.model.Placement.getGroupName()方法的使用及代码示例

x33g5p2x  于2022-01-26 转载在 其他  
字(10.0k)|赞(0)|评价(0)|浏览(104)

本文整理了Java中com.amazonaws.services.ec2.model.Placement.getGroupName()方法的一些代码示例,展示了Placement.getGroupName()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Placement.getGroupName()方法的具体详情如下:
包路径:com.amazonaws.services.ec2.model.Placement
类名称:Placement
方法名:getGroupName

Placement.getGroupName介绍

[英]The name of the placement group the instance is in.
[中]实例所在的放置组的名称。

代码示例

代码示例来源:origin: aws/aws-sdk-java

/**
 * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
 * redacted from this string using a placeholder value.
 *
 * @return A string representation of this object.
 *
 * @see java.lang.Object#toString()
 */
@Override
public String toString() {
  StringBuilder sb = new StringBuilder();
  sb.append("{");
  if (getAvailabilityZone() != null)
    sb.append("AvailabilityZone: ").append(getAvailabilityZone()).append(",");
  if (getAffinity() != null)
    sb.append("Affinity: ").append(getAffinity()).append(",");
  if (getGroupName() != null)
    sb.append("GroupName: ").append(getGroupName()).append(",");
  if (getPartitionNumber() != null)
    sb.append("PartitionNumber: ").append(getPartitionNumber()).append(",");
  if (getHostId() != null)
    sb.append("HostId: ").append(getHostId()).append(",");
  if (getTenancy() != null)
    sb.append("Tenancy: ").append(getTenancy()).append(",");
  if (getSpreadDomain() != null)
    sb.append("SpreadDomain: ").append(getSpreadDomain());
  sb.append("}");
  return sb.toString();
}

代码示例来源:origin: aws/aws-sdk-java

@Override
public int hashCode() {
  final int prime = 31;
  int hashCode = 1;
  hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode());
  hashCode = prime * hashCode + ((getAffinity() == null) ? 0 : getAffinity().hashCode());
  hashCode = prime * hashCode + ((getGroupName() == null) ? 0 : getGroupName().hashCode());
  hashCode = prime * hashCode + ((getPartitionNumber() == null) ? 0 : getPartitionNumber().hashCode());
  hashCode = prime * hashCode + ((getHostId() == null) ? 0 : getHostId().hashCode());
  hashCode = prime * hashCode + ((getTenancy() == null) ? 0 : getTenancy().hashCode());
  hashCode = prime * hashCode + ((getSpreadDomain() == null) ? 0 : getSpreadDomain().hashCode());
  return hashCode;
}

代码示例来源:origin: aws/aws-sdk-java

if (other.getAffinity() != null && other.getAffinity().equals(this.getAffinity()) == false)
  return false;
if (other.getGroupName() == null ^ this.getGroupName() == null)
  return false;
if (other.getGroupName() != null && other.getGroupName().equals(this.getGroupName()) == false)
  return false;
if (other.getPartitionNumber() == null ^ this.getPartitionNumber() == null)

代码示例来源:origin: aws-amplify/aws-sdk-android

@Override
public int hashCode() {
  final int prime = 31;
  int hashCode = 1;
  
  hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode()); 
  hashCode = prime * hashCode + ((getGroupName() == null) ? 0 : getGroupName().hashCode()); 
  hashCode = prime * hashCode + ((getTenancy() == null) ? 0 : getTenancy().hashCode()); 
  hashCode = prime * hashCode + ((getHostId() == null) ? 0 : getHostId().hashCode()); 
  hashCode = prime * hashCode + ((getAffinity() == null) ? 0 : getAffinity().hashCode()); 
  return hashCode;
}

代码示例来源:origin: aws-amplify/aws-sdk-android

/**
 * Returns a string representation of this object; useful for testing and
 * debugging.
 *
 * @return A string representation of this object.
 *
 * @see java.lang.Object#toString()
 */
@Override
public String toString() {
  StringBuilder sb = new StringBuilder();
  sb.append("{");
  if (getAvailabilityZone() != null) sb.append("AvailabilityZone: " + getAvailabilityZone() + ",");
  if (getGroupName() != null) sb.append("GroupName: " + getGroupName() + ",");
  if (getTenancy() != null) sb.append("Tenancy: " + getTenancy() + ",");
  if (getHostId() != null) sb.append("HostId: " + getHostId() + ",");
  if (getAffinity() != null) sb.append("Affinity: " + getAffinity() );
  sb.append("}");
  return sb.toString();
}

代码示例来源:origin: aws-amplify/aws-sdk-android

@Override
public boolean equals(Object obj) {
  if (this == obj) return true;
  if (obj == null) return false;
  if (obj instanceof Placement == false) return false;
  Placement other = (Placement)obj;
  
  if (other.getAvailabilityZone() == null ^ this.getAvailabilityZone() == null) return false;
  if (other.getAvailabilityZone() != null && other.getAvailabilityZone().equals(this.getAvailabilityZone()) == false) return false; 
  if (other.getGroupName() == null ^ this.getGroupName() == null) return false;
  if (other.getGroupName() != null && other.getGroupName().equals(this.getGroupName()) == false) return false; 
  if (other.getTenancy() == null ^ this.getTenancy() == null) return false;
  if (other.getTenancy() != null && other.getTenancy().equals(this.getTenancy()) == false) return false; 
  if (other.getHostId() == null ^ this.getHostId() == null) return false;
  if (other.getHostId() != null && other.getHostId().equals(this.getHostId()) == false) return false; 
  if (other.getAffinity() == null ^ this.getAffinity() == null) return false;
  if (other.getAffinity() != null && other.getAffinity().equals(this.getAffinity()) == false) return false; 
  return true;
}

代码示例来源:origin: aws/aws-sdk-java

if (placement.getGroupName() != null) {
  request.addParameter("LaunchSpecification.Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

代码示例来源:origin: aws/aws-sdk-java

if (placement.getGroupName() != null) {
  request.addParameter("LaunchTemplateConfigs." + launchTemplateConfigsListIndex + ".Overrides." + overridesListIndex
      + ".Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

代码示例来源:origin: aws/aws-sdk-java

if (placement.getGroupName() != null) {
  request.addParameter("Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

/**
 * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
 * redacted from this string using a placeholder value.
 *
 * @return A string representation of this object.
 *
 * @see java.lang.Object#toString()
 */
@Override
public String toString() {
  StringBuilder sb = new StringBuilder();
  sb.append("{");
  if (getAvailabilityZone() != null)
    sb.append("AvailabilityZone: ").append(getAvailabilityZone()).append(",");
  if (getAffinity() != null)
    sb.append("Affinity: ").append(getAffinity()).append(",");
  if (getGroupName() != null)
    sb.append("GroupName: ").append(getGroupName()).append(",");
  if (getPartitionNumber() != null)
    sb.append("PartitionNumber: ").append(getPartitionNumber()).append(",");
  if (getHostId() != null)
    sb.append("HostId: ").append(getHostId()).append(",");
  if (getTenancy() != null)
    sb.append("Tenancy: ").append(getTenancy()).append(",");
  if (getSpreadDomain() != null)
    sb.append("SpreadDomain: ").append(getSpreadDomain());
  sb.append("}");
  return sb.toString();
}

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

@Override
public int hashCode() {
  final int prime = 31;
  int hashCode = 1;
  hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode());
  hashCode = prime * hashCode + ((getAffinity() == null) ? 0 : getAffinity().hashCode());
  hashCode = prime * hashCode + ((getGroupName() == null) ? 0 : getGroupName().hashCode());
  hashCode = prime * hashCode + ((getPartitionNumber() == null) ? 0 : getPartitionNumber().hashCode());
  hashCode = prime * hashCode + ((getHostId() == null) ? 0 : getHostId().hashCode());
  hashCode = prime * hashCode + ((getTenancy() == null) ? 0 : getTenancy().hashCode());
  hashCode = prime * hashCode + ((getSpreadDomain() == null) ? 0 : getSpreadDomain().hashCode());
  return hashCode;
}

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

if (other.getAffinity() != null && other.getAffinity().equals(this.getAffinity()) == false)
  return false;
if (other.getGroupName() == null ^ this.getGroupName() == null)
  return false;
if (other.getGroupName() != null && other.getGroupName().equals(this.getGroupName()) == false)
  return false;
if (other.getPartitionNumber() == null ^ this.getPartitionNumber() == null)

代码示例来源:origin: aws-amplify/aws-sdk-android

request.addParameter("LaunchSpecification.Placement.AvailabilityZone", StringUtils.fromString(placementPlacement.getAvailabilityZone()));
if (placementPlacement.getGroupName() != null) {
  request.addParameter("LaunchSpecification.Placement.GroupName", StringUtils.fromString(placementPlacement.getGroupName()));

代码示例来源:origin: org.apache.airavata/airavata-xbaya-gui

/**
 * @see org.apache.airavata.xbaya.ui.widgets.TableRenderable#getValue(int)
 */
@Override
public Object getValue(int index) {
  switch (index) {
  case 0:
    return this.instance.getInstanceId();
  case 1:
    return this.instance.getImageId();
  case 2:
    return this.instance.getRootDeviceType();
  case 3:
    return this.instance.getInstanceType();
  case 4:
    return this.instance.getState().getName();
  case 5:
    return this.instance.getKeyName();
  case 6:
    return this.instance.getMonitoring().getState();
  case 7:
    return this.instance.getVirtualizationType();
  case 8:
    return this.instance.getPlacement().getGroupName();
  default:
    return null;
  }
}

代码示例来源:origin: airbnb/billow

this.hypervisor = instance.getHypervisor();
this.az = instance.getPlacement().getAvailabilityZone();
this.group = instance.getPlacement().getGroupName();
this.tenancy = instance.getPlacement().getTenancy();
this.vpc = instance.getVpcId();

代码示例来源:origin: aws-amplify/aws-sdk-android

request.addParameter("Placement.AvailabilityZone", StringUtils.fromString(placementPlacement.getAvailabilityZone()));
if (placementPlacement.getGroupName() != null) {
  request.addParameter("Placement.GroupName", StringUtils.fromString(placementPlacement.getGroupName()));

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

if (placement.getGroupName() != null) {
  request.addParameter("LaunchSpecification.Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

if (placement.getGroupName() != null) {
  request.addParameter("LaunchTemplateConfigs." + launchTemplateConfigsListIndex + ".Overrides." + overridesListIndex
      + ".Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

代码示例来源:origin: com.amazonaws/aws-java-sdk-ec2

if (placement.getGroupName() != null) {
  request.addParameter("Placement.GroupName", StringUtils.fromString(placement.getGroupName()));

相关文章