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;
05:
06: import com.tc.object.loaders.ClassProvider;
07: import com.tc.object.loaders.NamedClassLoader;
08:
09: public class MockClassProvider implements ClassProvider {
10:
11: public MockClassProvider() {
12: super ();
13: }
14:
15: public Class getClassFor(String className, String loaderDesc)
16: throws ClassNotFoundException {
17: return getClass().getClassLoader().loadClass(className);
18:
19: }
20:
21: public String getLoaderDescriptionFor(Class clazz) {
22: return "";
23: }
24:
25: public ClassLoader getClassLoader(String loaderDesc) {
26: return getClass().getClassLoader();
27: }
28:
29: public String getLoaderDescriptionFor(ClassLoader loader) {
30: return "";
31: }
32:
33: public void registerNamedLoader(NamedClassLoader loader) {
34: // do nothing
35: }
36:
37: }
|