xpressinsight.create_app
xpressinsight.create_app(app_type: Type[~AppBaseChild], base_dir: str = None, companion_file: str = None, app_work_dir: str = None, insight_work_dir: str = None, preserve_insight_work_dir: bool = False) -> ~AppBaseChild
app_type
|
A subclass of xpressinsight.AppBase.
|
base_dir
|
Path to application base directory (absolute or relative to current working directory). By default, it will be set to the parent directory of the source file that defines the
app_type class.
|
companion_file
|
Path to application companion XML file (absolute or relative to
base_dir). By default, it will be set to the unique XML file that is located in the application base directory.
|
app_work_dir
|
Absolute path to temporary application working directory. By default, it will be set to the subfolder "work_dir" in the application base directory.
|
insight_work_dir
|
Absolute path to temporary Insight working directory. By default, it will be set to the subfolder "work_dir/xpressinsight" in the application base directory.
|
preserve_insight_work_dir
|
Whether to retain any existing content in the temporary Insight working directory. If False (the default), this directory will be emptied by create_app.
|
>>> import xpressinsight as xi ... ... @xi.AppConfig(name="Insight Python App") ... class MyApp(xi.AppBase): ... @xi.ExecModeLoad() ... def load(self): ... print(self.insight.exec_mode, "mode ...") ... ... @xi.ExecModeRun() ... def run(self): ... print(self.insight.exec_mode, "mode ...") ... ... if __name__ == "__main__": ... app = xi.create_app(MyApp) ... sys.exit(app.call_exec_modes(["LOAD", "RUN"]))
© 2001-2025 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.