public void requestRepaintRequests() {
}
+ public String getTestingIdentifier() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public void setTestingIdentifier(String id) {
+ throw new UnsupportedOperationException(
+ "Setting testing id for this Paintable is not implemented");
+ }
+
}
}
public void requestRepaintRequests() {
}
+ public String getTestingIdentifier() {
+ return null;
+ }
+
+ public void setTestingIdentifier(String id) {
+ throw new UnsupportedOperationException(
+ "Setting testing id for this Paintable is not implemented");
+ }
+
}
}
return retval;
}
+
+ public String getTestingIdentifier() {
+ return null;
+ }
+
+ public void setTestingIdentifier(String id) {
+ throw new UnsupportedOperationException(
+ "Setting testing id for this Paintable is not implemented");
+ }
}
*/
public void requestRepaint();
+ /**
+ * Adds an unique id for component that get's transferred to terminal for
+ * testing purposes.
+ *
+ * @param id
+ * A short (< 20 chars) alphanumeric indentifier
+ */
+ public void setTestingIdentifier(String id);
+
+ public String getTestingIdentifier();
+
/**
* Repaint request event is thrown when the paintable needs to be repainted.
* This is typically done when the <code>paint</code> method would return
public void requestRepaintRequests() {
}
+ public String getTestingIdentifier() {
+ return null;
+ }
+
+ public void setTestingIdentifier(String id) {
+ throw new UnsupportedOperationException(
+ "Setting testing id for this Paintable is not implemented");
+ }
+
}
return msg;
}
+ public String getTestingIdentifier() {
+ return null;
+ }
+
+ public void setTestingIdentifier(String id) {
+ throw new UnsupportedOperationException(
+ "Setting testing id for this Paintable is not implemented");
+ }
+
}
if (testingToolsServerUri == null) {
// Default behavior is that ATFServer application exists on
// same application server as current application does.
- testingToolsServerUri = "http" + (request.isSecure() ? "s" : "")
- + "://" + request.getServerName() + ":"
- + request.getLocalPort() + "/ATF/ATFServer";
+ testingToolsServerUri = "http" + (request.isSecure() ? "s" : "") + "://"
+ + request.getServerName() + ":" + request.getLocalPort()
+ + "/ATF/ATFServer";
}
return testingToolsServerUri;
}
String id = (String) paintableIdMap.get(paintable);
if (id == null) {
- id = "PID" + Integer.toString(idSequence++);
+ // use testing identifier as id if set
+ id = paintable.getTestingIdentifier();
+ if (id == null) {
+ id = "PID" + Integer.toString(idSequence++);
+ }
paintableIdMap.put(paintable, id);
idPaintableMap.put(id, paintable);
}
*/
private boolean repaintRequestListenersNotified = false;
+ private String testingId;
+
/* Constructor ***************************************************** */
/**
*/
public abstract String getTag();
+ public void setTestingIdentifier(String id) {
+ testingId = id;
+ }
+
+ public String getTestingIdentifier() {
+ return testingId;
+ }
+
/**
* Gets style for component. Multiple styles are joined with spaces.
*
*/
private boolean repaintRequestListenersNotified = false;
+ private String testingId;
+
/**
* Constructs a new custom component.
*
}
+ public void setTestingIdentifier(String id) {
+ testingId = id;
+ }
+
+ public String getTestingIdentifier() {
+ return testingId;
+ }
+
}