Package rdflib :: Package syntax :: Package serializers :: Module TurtleSerializer :: Class TurtleSerializer
[show private | hide private]
[frames | no frames]

Type TurtleSerializer

        object --+        
                 |        
AbstractSerializer --+    
                     |    
   RecursiveSerializer --+
                         |
                        TurtleSerializer

Known Subclasses:
N3Serializer

Method Summary
  __init__(self, store)
  doList(self, l)
  endDocument(self)
  getQName(self, uri)
  isValidList(self, l)
Checks if l is a valid RDF list, i.e.
  isValidLocalName(self, name)
  label(self, node)
  objectList(self, objects)
  p_default(self, node, ignore)
  p_squared(self, node, position)
  path(self, node, position)
  predicateList(self, subject)
  preprocessTriple(self, triple)
  reset(self)
  s_default(self, subject)
  s_squared(self, subject)
  serialize(self, stream, base, encoding)
Abstract method
  startDocument(self)
  statement(self, subject)
  verb(self, node)
    Inherited from RecursiveSerializer
  addNamespace(self, prefix, uri)
  buildPredicateHash(self, subject)
Build a hash key by predicate to a list of objects for the given subject
  checkSubject(self, subject)
Check to see if the subject should be serialized yet
  indent(self, modifier)
Returns indent string multiplied by the depth
  isDone(self, subject)
Return true if subject is serialized
  orderSubjects(self)
  preprocess(self)
  refCount(self, node)
Return the number of times this node has been referenced in the object position
  sortProperties(self, properties)
Take a hash from predicate uris to lists of values.
  subjectDone(self, subject)
Mark a subject as done.
  write(self, text)
Write text in given encoding.
    Inherited from AbstractSerializer
  relativize(self, uri)
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __repr__(x)
x.__repr__() <==> repr(x)
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)

Class Variable Summary
str indentString = '    '
str short_name = 'turtle'
    Inherited from RecursiveSerializer
int maxDepth = 10                                                                    
list predicateOrder = [u'http://www.w3.org/1999/02/22-rdf-syn...
list topClasses = [u'http://www.w3.org/2000/01/rdf-schema#Cla...

Method Details

isValidList(self, l)

Checks if l is a valid RDF list, i.e. no nodes have other properties.

serialize(self, stream, base=None, encoding=None)

Abstract method
Overrides:
rdflib.syntax.serializers.AbstractSerializer.AbstractSerializer.serialize (inherited documentation)

Class Variable Details

indentString

Type:
str
Value:
'    '                                                                 

short_name

Type:
str
Value:
'turtle'                                                               

Generated by Epydoc 2.1 on Mon Oct 23 14:11:23 2006 http://epydoc.sf.net