class documentation

class FilesLayout(NotebookLayout): (source)

View In Hierarchy

Layout is responsible for mapping between pages and files. This is the most basic version, where each page maps to the like-named file.
Method __init__ Constructor @param folder: a Folder object @param endofline: either "dos" or "unix", default per OS
Method get_attachments_folder Undocumented
Method get_format Undocumented
Method index_list_children Undocumented
Method is_source_file Undocumented
Method map_file No summary
Method map_filepath Like map_file but takes a string with relative path
Method map_page No summary
Method resolve_conflict No summary
Instance Variable default_extension Undocumented
Instance Variable default_format Undocumented
Instance Variable endofline Undocumented
Instance Variable root Undocumented
def __init__(self, folder, endofline=_EOL, default_format='wiki', default_extension='.txt'): (source)
Constructor
Parameters
foldera Folder object
endoflineeither "dos" or "unix", default per OS
default_formatUndocumented
default_extensionUndocumented
def get_attachments_folder(self, pagename): (source)

Undocumented

def get_format(self, file): (source)

Undocumented

def index_list_children(self, pagename): (source)

Undocumented

def is_source_file(self, file): (source)

Undocumented

def map_file(self, file): (source)
def map_filepath(self, path): (source)
Like map_file but takes a string with relative path
def map_page(self, pagename): (source)
Map a pagename to a (default) file
Parameters
pagenamea Path
Returns
a 2-tuple of a File for the source and a Folder for the attachments. Neither of these needs to exist.
def resolve_conflict(self, *filepaths): (source)
Decide which is the real page file when multiple files map to the same page.
Parameters
*filepaths2 or more FilePath objects
Returns
FilePath that should take precedent as te page source
default_extension = (source)

Undocumented

default_format = (source)

Undocumented

endofline = (source)

Undocumented

root = (source)

Undocumented