def __init__(self, options): self.document_path = options['document_path'] self.resource_path = options['resource_path'] self.output_path = options['output_path'] self.options = options nib.plugins.load(options) nib.instance(self)
def __init__(self, path=None, uri=None, group=None, content=None, short=None, **kwargs): options = nib.instance().options defaults = options['defaults'] for key in defaults: kwargs.setdefault(key, defaults[key]) dict.__init__(self, **kwargs) self.path, self.extension = os.path.splitext(path) self.uri = uri self.group = group self.content = content self.short = short or content