org.d2rq.lang
Class ClassMap

java.lang.Object
  extended by org.d2rq.lang.MapObject
      extended by org.d2rq.lang.ResourceMap
          extended by org.d2rq.lang.ClassMap

public class ClassMap
extends ResourceMap

Java class corresponding to d2rq:ClassMap.

Author:
Richard Cyganiak (richard@cyganiak.de)

Constructor Summary
ClassMap(Resource classMapResource)
           
 
Method Summary
 void accept(D2RQMappingVisitor visitor)
           
 void addClass(Resource class_)
           
 void addPropertyBridge(PropertyBridge bridge)
          Adds a property bridge to this class map.
static ClassMap create(Resource id, String uriPattern, Mapping mapping)
          Convenience method for creating class maps.
 Collection<Resource> getClasses()
           
 Database getDatabase()
           
 Collection<PropertyBridge> propertyBridges()
           
 Resource resource()
           
 void setDatabase(Database database)
           
 String toString()
           
 
Methods inherited from class org.d2rq.lang.ResourceMap
addAlias, addCondition, addDefinitionComment, addDefinitionLabel, addDefinitionProperty, addJoin, addValueContains, addValueRegex, getAdditionalDefinitionProperties, getAliases, getBNodeIdColumns, getConditions, getConstantValue, getContainsDuplicates, getDefinitionComments, getDefinitionLabels, getJoins, getTranslateWith, getURIColumn, getURIPattern, getUriSQLExpression, getValueContainses, getValueMaxLength, getValueRegexes, setBNodeIdColumns, setConstantValue, setContainsDuplicates, setTranslateWith, setURIColumn, setURIPattern, setUriSQLExpression, setValueMaxLength
 
Methods inherited from class org.d2rq.lang.MapObject
assertArgumentNotNull, assertNotYetDefined
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassMap

public ClassMap(Resource classMapResource)
Method Detail

create

public static ClassMap create(Resource id,
                              String uriPattern,
                              Mapping mapping)
Convenience method for creating class maps.

Parameters:
id - Identifier for the class map; may be null
uriPattern - URI pattern
mapping - Mapping the class map belongs to; if it has exactly one database, that will be used too

resource

public Resource resource()
Overrides:
resource in class MapObject

getClasses

public Collection<Resource> getClasses()

setDatabase

public void setDatabase(Database database)

getDatabase

public Database getDatabase()
Specified by:
getDatabase in class ResourceMap

addClass

public void addClass(Resource class_)

addPropertyBridge

public void addPropertyBridge(PropertyBridge bridge)
Adds a property bridge to this class map. Usually not invoked directly but through PropertyBridge.setBelongsToClassMap(ClassMap).


propertyBridges

public Collection<PropertyBridge> propertyBridges()

accept

public void accept(D2RQMappingVisitor visitor)
Specified by:
accept in class MapObject

toString

public String toString()
Overrides:
toString in class MapObject