From e929b5f4c6d9351b29150e6c1843f06806ee7b00 Mon Sep 17 00:00:00 2001 From: Andreas Fitzek Date: Mon, 1 Dec 2014 12:23:47 +0100 Subject: added status servlet to pdf-as-web --- .../at/gv/egiz/status/impl/BaseTestResult.java | 91 ++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 pdf-as-web-status/src/main/java/at/gv/egiz/status/impl/BaseTestResult.java (limited to 'pdf-as-web-status/src/main/java/at/gv/egiz/status/impl/BaseTestResult.java') diff --git a/pdf-as-web-status/src/main/java/at/gv/egiz/status/impl/BaseTestResult.java b/pdf-as-web-status/src/main/java/at/gv/egiz/status/impl/BaseTestResult.java new file mode 100644 index 00000000..da77f424 --- /dev/null +++ b/pdf-as-web-status/src/main/java/at/gv/egiz/status/impl/BaseTestResult.java @@ -0,0 +1,91 @@ +package at.gv.egiz.status.impl; + +import java.util.ArrayList; +import java.util.List; + +import at.gv.egiz.status.TestResult; +import at.gv.egiz.status.TestStatus; + +/** + * The Class BaseTestResult. + */ +public class BaseTestResult implements TestResult { + + /** The status. */ + private TestStatus status; + + /** The details. */ + private List details; + + /** + * Instantiates a new base test result. + */ + public BaseTestResult() { + this.init(TestStatus.INDETERMINATE, new ArrayList()); + } + + /** + * Instantiates a new base test result. + * + * @param status the status + */ + public BaseTestResult(TestStatus status) { + this.init(status, new ArrayList()); + } + + /** + * Instantiates a new base test result. + * + * @param status the status + * @param details the details + */ + public BaseTestResult(TestStatus status, List details) { + this.init(status, details); + } + + /** + * Inits the. + * + * @param status the status + * @param details the details + */ + private void init(TestStatus status, List details) { + this.status = status; + this.details = details; + } + + /** + * Sets the status. + * + * @param status the new status + */ + public void setStatus(TestStatus status) { + this.status = status; + } + + /** + * Sets the details. + * + * @param details the new details + */ + public void setDetails(List details) { + this.details = details; + } + + /* (non-Javadoc) + * @see at.gv.egiz.status.TestResult#getStatus() + */ + @Override + public TestStatus getStatus() { + return status; + } + + /* (non-Javadoc) + * @see at.gv.egiz.status.TestResult#getDetails() + */ + @Override + public List getDetails() { + return details; + } + +} -- cgit v1.2.3