behave_manners.pagelems.site_collection module¶
-
class
DSiteCollection(loader, config=None)¶ Bases:
behave_manners.pagelems.base_parsers.DPageElementCollection of several HTML pages, like a site
Not supposed to be parsed, but directly instantiated as root hierarchy of all parsed html pageobject files.
-
consume(element)¶
-
get_by_file(fname)¶ Get page by template filename
Returns: pageelem
-
get_by_title(title)¶ Get page by set title
Titles are arbitrary, pretty names assigned to page templates :return: (pageelem, url)
-
get_by_url(url, fragment=None)¶ Find the page template that matches url (path) of browser
returns (page, title, params)
-
get_root_scope()¶ Return new DOMScope bound to self
A DSiteCollection can be reused across runs, but ideally each run should start with a new scope, as returned by this method. Then, this scope should be passed to pages under this site, as those returned by get_by_title() , get_by_url() etc.
-
load_all()¶ Load all referenced pages
Used for forced scan of their content
-
load_galleryfile(pname)¶
-
load_index(pname)¶
-
load_pagefile(pname)¶
-
load_preloads()¶ Load pending preloads or gallery files
-
logger= <Logger site_collection (WARNING)>¶
-
register_link(link)¶
-