[ { "module": "meta", "function": "CompileScript", "input": [ { "name": "fileInput", "type": "str", "description": "The path of the script that we want to compile.", "optional": false }, { "name": "fileOutput", "type": "str", "description": "The destination path of the created compiled file.", "optional": false }, { "name": "moduleName", "type": "str", "description": "The name of the module.", "optional": false }, { "name": "mode", "type": "bool", "description": "Declares whether to include the input script\u2019s imported modules, inside the final comp "optional": true } ], "output": { "type": "int", "description": "Returns 1 on success, 0 on failure." }, "deprecated": null, "example": "import meta\n\ndef main():\n meta.CompileScript(\n \"/home/user/scripts/some_script.py\ }, { "module": "meta", "function": "ImportCode", "input": [ { "name": "path", "type": "str", "description": "The name of the script file to import.", "optional": false } ], "output": { "type": "int", "description": "Returns 0 on success, else an exception is raised." }, "deprecated": null, "example": "import meta\n\nfile1 = \"/home/demo/module1.pyb\"\nfile2 = \"C:\\\\demo\\\\module2.pyb\"\n\nm }, { "module": "meta", "function": "PybImport", "input": [ { "name": "module_name", "type": "str", "description": "The name of the module.", "optional": false }, { "name": "script_file_path", "type": "str", "description": "The filepath of the script.", "optional": false } ], "output": { "type": "ModuleType", "description": "Returns the imported module." }, "deprecated": null, "example": "import meta\n\ndef main():\n x = meta.PybImport(\"moduleName\", \"/module/file/path/module }, { "module": "meta", "function": "ReadingFile", "input": [], "output": { "type": "str", "description": "Returns the currently reading physical file on disk." }, "deprecated": null, "example": "import meta\n\ndef main():\n x = meta.ReadingFile()\n print(x)" }, { "module": "meta", "function": "ScriptCurrentDir", "input": [], "output": { "type": "str", "description": "Returns the current working directory." }, "deprecated": null, "example": "import meta\n\ndef main():\n print(meta.ScriptCurrentDir())" }, { "module": "meta", "function": "ScriptHomeDir", "input": [], "output": { "type": "str", "description": "Returns the ANSA/META Home directory path." }, "deprecated": { "version": "Use:meta.constants.app_root_dirinstead", "message": "Use:meta.constants.app_root_dirinstead" }, "example": "import meta\n\ndef main():\n print(meta.ScriptHomeDir())" }, { "module": "meta", "function": "ScriptUserDir", "input": [], "output": { "type": "str", "description": "Returns the BetaHome directory path." }, "deprecated": { "version": "Use:meta.constants.app_home_dirinstead", "message": "Deprecated since version Use:meta.constants.app_home_dirinstead." }, "example": "import meta\n\ndef main():\n print(meta.ScriptUserDir())" }, { "module": "meta.annotations", "function": "AnchorTypeOfAnnotation", "input": [ { "name": "annotation_id", "type": "int", "description": "Id of the annotation." } ], "output": { "type": "str", "description": "Upon success, it returns a string referring to the type of the annotation pointer.Possible retur }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_anchor_type() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_id }, { "module": "meta.annotations", "function": "AnnotationById", "input": [ { "name": "annotation_id", "type": "int", "description": "Id of the annotation." } ], "output": { "type": "Annotation", "description": "Upon success, it returns an object of class Annotation with the given id.Else, a non valid Ann }, "deprecated": { "version": "20.1.0", "message": "Use meta.pages.Page.get_annotations() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_id }, { "module": "meta.annotations", "function": "AnnotationGroups", "input": [], "output": { "type": "AnnotationGroup", "description": "It returns a list wwhere each member of the list is an object of class AnnotationGroup referrin }, "deprecated": { "version": "20.1.0", "message": "Use meta.pages.Page.get_annotation_groups() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_g }, { "module": "meta.annotations", "function": "AnnotationGroupsByName", "input": [ { "name": "group_name", "type": "str", "description": "Name of the group. Wildcards can also be used (\u201c*\u201d, \u201c?\u201d, \u201c[\u20 "optional": false } ], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class AnnotationGroup referring }, "deprecated": { "version": "20.1.0", "message": "Use meta.pages.Page.get_annotation_groups() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n group_name }, { "module": "meta.annotations", "function": "AnnotationGroupsOfWindow", "input": [ { "name": "window_name", "type": "str", "description": "Name of the window." } ], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class AnnotationGroup referring }, "deprecated": { "version": "20.1.0", "message": "Use meta.windows.Window.get_annotation_groups() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n window_nam }, { "module": "meta.annotations", "function": "Annotations", "input": [], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class Annotation referring to one }, "deprecated": { "version": "20.1.0", "message": "Use meta.pages.Page.get_annotations() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n all_annotatio }, { "module": "meta.annotations", "function": "AnnotationsListToDict", "input": [ { "name": "annotations", "type": "list[meta.annotations.Annotation]", "description": "List with objects of class Annotation." } ], "output": { "type": "dict", "description": "It returns a dictionary whose key is the id of the annotation and member is the corresponding }, "deprecated": null, "example": "# PYTHON object\nimport meta\nfrom meta import annotations\n\ndef main():\n all_annotatio }, { "module": "meta.annotations", "function": "AnnotationsOfGroup", "input": [ { "name": "group_name", "type": "str", "description": "Name of the annotation group." } ], "output": { "type": "list[Annotation]", "description": "Upon success, it returns a list where each member of the list is an object of class Annotation }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.AnnotationGroup.get_annotations() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n group_name }, { "module": "meta.annotations", "function": "AnnotationsOfOverlayRun", "input": [ { "name": "overlay_run_id", "type": "int", "description": "Id of the overlay run." }, { "name": "overlay_run_type", "type": "str", "description": "Type of the overlay run:- \u2018session\u2019- \u2018project\u2019" } ], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class Annotation referring to one }, "deprecated": { "version": "20.1.0", "message": "Use meta.overlay.Overlay.get_annotations() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n overlay_run_ }, { "module": "meta.annotations", "function": "AnnotationsOfWindow", "input": [ { "name": "window_name", "type": "str", "description": "Name of the window." } ], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class Annotation referring to one }, "deprecated": { "version": "20.1.0", "message": "Use meta.windows.Window.get_annotations() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n window_nam }, { "module": "meta.annotations", "function": "AttributeOfAnnotation", "input": [ { "name": "annot_id", "type": "int", "description": "The id of the annotation" }, { "name": "attrib_name", "type": "str", "description": "Name of the attribute" } ], "output": { "type": "str", "description": "Upon success, it returns a string with the value of the given argument.Else, an empty string i }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_attributes() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n name = \"Typ }, { "module": "meta.annotations", "function": "AttributesOfAnnotations", "input": [ { "name": "annot_id", "type": "int", "description": "The id of the annotation" } ], "output": { "type": "list", "description": "It returns a list where each member of the list is another list referring to one specific attribute }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_attributes() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annot_id = 1\ }, { "module": "meta.annotations", "function": "BackgroundColorOfAnnotation", "input": [ { "name": "annotation_id", "type": "int", "description": "Id of the annotation." } ], "output": { "type": "windows.Color", "description": "Upon success, it returns a color object with the background color of the corresponding annot }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_background_color() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_id }, { "module": "meta.annotations", "function": "BorderColorOfAnnotation", "input": [ { "name": "annotation_id", "type": "int", "description": "Id of the annotation." } ], "output": { "type": "windows.Color", "description": "Upon success, it returns a color object with the border color of the corresponding annotation }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_border_color() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_id }, { "module": "meta.annotations", "function": "BoundaryOfAnnotationPointer", "input": [ { "name": "annotation_id", "type": "int", "description": "Id of the annotation." } ], "output": { "type": "boundaries.Boundary", "description": "Upon success, it returns a boundary object with the boundary element of the pointer of the g }, "deprecated": { "version": "20.1.0", "message": "Use meta.annotations.Annotation.get_boundary() instead." }, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n annotation_id }, { "module": "meta.annotations", "function": "CollectNewAnnotationsEnd", "input": [], "output": { "type": "list[Annotation]", "description": "It returns a list where each member of the list is an object of class Annotation referring to one }, "deprecated": null, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\nfrom meta import utils\n\ndef m }, { "module": "meta.annotations", "function": "CollectNewAnnotationsStart", "input": [], "output": { "type": "int", "description": "It returns 1 upon success and 0 upon failure." }, "deprecated": null, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\nfrom meta import utils\n\ndef m }, { "module": "meta.annotations", "function": "CreateEmptyAnnotation", "input": [ { "name": "window_name", "type": "str", "description": "Name of the window." }, { "name": "annotation_text", "type": "str", "description": "Text of the annotation." }, { "name": "annotation_id", "type": "int", "description": "Id of the annotation. If there is an annotation with the given id then this function will fail. If op } ], "output": { "type": "Annotation", "description": "Upon success, it returns an object of class Annotation referring to the newly created annotat }, "deprecated": null, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n window_nam }, { "module": "meta.annotations", "function": "CreateEmptyAnnotationOnPlot", "input": [ { "name": "window_name", "type": "str", "description": "Name of the window." }, { "name": "plot_id", "type": "int", "description": "Id of the plot." }, { "name": "annotation_text", "type": "str", "description": "Text of the annotation." }, { "name": "annotation_id", "type": "int", "description": "Id of the annotation. If there is an annotation with the given id then this function will fail. If op } ], "output": { "type": "Annotation", "description": "Upon success, it returns an object of class Annotation referring to the newly created annotat }, "deprecated": null, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n window_nam }, { "module": "meta.annotations", "function": "CreateSomeEmptyAnnotations", "input": [ { "name": "window_names", "type": "list[str]", "description": "List with names of the windows." }, { "name": "annotation_texts", "type": "list[str]", "description": "List with texts of the annotations." }, { "name": "annotation_ids", "type": "list[int]", "description": "List with ids of the annotations. If there is an annotation with the given id then this function w "optional": true } ], "output": { "type": "list[Annotation]", "description": "Upon success, it returns a list with objects of class Annotation referring to the newly created }, "deprecated": null, "example": "# PYTHON script\nimport meta\nfrom meta import annotations\n\ndef main():\n list_window_ }, { "module": "meta.annotations", "function": "CreateSomeEmptyAnnotationsOnPlot", "input": [ { "name": "window_names",