public <T extends Anim> void clearanims(Class<T> type) { for (Iterator<Anim> i = nanims.iterator(); i.hasNext(); ) { Anim a = i.next(); if (type.isInstance(a)) i.remove(); } for (Iterator<Anim> i = anims.iterator(); i.hasNext(); ) { Anim a = i.next(); if (type.isInstance(a)) i.remove(); } }
@Deprecated public <T extends Widget> T findchild(Class<T> cl) { for (Widget wdg = child; wdg != null; wdg = wdg.next) { if (cl.isInstance(wdg)) return (cl.cast(wdg)); T ret = wdg.findchild(cl); if (ret != null) return (ret); } return (null); }
static boolean hasInstance(Object[] array, Class<? extends Annotation>... cs) { for (Object o : array) { for (Class<?> c : cs) { if (c.isInstance(o)) { return true; } } } return false; }
public <T extends Widget> T getparent(Class<T> cl) { for (Widget w = this; w != null; w = w.parent) { if (cl.isInstance(w)) return (cl.cast(w)); } return (null); }