/** * Calculate the full qualified componentname of the given type. * * @param type * The <code>org.eclipse.uml2.uml.Type</code> to calculate the * full qualified name for * @return The full qualified name as <code>java.lang.String</code> */ public String getFQNComponentName(Type type) { String pn = ""; Component cp = null; // looking for start component if (type instanceof Component) { cp = (Component) type; } else { cp = findNearestComponent(type); } // stepping up component hierarchy while (cp != null) { pn = cp.getName() + "." + pn; cp = findNearestComponent(cp); } if (pn.endsWith(".")) { pn = pn.substring(0, pn.length() - 1); } return pn; }