@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getMessageType() == null) ? 0 : getMessageType().hashCode()); hashCode = prime * hashCode + ((getCount() == null) ? 0 : getCount().hashCode()); hashCode = prime * hashCode + ((getDataSize() == null) ? 0 : getDataSize().hashCode()); return hashCode; }
/** * <p> * The count of messages that the agent sends to the Amazon Inspector service. * </p> * * @param count * The count of messages that the agent sends to the Amazon Inspector service. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withCount(Long count) { setCount(count); return this; }
/** * <p> * The data size of messages that the agent sends to the Amazon Inspector service. * </p> * * @param dataSize * The data size of messages that the agent sends to the Amazon Inspector service. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withDataSize(Long dataSize) { setDataSize(dataSize); return this; }
public TelemetryMetadata unmarshall(JsonUnmarshallerContext context) throws Exception { TelemetryMetadata telemetryMetadata = new TelemetryMetadata(); if (context.testExpression("messageType", targetDepth)) { context.nextToken(); telemetryMetadata.setMessageType(context.getUnmarshaller(String.class).unmarshall(context)); telemetryMetadata.setCount(context.getUnmarshaller(Long.class).unmarshall(context)); telemetryMetadata.setDataSize(context.getUnmarshaller(Long.class).unmarshall(context));
/** * <p> * A specific type of behavioral data that is collected by the agent. * </p> * * @param messageType * A specific type of behavioral data that is collected by the agent. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withMessageType(String messageType) { setMessageType(messageType); return this; }
public TelemetryMetadata unmarshall(JsonUnmarshallerContext context) throws Exception { TelemetryMetadata telemetryMetadata = new TelemetryMetadata(); if (context.testExpression("messageType", targetDepth)) { context.nextToken(); telemetryMetadata.setMessageType(context.getUnmarshaller(String.class).unmarshall(context)); telemetryMetadata.setCount(context.getUnmarshaller(Long.class).unmarshall(context)); telemetryMetadata.setDataSize(context.getUnmarshaller(Long.class).unmarshall(context));
/** * <p> * A specific type of behavioral data that is collected by the agent. * </p> * * @param messageType * A specific type of behavioral data that is collected by the agent. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withMessageType(String messageType) { setMessageType(messageType); return this; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof TelemetryMetadata == false) return false; TelemetryMetadata other = (TelemetryMetadata) obj; if (other.getMessageType() == null ^ this.getMessageType() == null) return false; if (other.getMessageType() != null && other.getMessageType().equals(this.getMessageType()) == false) return false; if (other.getCount() == null ^ this.getCount() == null) return false; if (other.getCount() != null && other.getCount().equals(this.getCount()) == false) return false; if (other.getDataSize() == null ^ this.getDataSize() == null) return false; if (other.getDataSize() != null && other.getDataSize().equals(this.getDataSize()) == false) return false; return true; }
/** * <p> * The data size of messages that the agent sends to the Amazon Inspector service. * </p> * * @param dataSize * The data size of messages that the agent sends to the Amazon Inspector service. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withDataSize(Long dataSize) { setDataSize(dataSize); return this; }
/** * <p> * The count of messages that the agent sends to the Amazon Inspector service. * </p> * * @param count * The count of messages that the agent sends to the Amazon Inspector service. * @return Returns a reference to this object so that method calls can be chained together. */ public TelemetryMetadata withCount(Long count) { setCount(count); 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 (getMessageType() != null) sb.append("MessageType: ").append(getMessageType()).append(","); if (getCount() != null) sb.append("Count: ").append(getCount()).append(","); if (getDataSize() != null) sb.append("DataSize: ").append(getDataSize()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(TelemetryMetadata telemetryMetadata, ProtocolMarshaller protocolMarshaller) { if (telemetryMetadata == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(telemetryMetadata.getMessageType(), MESSAGETYPE_BINDING); protocolMarshaller.marshall(telemetryMetadata.getCount(), COUNT_BINDING); protocolMarshaller.marshall(telemetryMetadata.getDataSize(), DATASIZE_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 + ((getMessageType() == null) ? 0 : getMessageType().hashCode()); hashCode = prime * hashCode + ((getCount() == null) ? 0 : getCount().hashCode()); hashCode = prime * hashCode + ((getDataSize() == null) ? 0 : getDataSize().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof TelemetryMetadata == false) return false; TelemetryMetadata other = (TelemetryMetadata) obj; if (other.getMessageType() == null ^ this.getMessageType() == null) return false; if (other.getMessageType() != null && other.getMessageType().equals(this.getMessageType()) == false) return false; if (other.getCount() == null ^ this.getCount() == null) return false; if (other.getCount() != null && other.getCount().equals(this.getCount()) == false) return false; if (other.getDataSize() == null ^ this.getDataSize() == null) return false; if (other.getDataSize() != null && other.getDataSize().equals(this.getDataSize()) == 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 (getMessageType() != null) sb.append("MessageType: ").append(getMessageType()).append(","); if (getCount() != null) sb.append("Count: ").append(getCount()).append(","); if (getDataSize() != null) sb.append("DataSize: ").append(getDataSize()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(TelemetryMetadata telemetryMetadata, ProtocolMarshaller protocolMarshaller) { if (telemetryMetadata == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(telemetryMetadata.getMessageType(), MESSAGETYPE_BINDING); protocolMarshaller.marshall(telemetryMetadata.getCount(), COUNT_BINDING); protocolMarshaller.marshall(telemetryMetadata.getDataSize(), DATASIZE_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }