public AnnotationFS handle(CreateSpanAnnotationRequest aRequest) throws AnnotationException { CreateSpanAnnotationRequest request = aRequest; for (SpanLayerBehavior behavior : behaviors) { request = behavior.onCreate(this, request); } AnnotationFS newAnnotation = createSpanAnnotation(request.getJcas().getCas(), request.getBegin(), request.getEnd()); publishEvent(new SpanCreatedEvent(this, request.getDocument(), request.getUsername(), newAnnotation)); return newAnnotation; }
public AnnotationFS handle(CreateSpanAnnotationRequest aRequest) throws AnnotationException { CreateSpanAnnotationRequest request = aRequest; for (SpanLayerBehavior behavior : behaviors) { request = behavior.onCreate(this, request); } AnnotationFS newAnnotation = createSpanAnnotation(request.getJcas().getCas(), request.getBegin(), request.getEnd()); publishEvent(new SpanCreatedEvent(this, request.getDocument(), request.getUsername(), newAnnotation)); return newAnnotation; }