Prolog Cafe v1.2

jp.ac.kobe_u.cs.prolog.lang
Class PrologClassLoader

java.lang.Object
  extended by java.lang.ClassLoader
      extended by jp.ac.kobe_u.cs.prolog.lang.PrologClassLoader
All Implemented Interfaces:
java.io.Serializable

public class PrologClassLoader
extends java.lang.ClassLoader
implements java.io.Serializable

Prolog class loader.

See Also:
Serialized Form

Constructor Summary
PrologClassLoader()
           
 
Method Summary
 boolean definedPredicate(java.lang.String pkg, java.lang.String functor, int arity)
          Check whether the predicate class for the given arguments is defined.
 java.lang.Class findClass(java.lang.String name)
           
 java.lang.Class loadPredicateClass(java.lang.String pkg, java.lang.String functor, int arity, boolean resolve)
          Returns a java.lang.Class object associated with the predicate class with the given arguments.
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrologClassLoader

public PrologClassLoader()
Method Detail

loadPredicateClass

public java.lang.Class loadPredicateClass(java.lang.String pkg,
                                          java.lang.String functor,
                                          int arity,
                                          boolean resolve)
                                   throws java.lang.ClassNotFoundException
Returns a java.lang.Class object associated with the predicate class with the given arguments.

Parameters:
pkg - package name
functor - predicate name
arity - predicate arity
resolve - If true then resolve the class
Returns:
a java.lang.Class object associated with the predicate class that corresponds to pkg:functor/arity if exists, otherwise throws ClassNotFoundException.
Throws:
java.lang.ClassNotFoundException

definedPredicate

public boolean definedPredicate(java.lang.String pkg,
                                java.lang.String functor,
                                int arity)
Check whether the predicate class for the given arguments is defined.

Parameters:
pkg - package name
functor - predicate name
arity - predicate arity
Returns:
true if the predicate pkg:functor/arity is defined, otherwise false.

findClass

public java.lang.Class findClass(java.lang.String name)
                          throws java.lang.ClassNotFoundException
Overrides:
findClass in class java.lang.ClassLoader
Throws:
java.lang.ClassNotFoundException

Prolog Cafe v1.2

Copyright (C) 1997-2008 M.BANBARA and N.TAMURA