msticpy.data.core.query_template module
MSTICPy query template definition.
- class msticpy.data.core.query_template.Query(description: str, args: ~msticpy.data.core.query_template.QueryArgs = <factory>, metadata: ~typing.Dict[str, ~typing.Any] | None = <factory>, parameters: ~typing.Dict[str, ~msticpy.data.core.query_template.QueryParameter] | None = <factory>)
Bases:
object
A Query definition.
- description: str
- metadata: Dict[str, Any] | None
- parameters: Dict[str, QueryParameter] | None
- class msticpy.data.core.query_template.QueryArgs(query: str = '', uri: str | None = None)
Bases:
object
Query arguments.
- query: str = ''
- uri: str | None = None
- class msticpy.data.core.query_template.QueryCollection(metadata: ~msticpy.data.core.query_template.QueryMetadata, defaults: ~msticpy.data.core.query_template.QueryDefaults | None = None, sources: ~typing.Dict[str, ~msticpy.data.core.query_template.Query] = <factory>, file_name: str | None = None)
Bases:
object
Query Collection class - a query template.
- defaults: QueryDefaults | None = None
- file_name: str | None = None
- metadata: QueryMetadata
- class msticpy.data.core.query_template.QueryDefaults(metadata: ~typing.Dict[str, ~typing.Any] | None = None, parameters: ~typing.Dict[str, ~msticpy.data.core.query_template.QueryParameter] = <factory>)
Bases:
object
Default values for query definitions.
- metadata: Dict[str, Any] | None = None
- parameters: Dict[str, QueryParameter]
- class msticpy.data.core.query_template.QueryMetadata(version: int, description: str, data_environments: ~typing.List[str], data_families: ~typing.List[str], database: str | None = None, cluster: str | None = None, clusters: ~typing.List[str] | None = None, cluster_groups: ~typing.List[str] | None = None, tags: ~typing.List[str] = <factory>, data_source: str | None = None, aliases: str | ~typing.List[str] | None = None, query_macros: ~typing.Dict[str, ~typing.Any] | None = None)
Bases:
object
Metadata for query definitions.
- aliases: str | List[str] | None = None
- cluster: str | None = None
- cluster_groups: List[str] | None = None
- clusters: List[str] | None = None
- data_environments: List[str]
- data_families: List[str]
- data_source: str | None = None
- database: str | None = None
- description: str
- query_macros: Dict[str, Any] | None = None
- tags: List[str]
- version: int