package pete.metrics.adaptability.elements;


class DetectionOnlyElements extends ElementsCollection {

	private EventElements events;

	public DetectionOnlyElements() {
		events = new EventElements();
		buildSequenceFlow();
		buildThrowLinkEvent();
		buildCatchLinkEvent();
	}

	private void buildSequenceFlow() {
		AdaptableElement sequenceFlow = new AdaptableElement("sequenceFlow");
		sequenceFlow.setLocatorExpression("//*[local-name() = 'sequenceFlow']");
		add(sequenceFlow);
	}

	private void buildThrowLinkEvent() {
		AdaptableElement linkEvent = new AdaptableElement("linkThrowEvent");
		linkEvent.setLocatorExpression(events.buildEventXPathExpression("intermediateThrowEvent", "link"));
		add(linkEvent);
	}

	private void buildCatchLinkEvent() {
		AdaptableElement linkEvent = new AdaptableElement("linkCatchEvent");
		linkEvent.setLocatorExpression(events.buildEventXPathExpression("intermediateCatchEvent", "link"));
		add(linkEvent);
	}

}

@@ -377,16 +377,22 @@
 nceFlow%22
+, true
 );%0A%09%09seq
@@ -588,24 +588,30 @@
 kThrowEvent%22
+, true
 );%0A%09%09linkEve
@@ -831,16 +831,22 @@
 chEvent%22
+, true
 );%0A%09%09lin

Set detectionOnly flag for DetectionOnlyElements