Package serp.bytecode

# Class BCClassLoader

java.lang.Object
java.lang.ClassLoader
serp.bytecode.BCClassLoader

public class BCClassLoader extends ClassLoader
Class loader that will attempt to find requested classes in a given `Project`.

Author:
  Abe White

## Constructor Summary

Constructors
Constructor
Description
`BCClassLoader(Project project)`
Constructor.
`BCClassLoader(Project project, ClassLoader loader)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`protected BCClass`
`createClass(String name)`
Override this method if unfound classes should be created on-the-fly.
`protected Class`
`findClass(String name)`
`Project`
`getProject()`
Return this class loader's project.

### Methods inherited from class java.lang.ClassLoader

`clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findResource, findResources, findSystemClass, getClassLoadingLock, getDefinedPackage, getDefinedPackages, getName, getPackage, getPackages, getParent, getPlatformClassLoader, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, getUnnamedModule, isRegisteredAsParallelCapable, loadClass, loadClass, registerAsParallelCapable, resolveClass, resources, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### BCClassLoader

public BCClassLoader(Project project)
Constructor. Supply the project to use when looking for classes.

### BCClassLoader

public BCClassLoader(Project project, ClassLoader loader)
Constructor. Supply the project to use when looking for classes.

Parameters:
  `parent` - the parent classoader

## Method Details

### getProject

public Project getProject()
Return this class loader's project.

### findClass

protected Class findClass(String name) throws ClassNotFoundException

Overrides:
  `findClass` in class `ClassLoader`
Throws:
  `ClassNotFoundException`

### createClass

protected BCClass createClass(String name)
Override this method if unfound classes should be created on-the-fly. Returns null by default.