package com.intuit.tank.harness.data; /* * #%L * Harness Data * %% * Copyright (C) 2011 - 2015 Intuit Inc. * %% * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * #L% */ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAttribute; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlType; @XmlType(name = "timerStep", propOrder = { "value", "start" }, namespace = HarnessDataNamespace.NAMESPACE_V1) @XmlAccessorType(XmlAccessType.FIELD) @XmlRootElement public class TimerStep extends TestStep { @XmlElement(name = "loggingKey") private String value; @XmlAttribute(name = "isStart") private boolean start; /** * @return the value */ public String getValue() { return value; } /** * @param value * the value to set */ public void setValue(String value) { this.value = value; } public boolean isStart() { return start; } public void setStart(boolean start) { this.start = start; } @Override public String getInfo() { return new StringBuilder().append((isStart() ? "Start" : "Stop") + "_Timer(").append(value).append(')') .toString(); } /** * @{inheritDoc */ @Override public String toString() { return getClass().getSimpleName() + (isStart() ? "Start" : "Stop") + " : " + value; } }