1 27 28 package org.objectweb.speedo.metadata; 29 30 import java.util.Iterator ; 31 import java.util.Map ; 32 33 36 public class SpeedoMetaInfo { 37 38 44 public Map xmldescriptor = null; 45 46 47 public SpeedoClass getSpeedoClass(String className) { 48 return getSpeedoClass(className, (SpeedoXMLDescriptor) null); 49 } 50 51 public SpeedoClass getSpeedoClass(String className, SpeedoXMLDescriptor xml) { 52 SpeedoClass sc = null; 54 if (xml != null) { 55 sc = xml.getSpeedoClass(className, false); 56 if (sc != null) { 57 return sc; 59 } 60 } 61 for(Iterator it = xmldescriptor.values().iterator(); 63 it.hasNext() && sc == null;) { 64 SpeedoXMLDescriptor _xml = (SpeedoXMLDescriptor) it.next(); 65 if (xml == _xml) { 66 continue; 67 } 68 sc = _xml.getSpeedoClass(className, false); 69 } 70 return sc; 72 } 73 74 public SpeedoClass getSpeedoClass(String className, SpeedoPackage sp) { 75 SpeedoXMLDescriptor xml = null; 77 if (sp != null) { 78 xml = sp.jdoXMLDescriptor; 79 } 80 SpeedoClass sc = getSpeedoClass(className, xml); 81 if (sc == null) { 82 sc = getSpeedoClass(sp.name + '.' + className, xml); 83 } 84 return sc; 86 } 87 88 } 89 | Popular Tags |