@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getResourceGroupArn() == null) ? 0 : getResourceGroupArn().hashCode()); hashCode = prime * hashCode + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode()); hashCode = prime * hashCode + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode()); return hashCode; }
/** * <p> * The ARN that specifies the Amazon Inspector assessment target. * </p> * * @param arn * The ARN that specifies the Amazon Inspector assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withArn(String arn) { setArn(arn); return this; }
/** * <p> * The time at which the assessment target is created. * </p> * * @param createdAt * The time at which the assessment target is created. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withCreatedAt(java.util.Date createdAt) { setCreatedAt(createdAt); return this; }
public AssessmentTarget unmarshall(JsonUnmarshallerContext context) throws Exception { AssessmentTarget assessmentTarget = new AssessmentTarget(); if (context.testExpression("arn", targetDepth)) { context.nextToken(); assessmentTarget.setArn(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setName(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setResourceGroupArn(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setCreatedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context)); assessmentTarget.setUpdatedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context));
/** * <p> * The name of the Amazon Inspector assessment target. * </p> * * @param name * The name of the Amazon Inspector assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withName(String name) { setName(name); return this; }
/** * <p> * The ARN that specifies the resource group that is associated with the assessment target. * </p> * * @param resourceGroupArn * The ARN that specifies the resource group that is associated with the assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withResourceGroupArn(String resourceGroupArn) { setResourceGroupArn(resourceGroupArn); return this; }
public AssessmentTarget unmarshall(JsonUnmarshallerContext context) throws Exception { AssessmentTarget assessmentTarget = new AssessmentTarget(); if (context.testExpression("arn", targetDepth)) { context.nextToken(); assessmentTarget.setArn(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setName(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setResourceGroupArn(context.getUnmarshaller(String.class).unmarshall(context)); assessmentTarget.setCreatedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context)); assessmentTarget.setUpdatedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context));
/** * <p> * The name of the Amazon Inspector assessment target. * </p> * * @param name * The name of the Amazon Inspector assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withName(String name) { setName(name); return this; }
/** * <p> * The ARN that specifies the resource group that is associated with the assessment target. * </p> * * @param resourceGroupArn * The ARN that specifies the resource group that is associated with the assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withResourceGroupArn(String resourceGroupArn) { setResourceGroupArn(resourceGroupArn); return this; }
return false; AssessmentTarget other = (AssessmentTarget) obj; if (other.getArn() == null ^ this.getArn() == null) return false; if (other.getArn() != null && other.getArn().equals(this.getArn()) == 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.getResourceGroupArn() == null ^ this.getResourceGroupArn() == null) return false; if (other.getResourceGroupArn() != null && other.getResourceGroupArn().equals(this.getResourceGroupArn()) == false) return false; if (other.getCreatedAt() == null ^ this.getCreatedAt() == null) return false; if (other.getCreatedAt() != null && other.getCreatedAt().equals(this.getCreatedAt()) == false) return false; if (other.getUpdatedAt() == null ^ this.getUpdatedAt() == null) return false; if (other.getUpdatedAt() != null && other.getUpdatedAt().equals(this.getUpdatedAt()) == false) return false; return true;
/** * <p> * The ARN that specifies the Amazon Inspector assessment target. * </p> * * @param arn * The ARN that specifies the Amazon Inspector assessment target. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withArn(String arn) { setArn(arn); return this; }
/** * <p> * The time at which the assessment target is created. * </p> * * @param createdAt * The time at which the assessment target is created. * @return Returns a reference to this object so that method calls can be chained together. */ public AssessmentTarget withCreatedAt(java.util.Date createdAt) { setCreatedAt(createdAt); return this; }
/** * 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 (getArn() != null) sb.append("Arn: ").append(getArn()).append(","); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getResourceGroupArn() != null) sb.append("ResourceGroupArn: ").append(getResourceGroupArn()).append(","); if (getCreatedAt() != null) sb.append("CreatedAt: ").append(getCreatedAt()).append(","); if (getUpdatedAt() != null) sb.append("UpdatedAt: ").append(getUpdatedAt()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(AssessmentTarget assessmentTarget, ProtocolMarshaller protocolMarshaller) { if (assessmentTarget == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(assessmentTarget.getArn(), ARN_BINDING); protocolMarshaller.marshall(assessmentTarget.getName(), NAME_BINDING); protocolMarshaller.marshall(assessmentTarget.getResourceGroupArn(), RESOURCEGROUPARN_BINDING); protocolMarshaller.marshall(assessmentTarget.getCreatedAt(), CREATEDAT_BINDING); protocolMarshaller.marshall(assessmentTarget.getUpdatedAt(), UPDATEDAT_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 + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getResourceGroupArn() == null) ? 0 : getResourceGroupArn().hashCode()); hashCode = prime * hashCode + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode()); hashCode = prime * hashCode + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode()); return hashCode; }
return false; AssessmentTarget other = (AssessmentTarget) obj; if (other.getArn() == null ^ this.getArn() == null) return false; if (other.getArn() != null && other.getArn().equals(this.getArn()) == 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.getResourceGroupArn() == null ^ this.getResourceGroupArn() == null) return false; if (other.getResourceGroupArn() != null && other.getResourceGroupArn().equals(this.getResourceGroupArn()) == false) return false; if (other.getCreatedAt() == null ^ this.getCreatedAt() == null) return false; if (other.getCreatedAt() != null && other.getCreatedAt().equals(this.getCreatedAt()) == false) return false; if (other.getUpdatedAt() == null ^ this.getUpdatedAt() == null) return false; if (other.getUpdatedAt() != null && other.getUpdatedAt().equals(this.getUpdatedAt()) == false) return false; return true;
/** * 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 (getArn() != null) sb.append("Arn: ").append(getArn()).append(","); if (getName() != null) sb.append("Name: ").append(getName()).append(","); if (getResourceGroupArn() != null) sb.append("ResourceGroupArn: ").append(getResourceGroupArn()).append(","); if (getCreatedAt() != null) sb.append("CreatedAt: ").append(getCreatedAt()).append(","); if (getUpdatedAt() != null) sb.append("UpdatedAt: ").append(getUpdatedAt()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(AssessmentTarget assessmentTarget, ProtocolMarshaller protocolMarshaller) { if (assessmentTarget == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(assessmentTarget.getArn(), ARN_BINDING); protocolMarshaller.marshall(assessmentTarget.getName(), NAME_BINDING); protocolMarshaller.marshall(assessmentTarget.getResourceGroupArn(), RESOURCEGROUPARN_BINDING); protocolMarshaller.marshall(assessmentTarget.getCreatedAt(), CREATEDAT_BINDING); protocolMarshaller.marshall(assessmentTarget.getUpdatedAt(), UPDATEDAT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }