Exemple #1
0
    def __init__(self, yamlfile, install_dir, package_name, io_handlers,
                 verbose, dryrun):
        self.install_dir = install_dir
        self.package_name = package_name
        self.io_handlers = io_handlers
        self.verbose = verbose
        self.dryrun = dryrun
        self.yamlfile = yamlfile

        self.reader = PodioConfigReader(yamlfile)
        self.reader.read()
        self.include_subfolder = self.reader.options["includeSubfolder"]

        self.env = jinja2.Environment(
            loader=jinja2.FileSystemLoader(TEMPLATE_DIR),
            keep_trailing_newline=True,
            lstrip_blocks=True,
            trim_blocks=True)

        self.get_syntax = self.reader.options["getSyntax"]
        self.incfolder = self.package_name + "/" if self.reader.options[
            "includeSubfolder"] else ""
        self.expose_pod_members = self.reader.options["exposePODMembers"]

        self.clang_format = []
    def __init__(self, yamlfile, install_dir, package_name,
                 verbose=True, getSyntax=False):

        self.yamlfile = yamlfile
        self.install_dir = install_dir
        self.package_name = package_name
        self.template_dir = os.path.join(thisdir, "../templates")
        self.verbose = verbose
        self.getSyntax = getSyntax
        self.buildin_types = ClassDefinitionValidator.buildin_types
        self.created_classes = []
        self.requested_classes = []
        self.reader = PodioConfigReader(yamlfile)
        self.warnings = []