All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.devicefarm.model.Counters Maven / Gradle / Ivy

Go to download

The AWS Java SDK for AWS Device Farm module holds the client classes that are used for communicating with AWS Device Farm

There is a newer version: 1.12.778
Show newest version
/*
 * Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.devicefarm.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Represents entity counters. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class Counters implements Serializable, Cloneable, StructuredPojo { /** *

* The total number of entities. *

*/ private Integer total; /** *

* The number of passed entities. *

*/ private Integer passed; /** *

* The number of failed entities. *

*/ private Integer failed; /** *

* The number of warned entities. *

*/ private Integer warned; /** *

* The number of errored entities. *

*/ private Integer errored; /** *

* The number of stopped entities. *

*/ private Integer stopped; /** *

* The number of skipped entities. *

*/ private Integer skipped; /** *

* The total number of entities. *

* * @param total * The total number of entities. */ public void setTotal(Integer total) { this.total = total; } /** *

* The total number of entities. *

* * @return The total number of entities. */ public Integer getTotal() { return this.total; } /** *

* The total number of entities. *

* * @param total * The total number of entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withTotal(Integer total) { setTotal(total); return this; } /** *

* The number of passed entities. *

* * @param passed * The number of passed entities. */ public void setPassed(Integer passed) { this.passed = passed; } /** *

* The number of passed entities. *

* * @return The number of passed entities. */ public Integer getPassed() { return this.passed; } /** *

* The number of passed entities. *

* * @param passed * The number of passed entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withPassed(Integer passed) { setPassed(passed); return this; } /** *

* The number of failed entities. *

* * @param failed * The number of failed entities. */ public void setFailed(Integer failed) { this.failed = failed; } /** *

* The number of failed entities. *

* * @return The number of failed entities. */ public Integer getFailed() { return this.failed; } /** *

* The number of failed entities. *

* * @param failed * The number of failed entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withFailed(Integer failed) { setFailed(failed); return this; } /** *

* The number of warned entities. *

* * @param warned * The number of warned entities. */ public void setWarned(Integer warned) { this.warned = warned; } /** *

* The number of warned entities. *

* * @return The number of warned entities. */ public Integer getWarned() { return this.warned; } /** *

* The number of warned entities. *

* * @param warned * The number of warned entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withWarned(Integer warned) { setWarned(warned); return this; } /** *

* The number of errored entities. *

* * @param errored * The number of errored entities. */ public void setErrored(Integer errored) { this.errored = errored; } /** *

* The number of errored entities. *

* * @return The number of errored entities. */ public Integer getErrored() { return this.errored; } /** *

* The number of errored entities. *

* * @param errored * The number of errored entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withErrored(Integer errored) { setErrored(errored); return this; } /** *

* The number of stopped entities. *

* * @param stopped * The number of stopped entities. */ public void setStopped(Integer stopped) { this.stopped = stopped; } /** *

* The number of stopped entities. *

* * @return The number of stopped entities. */ public Integer getStopped() { return this.stopped; } /** *

* The number of stopped entities. *

* * @param stopped * The number of stopped entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withStopped(Integer stopped) { setStopped(stopped); return this; } /** *

* The number of skipped entities. *

* * @param skipped * The number of skipped entities. */ public void setSkipped(Integer skipped) { this.skipped = skipped; } /** *

* The number of skipped entities. *

* * @return The number of skipped entities. */ public Integer getSkipped() { return this.skipped; } /** *

* The number of skipped entities. *

* * @param skipped * The number of skipped entities. * @return Returns a reference to this object so that method calls can be chained together. */ public Counters withSkipped(Integer skipped) { setSkipped(skipped); 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 (getTotal() != null) sb.append("Total: ").append(getTotal()).append(","); if (getPassed() != null) sb.append("Passed: ").append(getPassed()).append(","); if (getFailed() != null) sb.append("Failed: ").append(getFailed()).append(","); if (getWarned() != null) sb.append("Warned: ").append(getWarned()).append(","); if (getErrored() != null) sb.append("Errored: ").append(getErrored()).append(","); if (getStopped() != null) sb.append("Stopped: ").append(getStopped()).append(","); if (getSkipped() != null) sb.append("Skipped: ").append(getSkipped()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof Counters == false) return false; Counters other = (Counters) obj; if (other.getTotal() == null ^ this.getTotal() == null) return false; if (other.getTotal() != null && other.getTotal().equals(this.getTotal()) == false) return false; if (other.getPassed() == null ^ this.getPassed() == null) return false; if (other.getPassed() != null && other.getPassed().equals(this.getPassed()) == false) return false; if (other.getFailed() == null ^ this.getFailed() == null) return false; if (other.getFailed() != null && other.getFailed().equals(this.getFailed()) == false) return false; if (other.getWarned() == null ^ this.getWarned() == null) return false; if (other.getWarned() != null && other.getWarned().equals(this.getWarned()) == false) return false; if (other.getErrored() == null ^ this.getErrored() == null) return false; if (other.getErrored() != null && other.getErrored().equals(this.getErrored()) == false) return false; if (other.getStopped() == null ^ this.getStopped() == null) return false; if (other.getStopped() != null && other.getStopped().equals(this.getStopped()) == false) return false; if (other.getSkipped() == null ^ this.getSkipped() == null) return false; if (other.getSkipped() != null && other.getSkipped().equals(this.getSkipped()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getTotal() == null) ? 0 : getTotal().hashCode()); hashCode = prime * hashCode + ((getPassed() == null) ? 0 : getPassed().hashCode()); hashCode = prime * hashCode + ((getFailed() == null) ? 0 : getFailed().hashCode()); hashCode = prime * hashCode + ((getWarned() == null) ? 0 : getWarned().hashCode()); hashCode = prime * hashCode + ((getErrored() == null) ? 0 : getErrored().hashCode()); hashCode = prime * hashCode + ((getStopped() == null) ? 0 : getStopped().hashCode()); hashCode = prime * hashCode + ((getSkipped() == null) ? 0 : getSkipped().hashCode()); return hashCode; } @Override public Counters clone() { try { return (Counters) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.devicefarm.model.transform.CountersMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy