Package lexis :: Module wskClass :: Class WSKClass
[show private | hide private]
[frames | no frames]

Class WSKClass


A class.

attribute namespace XML namespace where this class is defined attribute properties list of the property that have this class as domain attribute superClasses list of the parent classes for this class attribute subClasses list of classes that have this class as parent attribute equivalent list of the classes that mean the same entity attribute concrete boolean abstract or concrete attribute deprecated if this class might disappear in the future and should not be used
Method Summary
  __init__(self, namespace, name, domainStruct, **kwargs)
Initialize the WSKClass.
  addEquivalentClass(self, className)
Add a class that is equivalent to this class.
  addProperty(self, property)
Add a property - an 'attribute' - to this class
  addSubClass(self, className)
Add a class that inherit from this class: the class will inherit all properties of this class
  addSuperClass(self, className)
Add a parent class: this class will inherit all the parent's properties
  compile(self)
Prepare the class for its run-time use: copy its parent class properties...
  dump(self)
  getProperties(self)
@Return the list of the properties of this class
  getProperty(self, propertyName)
Return the class property object
  getQName(self)
  hasProperty(self, propertyName)
Check if this class has the given property
  setClassMap(self, classMap)
Set the mapping to the physical storage for this class

Method Details

__init__(self, namespace, name, domainStruct, **kwargs)
(Constructor)

Initialize the WSKClass.
Parameters:
namespace - prefix of XML namespace where this class is defined
name - local name of the class
kwargs - dictionary of the other attributes. They can be: <li>label: label for the tables (if not defined, QName is used) <li>concrete: if abstract or concrete (true by default) <li>deprecated: if the class should not be used anymore (false by default)

addEquivalentClass(self, className)

Add a class that is equivalent to this class. Its name can be used instead of this class
Parameters:
className - name of the equivalent class

addProperty(self, property)

Add a property - an 'attribute' - to this class
Parameters:
property - RDFPropery class instance

addSubClass(self, className)

Add a class that inherit from this class: the class will inherit all properties of this class
Parameters:
className - QName of the subclass [namespace prefix:class name]

addSuperClass(self, className)

Add a parent class: this class will inherit all the parent's properties
Parameters:
className - QName of the parent class [namespace prefix_class name]

compile(self)

Prepare the class for its run-time use: copy its parent class properties...

getProperties(self)

@Return the list of the properties of this class

getProperty(self, propertyName)

Return the class property object
Parameters:
propertyName - QName of the property

hasProperty(self, propertyName)

Check if this class has the given property
Parameters:
propertyName - QName of the property [namspace prefix:property name]
Returns:
true if the class is in the domain of the property (or of one of its parents)

setClassMap(self, classMap)

Set the mapping to the physical storage for this class

Generated by Epydoc 2.0 on Sat Feb 07 21:05:41 2004 http://epydoc.sf.net