01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.object.bytecode.aspectwerkz;
05:
06: import com.tc.aspectwerkz.reflect.ClassInfo;
07:
08: import java.util.HashMap;
09: import java.util.Map;
10:
11: /**
12: *
13: */
14: public class ClassInfoFactory {
15: private final Map classInfoCache = new HashMap();
16:
17: public ClassInfo getClassInfo(String className) {
18: ClassInfo info;
19: synchronized (classInfoCache) {
20: info = (ClassInfo) classInfoCache.get(className);
21: if (info == null) {
22: info = new SimpleClassInfo(className);
23: classInfoCache.put(className, info);
24: }
25: }
26: return info;
27: }
28: }
|