net.ontopia.topicmaps.query.impl.basic
Class PredicateFactory

java.lang.Object
  extended by net.ontopia.topicmaps.query.impl.basic.PredicateFactory
All Implemented Interfaces:
PredicateFactoryIF

public class PredicateFactory
extends java.lang.Object
implements PredicateFactoryIF

INTERNAL: The basic predicate factory implementation.


Field Summary
protected  LocatorIF base
           
protected  java.util.Map predicatesById
           
protected  TopicMapIF topicmap
           
 
Constructor Summary
PredicateFactory(TopicMapIF topicmap, LocatorIF base)
           
 
Method Summary
 ModuleIF createModule(java.lang.String uri)
          INTERNAL: Creates a module instance for the specified URI.
 PredicateIF createPredicate(ParsedRule rule)
          INTERNAL: Creates a rule predicate for the parsed rule.
 PredicateIF createPredicate(java.lang.String name)
          INTERNAL: Looks up a built-in predicate by its name.
 PredicateIF createPredicate(TopicIF type, boolean assoc)
          INTERNAL: Creates a dynamic predicate for the given topic; either an association predicate or an occurrence predicate, depending on the value of the assoc parameter.
 boolean isBuiltInPredicate(java.lang.String name)
          INTERNAL: Used to find out if the given predicate name is the name of a built-in predicate.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

predicatesById

protected java.util.Map predicatesById

topicmap

protected TopicMapIF topicmap

base

protected LocatorIF base
Constructor Detail

PredicateFactory

public PredicateFactory(TopicMapIF topicmap,
                        LocatorIF base)
Method Detail

createPredicate

public PredicateIF createPredicate(java.lang.String name)
Description copied from interface: PredicateFactoryIF
INTERNAL: Looks up a built-in predicate by its name.

Specified by:
createPredicate in interface PredicateFactoryIF

createPredicate

public PredicateIF createPredicate(ParsedRule rule)
Description copied from interface: PredicateFactoryIF
INTERNAL: Creates a rule predicate for the parsed rule.

Specified by:
createPredicate in interface PredicateFactoryIF

createPredicate

public PredicateIF createPredicate(TopicIF type,
                                   boolean assoc)
Description copied from interface: PredicateFactoryIF
INTERNAL: Creates a dynamic predicate for the given topic; either an association predicate or an occurrence predicate, depending on the value of the assoc parameter.

Specified by:
createPredicate in interface PredicateFactoryIF

createModule

public ModuleIF createModule(java.lang.String uri)
Description copied from interface: PredicateFactoryIF
INTERNAL: Creates a module instance for the specified URI. If the predicate factory does not recognize the URI null is returned.

Specified by:
createModule in interface PredicateFactoryIF

isBuiltInPredicate

public boolean isBuiltInPredicate(java.lang.String name)
Description copied from interface: PredicateFactoryIF
INTERNAL: Used to find out if the given predicate name is the name of a built-in predicate. Needed for error checking, see bug #1082.

Specified by:
isBuiltInPredicate in interface PredicateFactoryIF


Copyright © 2000-2012 Ontopia.