acceldata-sdk-python 26.7.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- acceldata/__init__.py +7 -0
- acceldata/client/__init__.py +0 -0
- acceldata/client/adoc_client.py +666 -0
- acceldata/client/http_client.py +346 -0
- acceldata/client/transient_retry.py +142 -0
- acceldata/constants/__init__.py +1 -0
- acceldata/constants/constants.py +13 -0
- acceldata/exceptions/__init__.py +52 -0
- acceldata/exceptions/api_errors.py +85 -0
- acceldata/exceptions/exceptions.py +174 -0
- acceldata/exceptions/sdk_exceptions.py +98 -0
- acceldata/mappers/__init__.py +21 -0
- acceldata/mappers/catalog_executions.py +107 -0
- acceldata/models/__init__.py +0 -0
- acceldata/models/api/catalog/above_configs.py +99 -0
- acceldata/models/api/catalog/above_configs_success.py +138 -0
- acceldata/models/api/catalog/absolute_configs.py +197 -0
- acceldata/models/api/catalog/absolute_configs_fallback.py +101 -0
- acceldata/models/api/catalog/absolute_threshold_config.py +105 -0
- acceldata/models/api/catalog/analysis_job_context.py +102 -0
- acceldata/models/api/catalog/analytics_pipeline.py +385 -0
- acceldata/models/api/catalog/analytics_pipeline_endpoint.py +136 -0
- acceldata/models/api/catalog/anomaly_config.py +95 -0
- acceldata/models/api/catalog/anomaly_details.py +119 -0
- acceldata/models/api/catalog/anomaly_threshold_config.py +105 -0
- acceldata/models/api/catalog/artifact.py +92 -0
- acceldata/models/api/catalog/assembly.py +171 -0
- acceldata/models/api/catalog/asset.py +162 -0
- acceldata/models/api/catalog/asset_catalog_listing.py +159 -0
- acceldata/models/api/catalog/asset_catalog_listing_response.py +102 -0
- acceldata/models/api/catalog/asset_label_request.py +96 -0
- acceldata/models/api/catalog/asset_progress.py +96 -0
- acceldata/models/api/catalog/asset_progress_details.py +117 -0
- acceldata/models/api/catalog/asset_tag.py +124 -0
- acceldata/models/api/catalog/asset_tag_info.py +140 -0
- acceldata/models/api/catalog/asset_tag_request.py +95 -0
- acceldata/models/api/catalog/asset_tag_response.py +96 -0
- acceldata/models/api/catalog/asset_tags_response.py +102 -0
- acceldata/models/api/catalog/asset_type.py +96 -0
- acceldata/models/api/catalog/auto_anomaly_feature_analysis.py +160 -0
- acceldata/models/api/catalog/auto_anomaly_item_execution.py +133 -0
- acceldata/models/api/catalog/auto_anomaly_meta_data.py +162 -0
- acceldata/models/api/catalog/auto_anomaly_rule_execution.py +102 -0
- acceldata/models/api/catalog/auto_anomaly_summary.py +124 -0
- acceldata/models/api/catalog/backing_asset.py +126 -0
- acceldata/models/api/catalog/below_configs.py +99 -0
- acceldata/models/api/catalog/big_decimal.py +100 -0
- acceldata/models/api/catalog/big_integer.py +98 -0
- acceldata/models/api/catalog/bounds_date_time_marker_config.py +110 -0
- acceldata/models/api/catalog/bounds_file_event_marker_config.py +108 -0
- acceldata/models/api/catalog/bounds_id_marker_config.py +96 -0
- acceldata/models/api/catalog/catalog_asset_meta_data.py +128 -0
- acceldata/models/api/catalog/changes_by_config.py +105 -0
- acceldata/models/api/catalog/column_mapping.py +139 -0
- acceldata/models/api/catalog/column_metadata.py +90 -0
- acceldata/models/api/catalog/column_metric_with_anomaly_details.py +119 -0
- acceldata/models/api/catalog/column_variable.py +111 -0
- acceldata/models/api/catalog/composite_policy_execution.py +102 -0
- acceldata/models/api/catalog/composite_policy_item_execution.py +104 -0
- acceldata/models/api/catalog/connection.py +118 -0
- acceldata/models/api/catalog/connection_test_result.py +106 -0
- acceldata/models/api/catalog/connection_type.py +90 -0
- acceldata/models/api/catalog/connection_types_response.py +96 -0
- acceldata/models/api/catalog/crawler.py +88 -0
- acceldata/models/api/catalog/crawler_action_response.py +90 -0
- acceldata/models/api/catalog/crawler_execution.py +147 -0
- acceldata/models/api/catalog/crawler_execution_response.py +102 -0
- acceldata/models/api/catalog/crawler_status_response.py +90 -0
- acceldata/models/api/catalog/create_profile.py +194 -0
- acceldata/models/api/catalog/custom_sql_config.py +121 -0
- acceldata/models/api/catalog/data_bricks_spark_resource_config.py +104 -0
- acceldata/models/api/catalog/data_cadence_rule.py +236 -0
- acceldata/models/api/catalog/data_cadence_rule_details.py +125 -0
- acceldata/models/api/catalog/data_cadence_rule_execution.py +102 -0
- acceldata/models/api/catalog/data_cadence_rule_item.py +104 -0
- acceldata/models/api/catalog/data_cadence_rule_item_execution.py +158 -0
- acceldata/models/api/catalog/data_cadence_rule_response.py +98 -0
- acceldata/models/api/catalog/data_drift_execution.py +102 -0
- acceldata/models/api/catalog/data_drift_item_execution.py +121 -0
- acceldata/models/api/catalog/data_quality_engine.py +90 -0
- acceldata/models/api/catalog/data_quality_execution.py +106 -0
- acceldata/models/api/catalog/data_quality_rule.py +323 -0
- acceldata/models/api/catalog/data_quality_rule_details.py +186 -0
- acceldata/models/api/catalog/data_quality_rule_response.py +120 -0
- acceldata/models/api/catalog/data_quality_rules_response.py +102 -0
- acceldata/models/api/catalog/databricks_compute_config.py +113 -0
- acceldata/models/api/catalog/dataplane_engine.py +105 -0
- acceldata/models/api/catalog/dataplane_health_metrics.py +101 -0
- acceldata/models/api/catalog/dataplane_job.py +216 -0
- acceldata/models/api/catalog/dataplane_job_status.py +113 -0
- acceldata/models/api/catalog/dataplane_request.py +96 -0
- acceldata/models/api/catalog/dataproc_compute_config.py +106 -0
- acceldata/models/api/catalog/dataproc_spark_resource_config.py +104 -0
- acceldata/models/api/catalog/date_based_partition_marker_config.py +116 -0
- acceldata/models/api/catalog/date_partitioning_marker_config.py +113 -0
- acceldata/models/api/catalog/date_time_marker_config.py +109 -0
- acceldata/models/api/catalog/day_month_year_based_partition_marker_config.py +124 -0
- acceldata/models/api/catalog/decreased_by_config.py +105 -0
- acceldata/models/api/catalog/delete_artifact_response.py +88 -0
- acceldata/models/api/catalog/dq_rule_execution.py +248 -0
- acceldata/models/api/catalog/drift.py +121 -0
- acceldata/models/api/catalog/enable_rule_request.py +88 -0
- acceldata/models/api/catalog/engine.py +90 -0
- acceldata/models/api/catalog/execution_cancellation_response.py +92 -0
- acceldata/models/api/catalog/execution_response.py +144 -0
- acceldata/models/api/catalog/execution_result.py +126 -0
- acceldata/models/api/catalog/executions_response.py +102 -0
- acceldata/models/api/catalog/failed_asset_detail.py +90 -0
- acceldata/models/api/catalog/failed_summary.py +98 -0
- acceldata/models/api/catalog/file.py +94 -0
- acceldata/models/api/catalog/file_marker_config.py +99 -0
- acceldata/models/api/catalog/generic_config_fallback.py +101 -0
- acceldata/models/api/catalog/generic_execution.py +221 -0
- acceldata/models/api/catalog/generic_rule_execution.py +137 -0
- acceldata/models/api/catalog/global_storage_config_dto.py +172 -0
- acceldata/models/api/catalog/hosted_dp_deployment_response.py +98 -0
- acceldata/models/api/catalog/id_marker_config.py +94 -0
- acceldata/models/api/catalog/increased_by_config.py +105 -0
- acceldata/models/api/catalog/item.py +160 -0
- acceldata/models/api/catalog/item_execution.py +192 -0
- acceldata/models/api/catalog/item_segment.py +131 -0
- acceldata/models/api/catalog/job_schedule.py +118 -0
- acceldata/models/api/catalog/job_spec.py +96 -0
- acceldata/models/api/catalog/kubernetes_metrics.py +91 -0
- acceldata/models/api/catalog/label.py +97 -0
- acceldata/models/api/catalog/livy_compute_config.py +103 -0
- acceldata/models/api/catalog/livy_spark_resource_config.py +106 -0
- acceldata/models/api/catalog/look_back_config.py +90 -0
- acceldata/models/api/catalog/manual_tag_request.py +92 -0
- acceldata/models/api/catalog/mapping.py +97 -0
- acceldata/models/api/catalog/marker.py +88 -0
- acceldata/models/api/catalog/marker_config.py +349 -0
- acceldata/models/api/catalog/marker_config_fallback.py +101 -0
- acceldata/models/api/catalog/meta.py +92 -0
- acceldata/models/api/catalog/meta_data.py +92 -0
- acceldata/models/api/catalog/meta_data_item.py +94 -0
- acceldata/models/api/catalog/mini_profile_request.py +112 -0
- acceldata/models/api/catalog/notification_payload.py +114 -0
- acceldata/models/api/catalog/offset_based_marker_config.py +97 -0
- acceldata/models/api/catalog/operational_config.py +92 -0
- acceldata/models/api/catalog/pattern_configuration.py +90 -0
- acceldata/models/api/catalog/pipe_line_request.py +92 -0
- acceldata/models/api/catalog/pipeline_compute_config.py +110 -0
- acceldata/models/api/catalog/policy_execution_marker_config.py +94 -0
- acceldata/models/api/catalog/policy_execution_request.py +229 -0
- acceldata/models/api/catalog/policy_group.py +114 -0
- acceldata/models/api/catalog/policy_transform_udf.py +113 -0
- acceldata/models/api/catalog/process_metrics.py +91 -0
- acceldata/models/api/catalog/profile_anomaly_details_response.py +109 -0
- acceldata/models/api/catalog/profile_anomaly_item_execution.py +127 -0
- acceldata/models/api/catalog/profile_anomaly_rule_execution.py +102 -0
- acceldata/models/api/catalog/profile_anomaly_rule_item.py +109 -0
- acceldata/models/api/catalog/profile_cancellation_response.py +92 -0
- acceldata/models/api/catalog/profile_request.py +211 -0
- acceldata/models/api/catalog/profile_request_response.py +92 -0
- acceldata/models/api/catalog/property_template.py +178 -0
- acceldata/models/api/catalog/property_templates.py +123 -0
- acceldata/models/api/catalog/pub_sub_lookback_marker_config.py +96 -0
- acceldata/models/api/catalog/pub_sub_timestamp_marker_config.py +108 -0
- acceldata/models/api/catalog/quality_rule.py +381 -0
- acceldata/models/api/catalog/quality_rule_execution_metrics.py +114 -0
- acceldata/models/api/catalog/quality_rule_with_latest_execution.py +115 -0
- acceldata/models/api/catalog/range_configs.py +109 -0
- acceldata/models/api/catalog/reconciliation_item.py +102 -0
- acceldata/models/api/catalog/reconciliation_item_execution.py +157 -0
- acceldata/models/api/catalog/reconciliation_rule.py +339 -0
- acceldata/models/api/catalog/reconciliation_rule_details.py +225 -0
- acceldata/models/api/catalog/reconciliation_rule_execution.py +102 -0
- acceldata/models/api/catalog/reconciliation_rule_response.py +98 -0
- acceldata/models/api/catalog/reconciliation_rules_response.py +102 -0
- acceldata/models/api/catalog/relative_config.py +197 -0
- acceldata/models/api/catalog/relative_config_fallback.py +101 -0
- acceldata/models/api/catalog/relative_threshold_config.py +111 -0
- acceldata/models/api/catalog/root_cause_analysis.py +108 -0
- acceldata/models/api/catalog/rule_execution.py +327 -0
- acceldata/models/api/catalog/rule_execution_result.py +90 -0
- acceldata/models/api/catalog/rule_item_result.py +125 -0
- acceldata/models/api/catalog/rule_meta_data.py +94 -0
- acceldata/models/api/catalog/rule_spark_sql_dynamic_filter_variable_mapping.py +100 -0
- acceldata/models/api/catalog/rule_tag.py +101 -0
- acceldata/models/api/catalog/rule_threshold_configuration.py +236 -0
- acceldata/models/api/catalog/rule_threshold_configuration_fallback.py +101 -0
- acceldata/models/api/catalog/rules_with_latest_execution_response.py +102 -0
- acceldata/models/api/catalog/sample_data_api_response.py +122 -0
- acceldata/models/api/catalog/schema_drift_item_execution.py +131 -0
- acceldata/models/api/catalog/schema_drift_rule_execution.py +102 -0
- acceldata/models/api/catalog/secret_manager_configuration.py +90 -0
- acceldata/models/api/catalog/secret_manager_configuration_with_option.py +98 -0
- acceldata/models/api/catalog/security_config.py +90 -0
- acceldata/models/api/catalog/segment_metric_json.py +142 -0
- acceldata/models/api/catalog/segments_analysis.py +145 -0
- acceldata/models/api/catalog/short_segment.py +97 -0
- acceldata/models/api/catalog/simple_quality_rule_response.py +92 -0
- acceldata/models/api/catalog/snapshot_data.py +117 -0
- acceldata/models/api/catalog/source_model.py +90 -0
- acceldata/models/api/catalog/source_type.py +100 -0
- acceldata/models/api/catalog/source_types_response.py +102 -0
- acceldata/models/api/catalog/spark_job_status.py +113 -0
- acceldata/models/api/catalog/spark_resource_config.py +114 -0
- acceldata/models/api/catalog/standard_response_assembly.py +92 -0
- acceldata/models/api/catalog/standard_response_crawler_action_response.py +92 -0
- acceldata/models/api/catalog/standard_response_crawler_status_response.py +92 -0
- acceldata/models/api/catalog/standard_response_delete_artifact_response.py +92 -0
- acceldata/models/api/catalog/standard_response_list.py +96 -0
- acceldata/models/api/catalog/standard_response_map.py +88 -0
- acceldata/models/api/catalog/standard_response_meta_data.py +92 -0
- acceldata/models/api/catalog/standard_response_mini_profile_request.py +92 -0
- acceldata/models/api/catalog/standard_response_profile_request.py +92 -0
- acceldata/models/api/catalog/start_profiling_request.py +92 -0
- acceldata/models/api/catalog/tag_domain.py +116 -0
- acceldata/models/api/catalog/threshold_breach_details.py +101 -0
- acceldata/models/api/catalog/time_based_config.py +92 -0
- acceldata/models/api/catalog/time_based_threshold_config.py +105 -0
- acceldata/models/api/catalog/timestamp_based_marker_config.py +115 -0
- acceldata/models/api/catalog/udf_variable.py +97 -0
- acceldata/models/api/catalog/yunikorn_compute_config.py +133 -0
- acceldata/models/api/catalog/yunikorn_spark_resource_config.py +154 -0
- acceldata/models/api/pipeline/big_decimal.py +100 -0
- acceldata/models/api/pipeline/big_integer.py +98 -0
- acceldata/models/api/pipeline/child_span_response.py +96 -0
- acceldata/models/api/pipeline/create_span_event.py +109 -0
- acceldata/models/api/pipeline/edge.py +108 -0
- acceldata/models/api/pipeline/event_alert_object.py +95 -0
- acceldata/models/api/pipeline/generic_config_fallback.py +101 -0
- acceldata/models/api/pipeline/identifier.py +146 -0
- acceldata/models/api/pipeline/job_request.py +130 -0
- acceldata/models/api/pipeline/meta.py +107 -0
- acceldata/models/api/pipeline/meta_data.py +92 -0
- acceldata/models/api/pipeline/metric.py +103 -0
- acceldata/models/api/pipeline/node.py +201 -0
- acceldata/models/api/pipeline/node_response.py +92 -0
- acceldata/models/api/pipeline/notification_payload.py +114 -0
- acceldata/models/api/pipeline/pipeline.py +152 -0
- acceldata/models/api/pipeline/pipeline_baseline_metric.py +92 -0
- acceldata/models/api/pipeline/pipeline_details.py +118 -0
- acceldata/models/api/pipeline/pipeline_details_response.py +102 -0
- acceldata/models/api/pipeline/pipeline_input_request.py +92 -0
- acceldata/models/api/pipeline/pipeline_listing_info.py +118 -0
- acceldata/models/api/pipeline/pipeline_response.py +92 -0
- acceldata/models/api/pipeline/pipeline_run.py +136 -0
- acceldata/models/api/pipeline/pipeline_run_request.py +92 -0
- acceldata/models/api/pipeline/pipeline_runs_response.py +102 -0
- acceldata/models/api/pipeline/pipeline_summary.py +98 -0
- acceldata/models/api/pipeline/pipelines_listing_response.py +102 -0
- acceldata/models/api/pipeline/policy_summary.py +102 -0
- acceldata/models/api/pipeline/span.py +115 -0
- acceldata/models/api/pipeline/span_event.py +114 -0
- acceldata/models/api/pipeline/span_event_request.py +92 -0
- acceldata/models/api/pipeline/span_event_response.py +92 -0
- acceldata/models/api/pipeline/span_request.py +94 -0
- acceldata/models/api/pipeline/spans_response.py +96 -0
- acceldata/models/api/pipeline/tag.py +97 -0
- acceldata/models/sdk/__init__.py +0 -0
- acceldata/models/sdk/catalog/__init__.py +105 -0
- acceldata/models/sdk/catalog/asset_resource.py +112 -0
- acceldata/models/sdk/catalog/asset_source_type.py +59 -0
- acceldata/models/sdk/catalog/custom_asset_metadata.py +11 -0
- acceldata/models/sdk/catalog/datasource_resource.py +88 -0
- acceldata/models/sdk/catalog/executor.py +524 -0
- acceldata/models/sdk/catalog/policy_execution_request.py +114 -0
- acceldata/models/sdk/catalog/policy_execution_type.py +16 -0
- acceldata/models/sdk/catalog/policy_filter.py +94 -0
- acceldata/models/sdk/catalog/policy_rule_resources.py +388 -0
- acceldata/models/sdk/catalog/profile_request_resource.py +77 -0
- acceldata/models/sdk/catalog/profiling.py +82 -0
- acceldata/models/sdk/catalog/profiling_configuration_error.py +5 -0
- acceldata/models/sdk/pipeline/__init__.py +62 -0
- acceldata/models/sdk/pipeline/create_job_input.py +108 -0
- acceldata/models/sdk/pipeline/create_pipeline_input_request.py +72 -0
- acceldata/models/sdk/pipeline/events/__init__.py +5 -0
- acceldata/models/sdk/pipeline/events/generic_event.py +31 -0
- acceldata/models/sdk/pipeline/events/log_event.py +34 -0
- acceldata/models/sdk/pipeline/events/span_event.py +8 -0
- acceldata/models/sdk/pipeline/pipeline_resource.py +171 -0
- acceldata/models/sdk/pipeline/pipeline_run_input.py +84 -0
- acceldata/models/sdk/pipeline/pipeline_run_resource.py +208 -0
- acceldata/models/sdk/pipeline/pipeline_source_type.py +20 -0
- acceldata/models/sdk/pipeline/span_resource.py +327 -0
- acceldata/openapi_deserialization_patches.py +161 -0
- acceldata/openapi_repr_patches.py +62 -0
- acceldata/services/__init__.py +0 -0
- acceldata/services/api_timestamp.py +31 -0
- acceldata/services/asset_service.py +651 -0
- acceldata/services/datasource_service.py +120 -0
- acceldata/services/generic_service.py +132 -0
- acceldata/services/marker_config.py +232 -0
- acceldata/services/pipeline_big_decimal_api.py +102 -0
- acceldata/services/pipeline_response_parse.py +209 -0
- acceldata/services/pipeline_service.py +494 -0
- acceldata/services/rule_service.py +620 -0
- acceldata/urls/__init__.py +1 -0
- acceldata/urls/catalog_urls.py +137 -0
- acceldata/urls/pipeline_urls.py +55 -0
- acceldata/utils/__init__.py +6 -0
- acceldata/utils/datetime_utils.py +16 -0
- acceldata/utils/operation_ack.py +22 -0
- acceldata/utils/span_helpers.py +95 -0
- acceldata/utils/time_range_utils.py +90 -0
- acceldata_sdk_python-26.7.0.dist-info/METADATA +26 -0
- acceldata_sdk_python-26.7.0.dist-info/RECORD +303 -0
- acceldata_sdk_python-26.7.0.dist-info/WHEEL +5 -0
- acceldata_sdk_python-26.7.0.dist-info/licenses/LICENSE +22 -0
- acceldata_sdk_python-26.7.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from datetime import datetime
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from acceldata.models.api.catalog.dataplane_job import DataplaneJob
|
|
24
|
+
from acceldata.models.api.catalog.marker import Marker
|
|
25
|
+
from acceldata.models.api.catalog.marker_config import MarkerConfig
|
|
26
|
+
from acceldata.models.api.catalog.pattern_configuration import PatternConfiguration
|
|
27
|
+
from acceldata.models.api.catalog.spark_resource_config import SparkResourceConfig
|
|
28
|
+
from typing import Optional, Set
|
|
29
|
+
from typing_extensions import Self
|
|
30
|
+
from pydantic_core import to_jsonable_python
|
|
31
|
+
|
|
32
|
+
class ProfileRequest(BaseModel):
|
|
33
|
+
"""
|
|
34
|
+
ProfileRequest
|
|
35
|
+
""" # noqa: E501
|
|
36
|
+
analysis_job: Optional[DataplaneJob] = Field(default=None, alias="analysisJob")
|
|
37
|
+
asset_id: StrictInt = Field(alias="assetId")
|
|
38
|
+
auto_profile_id: Optional[StrictInt] = Field(default=None, alias="autoProfileId")
|
|
39
|
+
auto_retries: Optional[StrictInt] = Field(default=0, alias="autoRetries")
|
|
40
|
+
auto_retry_enabled: Optional[StrictBool] = Field(default=False, alias="autoRetryEnabled")
|
|
41
|
+
created_at: datetime = Field(alias="createdAt")
|
|
42
|
+
engine_type: Optional[StrictStr] = Field(default=None, description="Allowed values at generation time: SPARK, JDBC_SQL, POD.", alias="engineType")
|
|
43
|
+
error: Optional[StrictStr] = None
|
|
44
|
+
executed_by: Optional[StrictStr] = Field(default=None, alias="executedBy")
|
|
45
|
+
execution_mode: Optional[StrictStr] = Field(default=None, description="Allowed values at generation time: MANUAL, SCHEDULED.", alias="executionMode")
|
|
46
|
+
id: StrictInt
|
|
47
|
+
is_data_change: StrictBool = Field(alias="isDataChange")
|
|
48
|
+
is_profile_anomalous: StrictBool = Field(alias="isProfileAnomalous")
|
|
49
|
+
job_id: Optional[StrictStr] = Field(default=None, alias="jobId")
|
|
50
|
+
job_type: Optional[StrictStr] = Field(default=None, alias="jobType")
|
|
51
|
+
marker: Optional[Marker] = None
|
|
52
|
+
marker_config: Optional[MarkerConfig] = Field(default=None, alias="markerConfig")
|
|
53
|
+
no_of_columns_per_batch: StrictInt = Field(alias="noOfColumnsPerBatch")
|
|
54
|
+
pattern_configuration: Optional[PatternConfiguration] = Field(default=None, alias="patternConfiguration")
|
|
55
|
+
profile_capabilities: List[StrictStr] = Field(alias="profileCapabilities")
|
|
56
|
+
profile_data_available: StrictBool = Field(alias="profileDataAvailable")
|
|
57
|
+
profiled_data: Optional[Dict[str, Any]] = Field(default=None, alias="profiledData")
|
|
58
|
+
profiling_type: StrictStr = Field(description="Allowed values at generation time: SELECTIVE, FULL, INCREMENTAL.", alias="profilingType")
|
|
59
|
+
resource_strategy_type: Optional[StrictStr] = Field(default='CUSTOM', description="Allowed values at generation time: INVENTORY, CUSTOM.", alias="resourceStrategyType")
|
|
60
|
+
rows: Optional[StrictInt] = None
|
|
61
|
+
run_type: StrictStr = Field(description="Allowed values at generation time: FULL_DATA_LOAD, BATCH_DATA_LOAD.", alias="runType")
|
|
62
|
+
selected_columns: List[StrictStr] = Field(alias="selectedColumns")
|
|
63
|
+
selected_resource_inventory: Optional[StrictStr] = Field(default=None, alias="selectedResourceInventory")
|
|
64
|
+
spark_resource_config: Optional[SparkResourceConfig] = Field(default=None, alias="sparkResourceConfig")
|
|
65
|
+
status: StrictStr
|
|
66
|
+
total_rows: Optional[StrictInt] = Field(default=None, alias="totalRows")
|
|
67
|
+
updated_at: datetime = Field(alias="updatedAt")
|
|
68
|
+
__properties: ClassVar[List[str]] = ["analysisJob", "assetId", "autoProfileId", "autoRetries", "autoRetryEnabled", "createdAt", "engineType", "error", "executedBy", "executionMode", "id", "isDataChange", "isProfileAnomalous", "jobId", "jobType", "marker", "markerConfig", "noOfColumnsPerBatch", "patternConfiguration", "profileCapabilities", "profileDataAvailable", "profiledData", "profilingType", "resourceStrategyType", "rows", "runType", "selectedColumns", "selectedResourceInventory", "sparkResourceConfig", "status", "totalRows", "updatedAt"]
|
|
69
|
+
|
|
70
|
+
model_config = ConfigDict(
|
|
71
|
+
validate_by_name=True,
|
|
72
|
+
validate_by_alias=True,
|
|
73
|
+
validate_assignment=True,
|
|
74
|
+
protected_namespaces=(),
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
def to_str(self) -> str:
|
|
79
|
+
"""Returns the string representation of the model using alias"""
|
|
80
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
81
|
+
|
|
82
|
+
def to_json(self) -> str:
|
|
83
|
+
"""Returns the JSON representation of the model using alias"""
|
|
84
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
85
|
+
|
|
86
|
+
@classmethod
|
|
87
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
88
|
+
"""Create an instance of ProfileRequest from a JSON string"""
|
|
89
|
+
return cls.from_dict(json.loads(json_str))
|
|
90
|
+
|
|
91
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
92
|
+
"""Return the dictionary representation of the model using alias.
|
|
93
|
+
|
|
94
|
+
This has the following differences from calling pydantic's
|
|
95
|
+
`self.model_dump(by_alias=True)`:
|
|
96
|
+
|
|
97
|
+
* `None` is only added to the output dict for nullable fields that
|
|
98
|
+
were set at model initialization. Other fields with value `None`
|
|
99
|
+
are ignored.
|
|
100
|
+
"""
|
|
101
|
+
excluded_fields: Set[str] = set([
|
|
102
|
+
])
|
|
103
|
+
|
|
104
|
+
_dict = self.model_dump(
|
|
105
|
+
by_alias=True,
|
|
106
|
+
exclude=excluded_fields,
|
|
107
|
+
exclude_none=True,
|
|
108
|
+
)
|
|
109
|
+
# override the default output from pydantic by calling `to_dict()` of analysis_job
|
|
110
|
+
if self.analysis_job:
|
|
111
|
+
_dict['analysisJob'] = self.analysis_job.to_dict()
|
|
112
|
+
# override the default output from pydantic by calling `to_dict()` of marker
|
|
113
|
+
if self.marker:
|
|
114
|
+
_dict['marker'] = self.marker.to_dict()
|
|
115
|
+
# override the default output from pydantic by calling `to_dict()` of marker_config
|
|
116
|
+
if self.marker_config:
|
|
117
|
+
_dict['markerConfig'] = self.marker_config.to_dict()
|
|
118
|
+
# override the default output from pydantic by calling `to_dict()` of pattern_configuration
|
|
119
|
+
if self.pattern_configuration:
|
|
120
|
+
_dict['patternConfiguration'] = self.pattern_configuration.to_dict()
|
|
121
|
+
# override the default output from pydantic by calling `to_dict()` of spark_resource_config
|
|
122
|
+
if self.spark_resource_config:
|
|
123
|
+
_dict['sparkResourceConfig'] = self.spark_resource_config.to_dict()
|
|
124
|
+
# set to None if engine_type (nullable) is None
|
|
125
|
+
# and model_fields_set contains the field
|
|
126
|
+
if self.engine_type is None and "engine_type" in self.model_fields_set:
|
|
127
|
+
_dict['engineType'] = None
|
|
128
|
+
|
|
129
|
+
# set to None if error (nullable) is None
|
|
130
|
+
# and model_fields_set contains the field
|
|
131
|
+
if self.error is None and "error" in self.model_fields_set:
|
|
132
|
+
_dict['error'] = None
|
|
133
|
+
|
|
134
|
+
# set to None if executed_by (nullable) is None
|
|
135
|
+
# and model_fields_set contains the field
|
|
136
|
+
if self.executed_by is None and "executed_by" in self.model_fields_set:
|
|
137
|
+
_dict['executedBy'] = None
|
|
138
|
+
|
|
139
|
+
# set to None if execution_mode (nullable) is None
|
|
140
|
+
# and model_fields_set contains the field
|
|
141
|
+
if self.execution_mode is None and "execution_mode" in self.model_fields_set:
|
|
142
|
+
_dict['executionMode'] = None
|
|
143
|
+
|
|
144
|
+
# set to None if job_id (nullable) is None
|
|
145
|
+
# and model_fields_set contains the field
|
|
146
|
+
if self.job_id is None and "job_id" in self.model_fields_set:
|
|
147
|
+
_dict['jobId'] = None
|
|
148
|
+
|
|
149
|
+
# set to None if job_type (nullable) is None
|
|
150
|
+
# and model_fields_set contains the field
|
|
151
|
+
if self.job_type is None and "job_type" in self.model_fields_set:
|
|
152
|
+
_dict['jobType'] = None
|
|
153
|
+
|
|
154
|
+
# set to None if resource_strategy_type (nullable) is None
|
|
155
|
+
# and model_fields_set contains the field
|
|
156
|
+
if self.resource_strategy_type is None and "resource_strategy_type" in self.model_fields_set:
|
|
157
|
+
_dict['resourceStrategyType'] = None
|
|
158
|
+
|
|
159
|
+
# set to None if selected_resource_inventory (nullable) is None
|
|
160
|
+
# and model_fields_set contains the field
|
|
161
|
+
if self.selected_resource_inventory is None and "selected_resource_inventory" in self.model_fields_set:
|
|
162
|
+
_dict['selectedResourceInventory'] = None
|
|
163
|
+
|
|
164
|
+
return _dict
|
|
165
|
+
|
|
166
|
+
@classmethod
|
|
167
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
168
|
+
"""Create an instance of ProfileRequest from a dict"""
|
|
169
|
+
if obj is None:
|
|
170
|
+
return None
|
|
171
|
+
|
|
172
|
+
if not isinstance(obj, dict):
|
|
173
|
+
return cls.model_validate(obj)
|
|
174
|
+
|
|
175
|
+
_obj = cls.model_validate({
|
|
176
|
+
"analysisJob": DataplaneJob.from_dict(obj["analysisJob"]) if obj.get("analysisJob") is not None else None,
|
|
177
|
+
"assetId": obj.get("assetId"),
|
|
178
|
+
"autoProfileId": obj.get("autoProfileId"),
|
|
179
|
+
"autoRetries": obj.get("autoRetries") if obj.get("autoRetries") is not None else 0,
|
|
180
|
+
"autoRetryEnabled": obj.get("autoRetryEnabled") if obj.get("autoRetryEnabled") is not None else False,
|
|
181
|
+
"createdAt": obj.get("createdAt"),
|
|
182
|
+
"engineType": obj.get("engineType"),
|
|
183
|
+
"error": obj.get("error"),
|
|
184
|
+
"executedBy": obj.get("executedBy"),
|
|
185
|
+
"executionMode": obj.get("executionMode"),
|
|
186
|
+
"id": obj.get("id"),
|
|
187
|
+
"isDataChange": obj.get("isDataChange") if obj.get("isDataChange") is not None else False,
|
|
188
|
+
"isProfileAnomalous": obj.get("isProfileAnomalous") if obj.get("isProfileAnomalous") is not None else False,
|
|
189
|
+
"jobId": obj.get("jobId"),
|
|
190
|
+
"jobType": obj.get("jobType"),
|
|
191
|
+
"marker": Marker.from_dict(obj["marker"]) if obj.get("marker") is not None else None,
|
|
192
|
+
"markerConfig": MarkerConfig.from_dict(obj["markerConfig"]) if obj.get("markerConfig") is not None else None,
|
|
193
|
+
"noOfColumnsPerBatch": obj.get("noOfColumnsPerBatch") if obj.get("noOfColumnsPerBatch") is not None else 300,
|
|
194
|
+
"patternConfiguration": PatternConfiguration.from_dict(obj["patternConfiguration"]) if obj.get("patternConfiguration") is not None else None,
|
|
195
|
+
"profileCapabilities": obj.get("profileCapabilities"),
|
|
196
|
+
"profileDataAvailable": obj.get("profileDataAvailable") if obj.get("profileDataAvailable") is not None else False,
|
|
197
|
+
"profiledData": obj.get("profiledData"),
|
|
198
|
+
"profilingType": obj.get("profilingType"),
|
|
199
|
+
"resourceStrategyType": obj.get("resourceStrategyType") if obj.get("resourceStrategyType") is not None else 'CUSTOM',
|
|
200
|
+
"rows": obj.get("rows"),
|
|
201
|
+
"runType": obj.get("runType") if obj.get("runType") is not None else 'FULL_DATA_LOAD',
|
|
202
|
+
"selectedColumns": obj.get("selectedColumns"),
|
|
203
|
+
"selectedResourceInventory": obj.get("selectedResourceInventory"),
|
|
204
|
+
"sparkResourceConfig": SparkResourceConfig.from_dict(obj["sparkResourceConfig"]) if obj.get("sparkResourceConfig") is not None else None,
|
|
205
|
+
"status": obj.get("status"),
|
|
206
|
+
"totalRows": obj.get("totalRows"),
|
|
207
|
+
"updatedAt": obj.get("updatedAt")
|
|
208
|
+
})
|
|
209
|
+
return _obj
|
|
210
|
+
|
|
211
|
+
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from acceldata.models.api.catalog.profile_request import ProfileRequest
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class ProfileRequestResponse(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
ProfileRequestResponse
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
profile_request: Optional[ProfileRequest] = Field(default=None, alias="profileRequest")
|
|
32
|
+
__properties: ClassVar[List[str]] = ["profileRequest"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
validate_by_name=True,
|
|
36
|
+
validate_by_alias=True,
|
|
37
|
+
validate_assignment=True,
|
|
38
|
+
protected_namespaces=(),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of ProfileRequestResponse from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
"""
|
|
65
|
+
excluded_fields: Set[str] = set([
|
|
66
|
+
])
|
|
67
|
+
|
|
68
|
+
_dict = self.model_dump(
|
|
69
|
+
by_alias=True,
|
|
70
|
+
exclude=excluded_fields,
|
|
71
|
+
exclude_none=True,
|
|
72
|
+
)
|
|
73
|
+
# override the default output from pydantic by calling `to_dict()` of profile_request
|
|
74
|
+
if self.profile_request:
|
|
75
|
+
_dict['profileRequest'] = self.profile_request.to_dict()
|
|
76
|
+
return _dict
|
|
77
|
+
|
|
78
|
+
@classmethod
|
|
79
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
80
|
+
"""Create an instance of ProfileRequestResponse from a dict"""
|
|
81
|
+
if obj is None:
|
|
82
|
+
return None
|
|
83
|
+
|
|
84
|
+
if not isinstance(obj, dict):
|
|
85
|
+
return cls.model_validate(obj)
|
|
86
|
+
|
|
87
|
+
_obj = cls.model_validate({
|
|
88
|
+
"profileRequest": ProfileRequest.from_dict(obj["profileRequest"]) if obj.get("profileRequest") is not None else None
|
|
89
|
+
})
|
|
90
|
+
return _obj
|
|
91
|
+
|
|
92
|
+
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
from pydantic_core import to_jsonable_python
|
|
25
|
+
|
|
26
|
+
class PropertyTemplate(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
PropertyTemplate
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
children: List[PropertyTemplate]
|
|
31
|
+
config_key: Optional[StrictStr] = Field(default=None, alias="configKey")
|
|
32
|
+
config_value: Optional[Any] = Field(default=None, alias="configValue")
|
|
33
|
+
data_validator: Optional[StrictStr] = Field(default=None, alias="dataValidator")
|
|
34
|
+
data_validator_message: Optional[StrictStr] = Field(default=None, alias="dataValidatorMessage")
|
|
35
|
+
description: Optional[StrictStr] = None
|
|
36
|
+
disable_update: Optional[StrictBool] = Field(default=None, alias="disableUpdate")
|
|
37
|
+
display_label: StrictStr = Field(alias="displayLabel")
|
|
38
|
+
hidden: StrictBool
|
|
39
|
+
key: StrictStr
|
|
40
|
+
multi_select: Optional[StrictBool] = Field(default=None, alias="multiSelect")
|
|
41
|
+
options: List[StrictStr]
|
|
42
|
+
read_only: StrictBool = Field(alias="readOnly")
|
|
43
|
+
replacement_for: Optional[StrictStr] = Field(default=None, alias="replacementFor")
|
|
44
|
+
required: StrictBool
|
|
45
|
+
sub_type: Optional[StrictStr] = Field(default=None, description="Allowed values at generation time: STRING, INT, FLOAT, BOOLEAN.", alias="subType")
|
|
46
|
+
type: StrictStr = Field(description="Allowed values at generation time: INT, FLOAT, STRING, BOOLEAN, JSON, DURATION, OBJECT, OPTIONS, URL, URI, PASSWORD, EMAIL, CRONEXPRESSION, FILE, ARRAY.")
|
|
47
|
+
value: Optional[Any] = None
|
|
48
|
+
visibility: Optional[StrictStr] = None
|
|
49
|
+
__properties: ClassVar[List[str]] = ["children", "configKey", "configValue", "dataValidator", "dataValidatorMessage", "description", "disableUpdate", "displayLabel", "hidden", "key", "multiSelect", "options", "readOnly", "replacementFor", "required", "subType", "type", "value", "visibility"]
|
|
50
|
+
|
|
51
|
+
model_config = ConfigDict(
|
|
52
|
+
validate_by_name=True,
|
|
53
|
+
validate_by_alias=True,
|
|
54
|
+
validate_assignment=True,
|
|
55
|
+
protected_namespaces=(),
|
|
56
|
+
)
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
def to_str(self) -> str:
|
|
60
|
+
"""Returns the string representation of the model using alias"""
|
|
61
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
62
|
+
|
|
63
|
+
def to_json(self) -> str:
|
|
64
|
+
"""Returns the JSON representation of the model using alias"""
|
|
65
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
66
|
+
|
|
67
|
+
@classmethod
|
|
68
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
69
|
+
"""Create an instance of PropertyTemplate from a JSON string"""
|
|
70
|
+
return cls.from_dict(json.loads(json_str))
|
|
71
|
+
|
|
72
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
73
|
+
"""Return the dictionary representation of the model using alias.
|
|
74
|
+
|
|
75
|
+
This has the following differences from calling pydantic's
|
|
76
|
+
`self.model_dump(by_alias=True)`:
|
|
77
|
+
|
|
78
|
+
* `None` is only added to the output dict for nullable fields that
|
|
79
|
+
were set at model initialization. Other fields with value `None`
|
|
80
|
+
are ignored.
|
|
81
|
+
"""
|
|
82
|
+
excluded_fields: Set[str] = set([
|
|
83
|
+
])
|
|
84
|
+
|
|
85
|
+
_dict = self.model_dump(
|
|
86
|
+
by_alias=True,
|
|
87
|
+
exclude=excluded_fields,
|
|
88
|
+
exclude_none=True,
|
|
89
|
+
)
|
|
90
|
+
# override the default output from pydantic by calling `to_dict()` of each item in children (list)
|
|
91
|
+
_items = []
|
|
92
|
+
if self.children:
|
|
93
|
+
for _item_children in self.children:
|
|
94
|
+
if _item_children:
|
|
95
|
+
_items.append(_item_children.to_dict())
|
|
96
|
+
_dict['children'] = _items
|
|
97
|
+
# set to None if config_key (nullable) is None
|
|
98
|
+
# and model_fields_set contains the field
|
|
99
|
+
if self.config_key is None and "config_key" in self.model_fields_set:
|
|
100
|
+
_dict['configKey'] = None
|
|
101
|
+
|
|
102
|
+
# set to None if config_value (nullable) is None
|
|
103
|
+
# and model_fields_set contains the field
|
|
104
|
+
if self.config_value is None and "config_value" in self.model_fields_set:
|
|
105
|
+
_dict['configValue'] = None
|
|
106
|
+
|
|
107
|
+
# set to None if data_validator (nullable) is None
|
|
108
|
+
# and model_fields_set contains the field
|
|
109
|
+
if self.data_validator is None and "data_validator" in self.model_fields_set:
|
|
110
|
+
_dict['dataValidator'] = None
|
|
111
|
+
|
|
112
|
+
# set to None if data_validator_message (nullable) is None
|
|
113
|
+
# and model_fields_set contains the field
|
|
114
|
+
if self.data_validator_message is None and "data_validator_message" in self.model_fields_set:
|
|
115
|
+
_dict['dataValidatorMessage'] = None
|
|
116
|
+
|
|
117
|
+
# set to None if description (nullable) is None
|
|
118
|
+
# and model_fields_set contains the field
|
|
119
|
+
if self.description is None and "description" in self.model_fields_set:
|
|
120
|
+
_dict['description'] = None
|
|
121
|
+
|
|
122
|
+
# set to None if replacement_for (nullable) is None
|
|
123
|
+
# and model_fields_set contains the field
|
|
124
|
+
if self.replacement_for is None and "replacement_for" in self.model_fields_set:
|
|
125
|
+
_dict['replacementFor'] = None
|
|
126
|
+
|
|
127
|
+
# set to None if sub_type (nullable) is None
|
|
128
|
+
# and model_fields_set contains the field
|
|
129
|
+
if self.sub_type is None and "sub_type" in self.model_fields_set:
|
|
130
|
+
_dict['subType'] = None
|
|
131
|
+
|
|
132
|
+
# set to None if value (nullable) is None
|
|
133
|
+
# and model_fields_set contains the field
|
|
134
|
+
if self.value is None and "value" in self.model_fields_set:
|
|
135
|
+
_dict['value'] = None
|
|
136
|
+
|
|
137
|
+
# set to None if visibility (nullable) is None
|
|
138
|
+
# and model_fields_set contains the field
|
|
139
|
+
if self.visibility is None and "visibility" in self.model_fields_set:
|
|
140
|
+
_dict['visibility'] = None
|
|
141
|
+
|
|
142
|
+
return _dict
|
|
143
|
+
|
|
144
|
+
@classmethod
|
|
145
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
146
|
+
"""Create an instance of PropertyTemplate from a dict"""
|
|
147
|
+
if obj is None:
|
|
148
|
+
return None
|
|
149
|
+
|
|
150
|
+
if not isinstance(obj, dict):
|
|
151
|
+
return cls.model_validate(obj)
|
|
152
|
+
|
|
153
|
+
_obj = cls.model_validate({
|
|
154
|
+
"children": [PropertyTemplate.from_dict(_item) for _item in obj["children"]] if obj.get("children") is not None else None,
|
|
155
|
+
"configKey": obj.get("configKey"),
|
|
156
|
+
"configValue": obj.get("configValue"),
|
|
157
|
+
"dataValidator": obj.get("dataValidator"),
|
|
158
|
+
"dataValidatorMessage": obj.get("dataValidatorMessage"),
|
|
159
|
+
"description": obj.get("description"),
|
|
160
|
+
"disableUpdate": obj.get("disableUpdate"),
|
|
161
|
+
"displayLabel": obj.get("displayLabel"),
|
|
162
|
+
"hidden": obj.get("hidden"),
|
|
163
|
+
"key": obj.get("key"),
|
|
164
|
+
"multiSelect": obj.get("multiSelect"),
|
|
165
|
+
"options": obj.get("options"),
|
|
166
|
+
"readOnly": obj.get("readOnly"),
|
|
167
|
+
"replacementFor": obj.get("replacementFor"),
|
|
168
|
+
"required": obj.get("required"),
|
|
169
|
+
"subType": obj.get("subType"),
|
|
170
|
+
"type": obj.get("type"),
|
|
171
|
+
"value": obj.get("value"),
|
|
172
|
+
"visibility": obj.get("visibility")
|
|
173
|
+
})
|
|
174
|
+
return _obj
|
|
175
|
+
|
|
176
|
+
# TODO: Rewrite to not use raise_errors
|
|
177
|
+
PropertyTemplate.model_rebuild(raise_errors=False)
|
|
178
|
+
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from acceldata.models.api.catalog.property_template import PropertyTemplate
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class PropertyTemplates(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
PropertyTemplates
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
assemblies: Dict[str, List[PropertyTemplate]]
|
|
32
|
+
connections: Dict[str, List[PropertyTemplate]]
|
|
33
|
+
__properties: ClassVar[List[str]] = ["assemblies", "connections"]
|
|
34
|
+
|
|
35
|
+
model_config = ConfigDict(
|
|
36
|
+
validate_by_name=True,
|
|
37
|
+
validate_by_alias=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
53
|
+
"""Create an instance of PropertyTemplates from a JSON string"""
|
|
54
|
+
return cls.from_dict(json.loads(json_str))
|
|
55
|
+
|
|
56
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
57
|
+
"""Return the dictionary representation of the model using alias.
|
|
58
|
+
|
|
59
|
+
This has the following differences from calling pydantic's
|
|
60
|
+
`self.model_dump(by_alias=True)`:
|
|
61
|
+
|
|
62
|
+
* `None` is only added to the output dict for nullable fields that
|
|
63
|
+
were set at model initialization. Other fields with value `None`
|
|
64
|
+
are ignored.
|
|
65
|
+
"""
|
|
66
|
+
excluded_fields: Set[str] = set([
|
|
67
|
+
])
|
|
68
|
+
|
|
69
|
+
_dict = self.model_dump(
|
|
70
|
+
by_alias=True,
|
|
71
|
+
exclude=excluded_fields,
|
|
72
|
+
exclude_none=True,
|
|
73
|
+
)
|
|
74
|
+
# override the default output from pydantic by calling `to_dict()` of each value in assemblies (dict of array)
|
|
75
|
+
_field_dict_of_array = {}
|
|
76
|
+
if self.assemblies:
|
|
77
|
+
for _key_assemblies in self.assemblies:
|
|
78
|
+
if self.assemblies[_key_assemblies] is not None:
|
|
79
|
+
_field_dict_of_array[_key_assemblies] = [
|
|
80
|
+
_item.to_dict() for _item in self.assemblies[_key_assemblies]
|
|
81
|
+
]
|
|
82
|
+
_dict['assemblies'] = _field_dict_of_array
|
|
83
|
+
# override the default output from pydantic by calling `to_dict()` of each value in connections (dict of array)
|
|
84
|
+
_field_dict_of_array = {}
|
|
85
|
+
if self.connections:
|
|
86
|
+
for _key_connections in self.connections:
|
|
87
|
+
if self.connections[_key_connections] is not None:
|
|
88
|
+
_field_dict_of_array[_key_connections] = [
|
|
89
|
+
_item.to_dict() for _item in self.connections[_key_connections]
|
|
90
|
+
]
|
|
91
|
+
_dict['connections'] = _field_dict_of_array
|
|
92
|
+
return _dict
|
|
93
|
+
|
|
94
|
+
@classmethod
|
|
95
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
96
|
+
"""Create an instance of PropertyTemplates from a dict"""
|
|
97
|
+
if obj is None:
|
|
98
|
+
return None
|
|
99
|
+
|
|
100
|
+
if not isinstance(obj, dict):
|
|
101
|
+
return cls.model_validate(obj)
|
|
102
|
+
|
|
103
|
+
_obj = cls.model_validate({
|
|
104
|
+
"assemblies": dict(
|
|
105
|
+
(_k,
|
|
106
|
+
[PropertyTemplate.from_dict(_item) for _item in _v]
|
|
107
|
+
if _v is not None
|
|
108
|
+
else None
|
|
109
|
+
)
|
|
110
|
+
for _k, _v in obj.get("assemblies", {}).items()
|
|
111
|
+
),
|
|
112
|
+
"connections": dict(
|
|
113
|
+
(_k,
|
|
114
|
+
[PropertyTemplate.from_dict(_item) for _item in _v]
|
|
115
|
+
if _v is not None
|
|
116
|
+
else None
|
|
117
|
+
)
|
|
118
|
+
for _k, _v in obj.get("connections", {}).items()
|
|
119
|
+
)
|
|
120
|
+
})
|
|
121
|
+
return _obj
|
|
122
|
+
|
|
123
|
+
|