org.apache.jackrabbit.spi.commons.nodetype.compact
Class CompactNodeTypeDefWriter
java.lang.Object
org.apache.jackrabbit.spi.commons.nodetype.compact.CompactNodeTypeDefWriter
public class CompactNodeTypeDefWriter
- extends Object
Prints node type defs in a compact notation
Print Format:
[ex:NodeType] > ex:ParentType1, ex:ParentType2
orderable mixin
- ex:property (STRING) = 'default1', 'default2'
primary mandatory autocreated protected multiple VERSION
< 'constraint1', 'constraint2'
+ ex:node (ex:reqType1, ex:reqType2) = ex:defaultType
mandatory autocreated protected multiple VERSION
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CompactNodeTypeDefWriter
public CompactNodeTypeDefWriter(Writer out,
Session s,
boolean includeNS)
- Creates a new nodetype writer based on a session
- Parameters:
out - the underlaying writers - repository sessionincludeNS - if true all used namespace decl. are also
written to the writer
CompactNodeTypeDefWriter
public CompactNodeTypeDefWriter(Writer out,
NamespaceResolver r,
boolean includeNS)
- Creates a new nodetype writer based on a namespace resolver
- Parameters:
out - the underlaying writerr - the naespace resolverincludeNS - if true all used namespace decl. are also
written to the writer
CompactNodeTypeDefWriter
public CompactNodeTypeDefWriter(Writer out,
NamespaceResolver r,
NamePathResolver npResolver)
- Creates a new nodetype writer that does not include namepsaces.
- Parameters:
out - the underlaying writerr - the naespace resolvernpResolver - name-path resolver
CompactNodeTypeDefWriter
public CompactNodeTypeDefWriter(Writer out,
NamespaceResolver r,
NamePathResolver npResolver,
boolean includeNS)
- Creates a new nodetype writer
- Parameters:
out - the underlying writerr - the namespace resolvernpResolver - name-path resolverincludeNS - if true all used namespace decl. are also
written to the writer
write
public static void write(Collection<? extends QNodeTypeDefinition> defs,
NamespaceResolver r,
NamePathResolver npResolver,
Writer out)
throws IOException
- Writes the given list of QNodeTypeDefinition to the output writer including the
used namespaces.
- Parameters:
defs - collection of definitionsr - namespace resolvernpResolver - name-path resolverout - output writer
- Throws:
IOException - if an I/O error occurs
write
public void write(QNodeTypeDefinition ntd)
throws IOException
- Write one QNodeTypeDefinition to this writer
- Parameters:
ntd - node type definition
- Throws:
IOException - if an I/O error occurs
write
public void write(Collection<? extends QNodeTypeDefinition> defs)
throws IOException
- Write a collection of QNodeTypeDefinitions to this writer
- Parameters:
defs - node type definitions
- Throws:
IOException - if an I/O error occurs
write
public void write(NodeTypeDefinition nt)
throws IOException
- Write one NodeTypeDefinition to this writer
- Parameters:
nt - node type definition
- Throws:
IOException - if an I/O error occurs
close
public void close()
throws IOException
- Flushes all pending write operations and Closes this writer. please note,
that the underlying writer remains open.
- Throws:
IOException - if an I/O error occurs
Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.