String attrString = "[#startpos<" + docOffset + " and #endpos>" + docOffset + "]";
CFNodeList matchingNodes = docRoot.getDocumentRoot().selectNodes("//cfinclude" + attrString);
Iterator nodeIter = matchingNodes.iterator();
CfmlTagItem currItem = null;
if(nodeIter.hasNext())
{
currItem = (CfmlTagItem)nodeIter.next();
}
else
{
matchingNodes = docRoot.getDocumentRoot().selectNodes("//cfmodule" + attrString);
nodeIter = matchingNodes.iterator();
if(nodeIter.hasNext()) {
currItem = (CfmlTagItem)nodeIter.next();
}
else
return;
}
String template = currItem.getAttributeValue("template");
IEditorPart iep = this.editor.getSite().getPage().getActiveEditor();
ITextEditor editor = (ITextEditor)iep;
String pth = (
(IResource)((FileEditorInput)editor.getEditorInput()