2005-03-19 09:28:44

Serialization and Deserialization of setup files.

Copyright 2005 Fourthought, Inc. (USA). Detailed license and copyright information: http://4suite.org/COPYRIGHT Project home, documentation, distributions: http://4suite.org/

For compatibility, same as CopyDir, but returns a complete list, rather than a generator.

Returns a generator of objects representing resources to add to the repository. The resources mirror a current snapshot of a local file system directory.

path = destination repo path (an existing Container) src = file system source path (a directory) must be a valid absolute URI if srcIsUri is True (default) must be a local path if srcIsUri is False fileMap = mapping of filename extensions to resource classes

A tree like /root/dir1/dir2 will be returned as a list like ['/root', '/root/dir1', '/root/dir1/dir2']. Files in each directory will be listed immediately following that directory. So files in dir1 will come before the entry for dir2. Directories are processed breadth-first.

path = destination repo path (an existing Container) src = file system source path (a directory) fileMap = mapping of filename extensions to resource classes resources = list of resource objects to append to

Deserialize a stream that references a setup file by URI

For compatibility, same as MirrorDirGen, but returns a complete list, rather than a generator.

Wrapper for CopyDirGen().

It optionally accepts a 'file' URI for src, and verifies that src refers to a directory. It does not accept an initial list of resources to append to.

Serialize a product list into a string

'http://purl.org/dc/elements/1.1/'
None
{'.gif': 'image/gif', '.htm': 'text/html', '.html': 'text/html', '.jpeg': 'image/jpeg', '.jpg': 'image/jpeg', '.png': 'image/png', '.rdf': 'text/xml', '.svg': 'image/svg', '.xhtml': 'text/html', '.xml': 'text/xml', ...}
'http://xmlns.4suite.org/reserved#product'
'.htm'
{'.daml': (None, None, <class Ft.Server.Common.Install.InstallUtil.RdfDocument>), '.gif': (None, 'image/gif', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.htm': (None, 'text/html', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.html': (None, 'text/html', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.jpeg': (None, 'image/jpeg', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.jpg': (None, 'image/jpeg', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.owl': (None, None, <class Ft.Server.Common.Install.InstallUtil.RdfDocument>), '.png': (None, 'image/png', <class Ft.Server.Common.Install.InstallUtil.RawFile>), '.rdf': (None, None, <class Ft.Server.Common.Install.InstallUtil.RdfDocument>), '.rdfs': (None, None, <class Ft.Server.Common.Install.InstallUtil.RdfDocument>), ...}
{'Command': <class Ft.Server.Common.Install.InstallUtil.Command>, 'RdfDocument': <class Ft.Server.Common.Install.InstallUtil.RdfDocument>, 'SchematronDocument': <class Ft.Server.Common.Install.InstallUtil.SchematronDocument>, 'Server': <class Ft.Server.Common.Install.InstallUtil.Server>, 'XPathDocumentDefinition': <class Ft.Server.Common.Install.InstallUtil.XPathDocumentDefinition>, 'XmlDocument': <class Ft.Server.Common.Install.InstallUtil.XmlDocument>, 'XsltDocument': <class Ft.Server.Common.Install.InstallUtil.XsltDocument>, 'XsltDocumentDefinition': <class Ft.Server.Common.Install.InstallUtil.XsltDocumentDefinition>}
{4: 'XmlDocument', 5: 'XsltDocument', 6: 'SchematronDocument', 9: 'XPathDocumentDefinition', 11: 'XsltDocumentDefinition', 12: 'RdfDocument', 14: 'Command', 15: 'Server'}
_Feature((2, 2, 0, 'alpha', 1), (2, 3, 0, 'final', 0), 4096)
'text/html'