* @param element the element (class, method, etc.) to examine
* @return an ArrayList of AnnotationInstances.
*/
private static ArrayList getAnnotations( XProgramElement element )
{
XDoc doc = element.getDoc();
ArrayList annotations = new ArrayList();
List tags = doc != null ? doc.getTags() : null;
ArrayList parentAnnotations = new ArrayList(); // hierarchy of parent annotations, e.g., Action -> Forward -> ...
if ( tags == null ) return annotations;
for ( Iterator i = tags.iterator(); i.hasNext(); )