Catalog

Environmental Intelligence: Geospatial APIs SDK (ibmpairs): A Python module to wrap the core functionality of the Geospatial APIs component.

Copyright 2019-2024 IBM Software: Sustainability, IBM Corp. All Rights Reserved.

SPDX-License-Identifier: BSD-3-Clause

class catalog.Category(id: int = None, name: str = None)

An object to represent a catalog category.

Parameters:
  • id (int) – category id

  • name (str) – category name

from_dict()

Create a Category object from a dictionary.

Parameters:

category_dict (Any) – A dictionary that contains the keys of a Category.

Return type:

ibmpairs.catalog.Category

Raises:

Exception – if not a dictionary.

from_json()

Create a Category object from json (dictonary or str).

Parameters:

category_dict (Any) – A json dictionary that contains the keys of a Category or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.Category

Raises:

Exception – if not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.ColorTable(id: str = None, name: str = None, colors: str = None)

An object to represent a catalog color table.

Parameters:
  • id (str) – An ID of a color table.

  • name (str) – A name for the color table.

  • colors (str) – A string list of colors.

from_dict()

Create a ColorTable object from a dictionary.

Parameters:

color_table_dict (Any) – A dictionary that contains the keys of a ColorTable.

Return type:

ibmpairs.catalog.ColorTable

Raises:

Exception – If not a dictionary.

from_json()

Create a ColorTable object from json (dictonary or str).

Parameters:

color_table_dict (Any) – A json dictionary that contains the keys of a ColorTable or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.ColorTable

Raises:

Exception – If not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayer(client: Client = None, name: str = None, description: str = None, name_alternate: str = None, rating: float = None, description_short: str = None, description_long: str = None, description_links: List[str] = None, data_source_name: str = None, data_source_attribution: str = None, data_source_description: str = None, data_source_links: List[str] = None, update_interval_max: str = None, update_interval_description: str = None, lag_horizon: str = None, lag_horizon_description: str = None, temporal_resolution: str = None, temporal_resolution_description: str = None, spatial_resolution_of_raw_data: str = None, interpolation: str = None, interpolation_upload: str = None, dimensions_description: str = None, permanence: bool = None, permanence_description: str = None, known_issues: str = None, properties: Properties = None, spatial_coverage: SpatialCoverage = None, latitude_min: float = None, longitude_min: float = None, latitude_max: float = None, longitude_max: float = None, temporal_min: str = None, temporal_max: str = None, measurement_interval: str = None, measurement_interval_description: str = None, meaning_of_timestamp: str = None, meaning_of_spatial_descriptor: str = None, id: str = None, dataset: DataSet = None, created_at: str = None, updated_at: str = None, type: str = None, unit: str = None, dataset_id: str = None, min_value: float = None, max_value: float = None, units: str = None, datatype: str = None, level: int = None, crs: str = None, color_table: ColorTable = None, description_internal: str = None, description_internal_links: List[str] = None, formula: str = None, data_layer_response: DataLayerReturn = None)

An object to represent an IBM PAIRS Data Set.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • name (str) – Data Layer name.

  • description (str) – Data Layer description.

  • name_alternate (str) – Alternative Data Layer name.

  • rating (float) – Rating.

  • description_short (str) – Short description of the Layer Set.

  • description_long (str) – Long description of the Layer Set.

  • description_links (List[str]) – A list of URLs with supporting documentation.

  • data_source_name (str) – A name for the origin data source.

  • data_source_attribution (str) – An attribution for the origin data source.

  • data_source_description (str) – A description of the origin data source.

  • data_source_links (List[str]) – A list of URLs with supporting documentation of the origin data source.

  • update_interval_max (str) – The maximum interval of an update to the Data Layer.

  • update_interval_description (str) – A description of the maximum update interval.

  • lag_horizon (str) – Lag horizon of the Data Layer.

  • lag_horizon_description (str) – Lag horizon description.

  • temporal_resolution (str) – The temporal resolution of the Data Layer.

  • temporal_resolution_description (str) – A description of the temporal resolution.

  • spatial_resolution_of_raw_data (str) – Spatial resolution of the raw data.

  • interpolation (str) – Interpolation.

  • interpolation_upload (str) – Interpolation on upload.

  • dimensions_description (str) – A description of the dimensions.

  • permanence (bool) – Permanence.

  • permanence_description (str) – A description of the permanence value.

  • known_issues (str) – Known issues with the data.

  • properties (ibmpairs.catalog.Properties) – A properties entry.

  • spatial_coverage (ibmpairs.catalog.SpatialCoverage) – A spatial coverage entry.

  • latitude_min (float) – The minimum latitude of the Data Set.

  • longitude_min (float) – The minimum longitude of the Data Set.

  • latitude_max (float) – The maximum latitude of the Data Set.

  • longitude_max (float) – The maximum longitude of the Data Set.

  • temporal_min (str) – The minimum temporal value of the Data Set.

  • temporal_max (str) – The maximum temporal value of the Data Set.

  • measurement_interval (str) – The measurement interval of the data.

  • measurement_interval_description (str) – A description of the measurement interval.

  • meaning_of_timestamp (str) – A description of the meaning of the timestamp value.

  • meaning_of_spatial_descriptor (str) – A description of the meaning of the spatial descriptor.

  • id (str) – The Data Layer ID.

  • dataset (ibmpairs.catalog.DataSet) – The Data Set a Data Layer belongs to.

  • created_at (str) – The date of creation.

  • updated_at (str) – The last updated date.

  • type (str) – Type.

  • unit (str) – Unit.

  • dataset_id (str) – The Data Set ID.

  • min_value (float) – The maximum value of the data in the Data Layer.

  • max_value (float) – The minimum value of the data in the Data Layer.

  • units (str) – Units.

  • datatype (str) – The data type of the Data Layer.

  • level (int) – The default IBM PAIRS level for the Data Layer.

  • crs (str) – CRS.

  • color_table (ibmpairs.catalog.ColorTable) – A color table to apply to the Data Layer.

  • description_internal (str) – An internal description of the Data Layer.

  • description_internal_links (List[str]) – A list of links that give context to the description internal.

  • formula (str) – Formula.

  • data_layer_response (ibmpairs.catalog.DataLayerReturn) – A server response to a executed Data Layer method call.

Raises:

Exception – An ibmpairs.client.Client is not found.

create(data_set_id: str, data_layer_type: str, data_layer_group: str = None, client: Client = None, verify: bool = True)

A method to create a Data Layer.

Parameters:
  • data_set_id (str) – The Data Set ID of the Data Layer should be created for.

  • data_layer_type (str) – The Data Layer type to be created, (e.g. 2draster).

  • data_layer_group (str) – In the case of vector data, the P group number the Data Layer should be created within.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Set ID is not provided, a Data Layer type is not provided, a Data Layer group is not provided and the type is a Vector, a server error occurred, the status of the request is not 200.

delete(id=None, hard_delete=False, client: Client = None, verify: bool = True)

A method to delete a Data Layer.

Parameters:
  • id (str) – The Data Layer ID of the Data Layer to be deleted.

  • hard_delete (bool) – Whether the Data Layer should be ‘hard deleted’, NOTE: this also deletes all data held by associated Data Layer. This step is necessary where the intention is to delete and recreate a Data Layer with the same name.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, t he status of the request is not 200.

display(columns: List[str] = ['dataset_id', 'id', 'name', 'description_short', 'description_long', 'level', 'type', 'units'])

A method to return a pandas.DataFrame object of a get result.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘dataset_id’, ‘id’, ‘name’, ‘description_short’, ‘description_long’, ‘level’, ‘type’, ‘unit’]

Returns:

A pandas.DataFrame of attributes from the object.

Return type:

pandas.DataFrame

from_dict()

Create a DataLayer object from a dictionary.

Parameters:

data_layer_dict (Any) – A dictionary that contains the keys of a DataLayer.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – if not a dictionary.

from_json()

Create a DataLayer object from json (dictonary or str).

Parameters:

data_layer_dict (Any) – A json dictionary that contains the keys of a DataLayer or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If not a dictionary or a string.

get(id=None, client: Client = None, verify: bool = True)

A method to get a Data Layer.

Parameters:
  • id (str) – The Data Layer ID of the Data Layer to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated DataLayer object.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_dict_data_layer_post()

Create a dictionary from the objects structure ready for a POST operation.

Return type:

dict

to_dict_data_layer_put()

Create a dictionary from the objects structure ready for a PUT operation.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

to_json_data_layer_post()

Create a string representation of a json dictionary from the objects structure ready for a POST operation.

Return type:

string

to_json_data_layer_put()

Create a string representation of a json dictionary from the objects structure ready for a PUT operation.

Return type:

string

update(id=None, client: Client = None, verify: bool = True)

A method to update a Data Layer.

Parameters:
  • id (str) – The Data Layer ID of the Data Layer to be updated.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

class catalog.DataLayerDimension(client: Client = None, data_layer_id: str = None, id: str = None, order: int = None, full_name: str = None, short_name: str = None, type: str = None, identifier: str = None, unit: str = None, data_layer_dimension_response: DataLayerDimensionReturn = None)

An object to represent an IBM PAIRS Data Layer Dimension.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_layer_id (str) – A Data Layer ID.

  • id (str) – The ID number of the Data Layer Dimension.

  • order (int) – The order number.

  • full_name (str) – Full name of the Data Layer Dimension.

  • short_name (str) – Short name of the Data Layer Dimension.

  • type (str) – Type of the Data Layer Dimension.

  • identifier (str) – The identifier.

  • unit (str) – Unit of the Data Layer Dimension.

  • data_layer_dimension_response (ibmpairs.catalog.DataLayerDimensionReturn) – A response object from a DataLayerDimension method call.

Raises:

Exception – An ibmpairs.client.Client is not found.

create(data_layer_id=None, client: Client = None, verify: bool = True)

A method to create a Data Layer Dimension.

Parameters:
  • data_layer_id (str) – The ID of the Data Layer the Data Layer Dimension should be created for.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Layer ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

display(columns: List[str] = ['id', 'short_name', 'identifier', 'order', 'full_name', 'type', 'unit'])

A method to return a pandas.DataFrame object of a get result.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘short_name’, ‘identifier’, ‘order’, ‘full_name’, ‘type’, ‘unit’]

Returns:

A pandas.DataFrame of attributes from the object.

Return type:

pandas.DataFrame

from_dict()

Create a DataLayerDimension object from a dictionary.

Parameters:

data_layer_dimension_dict (Any) – A dictionary that contains the keys of a DataLayerDimension.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – if not a dictionary.

from_json()

Create a DataLayerDimension object from json (dictonary or str).

Parameters:

data_layer_dimension_dict (Any) – A json dictionary that contains the keys of a DataLayerDimension or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – if not a dictionary or a string.

get(id=None, client: Client = None, verify: bool = True)

A method to get a Data Layer Dimension.

Parameters:
  • id (str) – The Data Layer Dimension ID of the Data Layer Dimension to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated Data Layer Dimension object.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_dict_data_layer_dimension_post()

Create a dictionary from the objects structure ready for a POST operation.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

to_json_data_layer_dimension_post()

Create a string representation of a json dictionary from the objects structure ready for a POST operation.

Return type:

string

class catalog.DataLayerDimensionReturn(data_layer_dimension_id: str = None, status: int = None, message: str = None)

An object to represent the response from a DataLayerDimension object call.

Parameters:
  • data_layer_dimension_id (str) – A Data Layer Dimension ID.

  • status (int) – A status code.

  • message (str) – A status message from the call.

from_dict()

Create a DataLayerDimensionReturn object from a dictionary.

Parameters:

data_layer_dimensions_return_dict (Any) – A dictionary that contains the keys of a DataLayerDimensionReturn.

Return type:

ibmpairs.catalog.DataLayerDimensionReturn

Raises:

Exception – If not a dictionary.

from_json()

Create a DataLayerDimensionReturn object from json (dictonary or str).

Parameters:

data_layer_dimensions_return_dict (Any) – A json dictionary that contains the keys of a DataLayerDimensionReturn or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerDimensionReturn

Raises:

Exception – If not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayerDimensions(client: Client = None, data_layer_dimensions: List[DataLayerDimension] = None, data_layer_id: str = None)

An object to represent a list of IBM PAIRS Data Layer Dimensions.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_layer_dimensions (List[ibmpairs.catalog.DataLayerDimension]) – An list of Data Layer Dimensions.

  • data_layer_id (str) – The Data Layer ID of the Data Layer Dimensions.

Raises:

Exception – An ibmpairs.client.Client is not found.

display(columns: List[str] = ['id', 'short_name', 'identifier', 'order', 'full_name', 'type', 'unit'], sort_by: str = 'id')

A method to return a pandas.DataFrame object of get results.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘short_name’, ‘identifier’, ‘order’, ‘full_name’, ‘type’, ‘unit’]

Returns:

A pandas.DataFrame of attributes from the data_layer_dimensions attribute.

Return type:

pandas.DataFrame

from_dict()

Create a DataLayerDimensions object from a dictionary.

Parameters:

data_layer_dimensions_dict (Any) – A dictionary that contains the keys of a DataLayerDimensions.

Return type:

ibmpairs.catalog.DataLayerDimensions

Raises:

Exception – If not a dictionary.

from_json()

Create a DataLayerDimensions object from json (dictonary or str).

Parameters:

data_layer_dimensions_dict (Any) – A json dictionary that contains the keys of a DataLayerDimensions or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerDimensions

Raises:

Exception – If not a dictionary or a string.

get(data_layer_id=None, client: Client = None, verify: bool = True)

A method to get a list of Data Layer Dimensions by Data Layer ID.

Parameters:
  • data_layer_id (str) – The Data Layer ID of the Data Layer Dimensions to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated Data Layer Dimensions object.

Return type:

ibmpairs.catalog.DataLayerDimensions

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Layer ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayerProperties(client: Client = None, data_layer_properties: List[DataLayerProperty] = None, data_layer_id: str = None)

An object to represent a list of IBM PAIRS Data Layer Properties.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_layer_properties (List[ibmpairs.catalog.DataLayerProperty]) – A list of Data Layer Properties.

  • data_layer_id (str) – The Data Layer ID of the Data Layer Properties.

Raises:

Exception – An ibmpairs.client.Client is not found.

display(columns: List[str] = ['id', 'short_name', 'identifier', 'order', 'full_name', 'type', 'unit'], sort_by: str = 'id')

A method to return a pandas.DataFrame object of get results.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘name’, ‘description_short’, ‘description_long’]

Returns:

A pandas.DataFrame of attributes from the data_layer_properties attribute.

Return type:

pandas.DataFrame

from_dict()

Create a DataLayerProperties object from a dictionary.

Parameters:

data_layer_properties_dict (Any) – A dictionary that contains the keys of a DataLayerProperties.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – If not a dictionary.

from_json()

Create a DataLayerProperties object from json (dictonary or str).

Parameters:

data_layer_properties_dict (Any) – A json dictionary that contains the keys of a DataLayerProperties or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – If not a dictionary or a string.

get(data_layer_id=None, client: Client = None, verify: bool = True)

A method to get a list of Data Layer Properties by Data Layer ID.

Parameters:
  • data_layer_id (str) – The Data Layer ID of the Data Layer Properties to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated Data Layer Properties object.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Layer ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayerProperty(client: Client = None, data_layer_id: str = None, id: str = None, order: int = None, full_name: str = None, short_name: str = None, type: str = None, identifier: str = None, unit: str = None, data_layer_property_response: DataLayerPropertyReturn = None)

An object to represent an IBM PAIRS Data Layer Property.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_layer_id (str) – A Data Layer ID.

  • id (str) – The ID number of the Data Layer Property.

  • order (int) – The order number.

  • full_name (str) – Full name of the Data Layer Property.

  • short_name (str) – Short name of the Data Layer Property.

  • type (str) – Type of the Data Layer Property.

  • identifier (str) – The identifier.

  • unit (str) – Unit of the Data Layer Property.

  • data_layer_property_response (ibmpairs.catalog.DataLayerPropertyReturn) – A response object from a DataLayerProperty method call.

Raises:

Exception – An ibmpairs.client.Client is not found.

create(data_layer_id=None, client: Client = None, verify: bool = True)

A method to create a Data Layer Property.

Parameters:
  • data_layer_id (str) – The ID of the Data Layer the Data Layer Property should be created for.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Layer ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

display(columns: List[str] = ['id', 'short_name', 'identifier', 'order', 'full_name', 'type', 'unit'])

A method to return a pandas.DataFrame object of a get result.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘short_name’, ‘identifier’, ‘order’, ‘full_name’, ‘type’, ‘unit’]

Returns:

A pandas.DataFrame of attributes from the object.

Return type:

pandas.DataFrame

from_dict()

Create a DataLayerProperty object from a dictionary.

Parameters:

data_layer_property_dict (Any) – A dictionary that contains the keys of a DataLayerProperty.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – if not a dictionary.

from_json()

Create a DataLayerProperty object from json (dictonary or str).

Parameters:

data_layer_property_dict (Any) – A json dictionary that contains the keys of a DataLayerProperty or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – If not a dictionary or a string.

get(id=None, client: Client = None, verify: bool = True)

A method to get a Data Layer Property.

Parameters:
  • id (str) – The Data Layer Property ID of the Data Layer Property to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated Data Layer Property object.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_dict_data_layer_property_post()

Create a dictionary from the objects structure ready for a POST operation.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

to_json_data_layer_property_post()

Create a string representation of a json dictionary from the objects structure ready for a POST operation.

Return type:

string

class catalog.DataLayerPropertyReturn(data_layer_property_id: str = None, status: int = None, message: str = None)

An object to represent the response from a DataLayerProperty object call.

Parameters:
  • data_layer_property_id (str) – A Data Layer Property ID.

  • status (int) – A status code.

  • message (str) – A status message from the call.

from_dict()

Create a DataLayerPropertyReturn object from a dictionary.

Parameters:

data_layer_property_return_dict (Any) – A dictionary that contains the keys of a DataLayerPropertyReturn.

Return type:

ibmpairs.catalog.DataLayerPropertyReturn

Raises:

Exception – if not a dictionary.

from_json()

Create a DataLayerPropertyReturn object from json (dictonary or str).

Parameters:

data_layer_property_return_dict (Any) – A json dictionary that contains the keys of a DataLayerPropertyReturn or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerPropertyReturn

Raises:

Exception – If not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayerReturn(data_layer_ids: List[str] = None, status: int = None, message: str = None, id: str = None)

An object to represent the response from a DataLayer object call.

Parameters:
  • data_layer_ids (List[str]) – A list of Data Layer IDs.

  • status (int) – A status code.

  • message (str) – A status message from the call.

  • id (str) – A Data Layer ID.

from_dict()

Create a DataLayerReturn object from a dictionary.

Parameters:

data_layer_return_dict (Any) – A dictionary that contains the keys of a DataLayerReturn.

Return type:

ibmpairs.catalog.DataLayerReturn

Raises:

Exception – If not a dictionary.

from_json()

Create a DataLayerReturn object from json (dictonary or str).

Parameters:

data_layer_return_dict (Any) – A json dictionary that contains the keys of a DataLayerReturn or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayerReturn

Raises:

Exception – If not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataLayers(client: Client = None, data_set_id: str = None, group: str = None, group_id: str = None, layer_type: str = None, data_layers: List[DataLayer] = None, data_layer_response: DataLayerReturn = None)

An object to represent a list of IBM PAIRS Data Layers.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_set_id (str) – The Data Set ID for the Data Layers.

  • group (str) – The group name of the Data Layers.

  • group_id (str) – The group ID of the Data Layers.

  • layer_type (str) – The layer type (e.g. 2draster).

  • data_layers (List[DataLayer]) – A list of Data Layers.

  • data_layer_response (ibmpairs.catalog.DataLayerReturn) – A server response to a executed Data Layer method call.

Raises:

Exception – An ibmpairs.client.Client is not found.

create(data_set_id: str = None, data_layer_group: str = None, data_layer_type: str = None, client: Client = None, verify: bool = True)

A method to create a number of Data Layers.

Parameters:
  • data_set_id (str) – The Data Set ID of the Data Layer should be created for.

  • data_layer_type (str) – The Data Layer type to be created, (e.g. 2draster).

  • data_layer_group (str) – In the case of vector data, the P group number the Data Layer should be created within.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, a Data Set ID is not provided or set in the object, a Data Layer type is not providedor set in the object, a Data Layer group is not provided (or set in the object) and the type is a Vector, a server error occurred, the status of the request is not 200.

display(columns: List[str] = ['dataset_id', 'id', 'name', 'description_short', 'description_long', 'level', 'type', 'unit'], sort_by: str = 'id')

A method to return a pandas.DataFrame object of get results.

Parameters:
  • columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘dataset_id’, ‘id’, ‘name’, ‘description_short’, ‘description_long’, ‘level’, ‘type’, ‘unit’]

  • sort_by (str) – A sort_by column

Returns:

A pandas.DataFrame of attributes from the data_layers object.

Return type:

pandas.DataFrame

filter_data_layers_by_attribute(attribute, value, regex=None)

A method to filter a list of Data Layers by an attribute.

Parameters:
  • attribute (str) – An attribute of a Data Layer.

  • value (str) – A value to search for.

  • regex (str) – A regex string to apply.

Returns:

A list of DataLayers that fit the criteria.

Return type:

List[ibmpairs.catalog.DataLayer]

Raises:

Exception – The value is not found in any Data Layer.

from_dict()

Create a DataLayers object from a dictionary.

Parameters:

data_layers_dict (Any) – A dictionary that contains the keys of a DataLayers.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If not a dictionary.

from_json()

Create a DataLayers object from json (dictonary or str).

Parameters:

data_layers_dict (Any) – A json dictionary that contains the keys of a DataLayers or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If not a dictionary or a string.

get(data_set_id=None, data_layer_group_id: str = None, data_layer_group: str = None, client: Client = None, verify: bool = True)

A method to get a list of Data Layers, either all, or with specification of a Data Set ID, those for a Data Set.

Parameters:
  • data_set_id (int or str) – The Data Set ID to gather Data Layers for, if unspecified, the method gathers all Data Layers a user has access to.

  • data_layer_group_id (str) – The Data Layer Group ID to filter the results on.

  • data_layer_group (str) – The Data Layer Group name to filter the results on.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated DataLayers object.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – A ibmpairs.client.Client is not found, if a Data Set ID is specified but could not be found, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_dict_data_layers_post()

Create a dictionary from the objects structure ready for a POST operation.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

to_json_data_layers_post()

Create a string representation of a json dictionary from the objects structure ready for a POST operation.

Return type:

string

class catalog.DataSet(client: Client = None, name: str = None, category: Category = None, max_layers: int = None, name_alternate: str = None, rating: float = None, description_short: str = None, description_long: str = None, description_links: List[str] = None, data_source_name: str = None, data_source_attribution: str = None, data_source_description: str = None, data_source_links: List[str] = None, update_interval_max: str = None, update_interval_description: str = None, lag_horizon: str = None, lag_horizon_description: str = None, temporal_resolution: str = None, temporal_resolution_description: str = None, spatial_resolution_of_raw_data: str = None, interpolation: str = None, dimensions_description: str = None, permanence: bool = None, permanence_description: str = None, known_issues: str = None, responsible_organization: str = None, properties: Properties = None, spatial_coverage: SpatialCoverage = None, latitude_min: float = None, longitude_min: float = None, latitude_max: float = None, longitude_max: float = None, temporal_min: str = None, temporal_max: str = None, id: str = None, key: str = None, dsource_h_link: str = None, dsource_desc: str = None, status: str = None, data_origin: str = None, created_at: str = None, updated_at: str = None, level: int = None, crs: str = None, offering_status: str = None, contact_person: str = None, description_internal: str = None, description_internal_links: List[str] = None, data_storage_mid_term: str = None, data_storage_long_term: str = None, elt_scripts_links: List[str] = None, license_information: str = None, data_set_response: DataSetReturn = None)

An object to represent an IBM PAIRS Data Set.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • name (str) – Data Set name.

  • category (ibmpairs.catalog.Category) – A category entry.

  • max_layers (int) – The maximum number of Data Layers the Data Set can contain.

  • name_alternate (str) – Alternative Data Set name.

  • rating (float) – Rating.

  • description_short (str) – Short description of the Data Set.

  • description_long (str) – Long description of the Data Set.

  • description_links (List[str]) – A list of URLs with supporting documentation.

  • data_source_name (str) – A name for the origin data source.

  • data_source_attribution (str) – An attribution for the origin data source.

  • data_source_description (str) – A description of the origin data source.

  • data_source_links (List[str]) – A list of URLs with supporting documentation of the origin data source.

  • update_interval_max (str) – The maximum interval of an update to the Data Set.

  • update_interval_description (str) – A description of the maximum update interval.

  • lag_horizon (str) – Lag horizon of the Data Set.

  • lag_horizon_description (str) – Lag horizon description.

  • temporal_resolution (str) – The temporal resolution of the Data Set.

  • temporal_resolution_description (str) – A description of the temporal resolution.

  • spatial_resolution_of_raw_data (str) – Spatial resolution of the raw data.

  • interpolation (str) – Interpolation.

  • dimensions_description (str) – A description of the dimensions.

  • permanence (bool) – Permanence.

  • permanence_description (str) – A description of the permanence value.

  • known_issues (str) – Known issues with the data.

  • responsible_organization (str) – An organization responsible for the data.

  • properties (ibmpairs.catalog.Properties) – A properties entry.

  • spatial_coverage (ibmpairs.catalog.SpatialCoverage) – A spatial coverage entry.

  • latitude_min (float) – The minimum latitude of the Data Set.

  • longitude_min (float) – The minimum longitude of the Data Set.

  • latitude_max (float) – The maximum latitude of the Data Set.

  • longitude_max (float) – The maximum longitude of the Data Set.

  • temporal_min (str) – The minimum temporal value of the Data Set.

  • temporal_max (str) – The maximum temporal value of the Data Set.

  • id (str) – The Data Set ID.

  • key (str) – The Data Set key.

  • dsource_h_link (str) – Data source hyperlink.

  • dsource_desc (str) – Data source description.

  • status (str) – Data Set status.

  • data_origin (str) – The origin of the data contained within the Data Set.

  • created_at (str) – The date of creation.

  • updated_at (str) – The last updated date.

  • level (int) – The default IBM PAIRS level for the Data Set.

  • crs (str) – CRS.

  • offering_status (str) – The legal status of the offering.

  • contact_person (str) – A contact person for the Data Set.

  • description_internal (str) – An internal description of the Data Set.

  • description_internal_links (List[str]) – A list of links that give context to the description_internal.

  • data_storage_mid_term (str) – The mid term data storage for the Data Set.

  • data_storage_long_term (str) – The lon term data storage for the Data Set.

  • elt_scripts_links (List[str]) – Extract Load Transform script links for the Data Set.

  • license_information (str) – License information for data in the Data Set.

  • data_set_response (ibmpairs.catalog.DataSetReturn) – A server response to a executed Data Set method call.

Raises:

Exception – An ibmpairs.client.Client is not found.

create(client: Client = None, verify: bool = True)

A method to create a Data Set.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, a server error occurred, the status of the request is not 200.

delete(id, hard_delete: bool = False, client: Client = None, verify: bool = True)

A method to delete a Data Set.

Parameters:
  • id (str) – The Data Set ID of the Data Set to be deleted.

  • hard_delete (bool) – Whether the Data Set should be ‘hard deleted’, NOTE: this also deletes all data held by associated Data Layers. This step is necessary where the intention is to delete and recreate a Data Set with the same name.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

display(columns: List[str] = ['id', 'name', 'description_short', 'description_long'])

A method to return a pandas.DataFrame object of a get result.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘name’, ‘description_short’, ‘description_long’]

Returns:

A pandas.DataFrame of attributes from the object.

Return type:

pandas.DataFrame

from_dict()

Create a DataSet object from a dictionary.

Parameters:

data_set_dict (Any) – A dictionary that contains the keys of a DataSet.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – if not a dictionary.

from_json()

Create a DataSet object from json (dictonary or str).

Parameters:

data_set_dict (Any) – A json dictionary that contains the keys of a DataSet or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – if not a dictionary or a string.

get(id=None, client: Client = None, verify: bool = True)

A method to get a Data Set.

Parameters:
  • id (str) – The Data Set ID of the Data Set to be gathered.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated DataSet object.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_dict_data_set_post()

Create a dictionary from the objects structure ready for a POST operation.

Return type:

dict

to_dict_data_set_put()

Create a dictionary from the objects structure ready for a PUT operation.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

to_json_data_set_post()

Create a string representation of a json dictionary from the objects structure ready for a POST operation.

Return type:

string

to_json_data_set_put()

Create a string representation of a json dictionary from the objects structure ready for a PUT operation.

Return type:

string

update(id=None, client: Client = None, verify: bool = True)

A method to update a Data Set.

Parameters:
  • id (str) – The Data Set ID of the Data Set to be updated.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Raises:

Exception – A ibmpairs.client.Client is not found, an ID is not provided or already held in the object, a server error occurred, the status of the request is not 200.

class catalog.DataSetReturn(data_set_id: str = None, status: int = None, message: str = None)

An object to represent the response from a DataSet object call.

Parameters:
  • data_set_id (str) – A data set id.

  • status (int) – A status code.

  • message (str) – A status message from the call.

from_dict()

Create a DataSetReturn object from a dictionary.

Parameters:

data_set_return_dict (Any) – A dictionary that contains the keys of a DataSetReturn.

Return type:

ibmpairs.catalog.DataSetReturn

Raises:

Exception – if not a dictionary.

from_json()

Create a DataSetReturn object from json (dictonary or str).

Parameters:

data_set_return_dict (Any) – A json dictionary that contains the keys of a DataSetReturn or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataSetReturn

Raises:

Exception – if not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.DataSets(client: Client = None, data_sets: List[DataSet] = None)

An object to represent a list of IBM PAIRS Data Sets.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_sets (List[ibmpairs.catalog.DataSet]) – A list of Data Sets.

Raises:

Exception – An ibmpairs.client.Client is not found.

display(columns: List[str] = ['id', 'name', 'description_short', 'description_long'], sort_by: str = 'id')

A method to return a pandas.DataFrame object of get results.

Parameters:

columns (List[str]) – The columns to be returned in the pandas.DataFrame object, defaults to [‘id’, ‘name’, ‘description_short’, ‘description_long’]

Returns:

A pandas.DataFrame of attributes from the data_sets attribute.

Return type:

pandas.DataFrame

from_dict()

Create a DataSets object from a dictionary.

Parameters:

data_sets_dict (Any) – A dictionary that contains the keys of a DataSets.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – If not a dictionary.

from_json()

Create a DataSets object from json (dictonary or str).

Parameters:

data_sets_dict (Any) – A json dictionary that contains the keys of a DataSets or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – if not a dictionary or a string.

get(client: Client = None, verify: bool = True)

A method to get all of Data Sets a user has access to.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A populated DataSets object.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – A ibmpairs.client.Client is not found, a server error occurred, the status of the request is not 200.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.Properties(sector: List[str] = None, application: List[str] = None, domain: List[str] = None, type: List[str] = None, source: List[str] = None)

An object to represent a list of catalog properties.

Parameters:
  • sector (List[str]) – A list of sectors

  • application (List[str]) – A list of applications

  • domain (List[str]) – A list of domains

  • type (List[str]) – A list of types

  • source (List[str]) – A list of sources

from_dict()

Create a Properties object from a dictionary.

Parameters:

properties_dict (Any) – A dictionary that contains the keys of a Properties.

Return type:

ibmpairs.catalog.Properties

Raises:

Exception – if not a dictionary.

from_json()

Create a Properties object from json (dictonary or str).

Parameters:

properties_dict (Any) – A json dictionary that contains the keys of a Properties or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.Properties

Raises:

Exception – if not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

class catalog.Search(client: Client = None, data_sets: DataSets = None, data_layers: DataLayers = None)

An object to search Data Sets and Data Layers for search terms.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • data_sets (List[DataSet]) – A list of Data Sets.

  • data_layers (List[DataLayer]) – A list of Data Layers.

Raises:

Exception – An ibmpairs.client.Client is not found.

all(search_term: str, client: Client = None, verify: bool = True)

A method to search Data Sets and Data Layers.

Parameters:
  • search_term (str) – A search term to be used.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A pandas.DataFrame of matching searched Data Sets and Data Layers.

Return type:

pandas.DataFrame

Raises:

Exception – An ibmpairs.client.Client is not found.

data_layers(search_term: str, client: Client = None, verify: bool = True)

A method to search Data Layers.

Parameters:
  • search_term (str) – A search term to be used.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A pandas.DataFrame of matching searched Data Layers.

Return type:

pandas.DataFrame

Raises:

Exception – An ibmpairs.client.Client is not found.

data_sets(search_term: str, client: Client = None, verify: bool = True)

A method to search Data Sets.

Parameters:
  • search_term (str) – A search term to be used.

  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A pandas.DataFrame of matching searched Data Sets.

Return type:

pandas.DataFrame

Raises:

Exception – An ibmpairs.client.Client is not found.

get_catalog(client: Client = None, verify: bool = True)

A method to get Data Sets and Data Layers to search.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS Client.

  • verify (bool) – SSL verification

Returns:

A pandas.DataFrame of merged Data Set and Data Layer information.

Return type:

pandas.DataFrame

Raises:

Exception – An ibmpairs.client.Client is not found.

class catalog.SpatialCoverage(country: List[str] = None)

An object to represent a catalog spatial coverage.

Parameters:

country (List[str]) – A list of countries

from_dict()

Create a SpatialCoverage object from a dictionary.

Parameters:

spatial_coverage_dict (Any) – A dictionary that contains the keys of a SpatialCoverage.

Return type:

ibmpairs.catalog.SpatialCoverage

Raises:

Exception – if not a dictionary.

from_json()

Create a SpatialCoverage object from json (dictonary or str).

Parameters:

spatial_coverage_dict (Any) – A json dictionary that contains the keys of a SpatialCoverage or a string representation of a json dictionary.

Return type:

ibmpairs.catalog.SpatialCoverage

Raises:

Exception – if not a dictionary or a string.

to_dict()

Create a dictionary from the objects structure.

Return type:

dict

to_json()

Create a string representation of a json dictionary from the objects structure.

Return type:

string

catalog.category_from_dict(category_dictionary: dict)

The method converts a dictionary of Category to a Category object.

Parameters:

category_dict (dict) – A dictionary that contains the keys of a Category.

Return type:

ibmpairs.catalog.Category

Raises:

Exception – If not a dict.

catalog.category_from_json(category_json: Any)

The method converts a dictionary or json string of Category to a Category object.

Parameters:

category_json (Any) – A dictionary or json string that contains the keys of a Category.

Return type:

ibmpairs.catalog.Category

Raises:

Exception – If not a dict or a str.

catalog.category_to_dict(category: Category)

The method converts an object of Category to a dict.

Parameters:

category (ibmpairs.catalog.Category) – A Category object.

Return type:

dict

catalog.category_to_json(category: Category)

The method converts an object of Category to a json string.

Parameters:

category (ibmpairs.catalog.Category) – A Category object.

Return type:

str

catalog.color_table_from_dict(color_table_dictionary: dict)

The method converts a dictionary of ColorTable to a ColorTable object.

Parameters:

color_table_dict (dict) – A dictionary that contains the keys of a ColorTable.

Return type:

ibmpairs.catalog.ColorTable

Raises:

Exception – If not a dict.

catalog.color_table_from_json(color_table_json: Any)

The method converts a dictionary or json string of ColorTable to a ColorTable object.

Parameters:

color_table_json (Any) – A dictionary or json string that contains the keys of a ColorTable.

Return type:

ibmpairs.catalog.ColorTable

Raises:

Exception – if not a dict or a str.

catalog.color_table_to_dict(color_table: ColorTable)

The method converts an object of ColorTable to a dict.

Parameters:

color_table (ibmpairs.catalog.ColorTable) – A ColorTable object.

Return type:

dict

catalog.color_table_to_json(color_table: ColorTable)

The method converts an object of ColorTable to a json string.

Parameters:

color_table (ibmpairs.catalog.ColorTable) – A ColorTable object.

Return type:

str

catalog.create_data_layer(data_layer: DataLayer, data_set_id, data_layer_type: str, data_layer_group: str = None, client: Client = None, verify: bool = True)

Creates a DataLayer from a DataLayer object.

Parameters:
  • data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If a global client is not yet and no client is provided

catalog.create_data_layer_dimension(data_layer_dimension: DataLayerDimension, data_layer_id, client: Client = None, verify: bool = True)

Creates a DataLayerDimension in a DataLayer from a DataLayerDimension object.

Parameters:
  • data_layer_dimension (ibmpairs.catalog.DataLayerDimension) – A DataLayerDimension object.

  • data_layer_id (int or str) – A DataLayer ID number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – If a global client is not yet and no client is provided

catalog.create_data_layer_property(data_layer_property: DataLayerProperty, data_layer_id, client: Client = None, verify: bool = True)

Creates a DataLayerProperty in a DataLayer from a DataLayerProperty object.

Parameters:
  • data_layer_property (ibmpairs.catalog.DataLayerProperty) – A DataLayerProperty object.

  • data_layer_id (int or str) – A DataLayer ID number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – If a global client is not yet and no client is provided

catalog.create_data_layers(data_layers: DataLayers, data_set_id=None, data_layer_type: str = None, data_layer_group: str = None, client: Client = None, verify: bool = True)

Creates a list of DataLayers from a DataLayers object.

Parameters:
  • data_layers (ibmpairs.catalog.DataLayer) – A DataLayers object.

  • data_set_id (int or str) – A DataSet ID number.

  • data_layer_type (str) – A DataLayer type (i.e. Raster or VectorPoint or VectorPolygon).

  • data_layer_group (str) – A DataLayer group name (if vector).

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If a global client is not yet and no client is provided

catalog.create_data_set(data_set: DataSet, client: Client = None, verify: bool = True)

Creates a DataSet from a DataSet object.

Parameters:
  • data_set (ibmpairs.catalog.DataSet) – A DataSet object.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If a global client is not yet and no client is provided

catalog.data_layer_dimension_from_dict(data_layer_dimension_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayerDimension to a DataLayerDimension object.

Parameters:
  • data_layer_dimension_dict (dict) – A dictionary that contains the keys of a DataLayerDimension.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – If not a dict.

catalog.data_layer_dimension_from_json(data_layer_dimension_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayerDimension to a DataLayerDimension object.

Parameters:
  • data_layer_dimension_json (Any) – A dictionary or json string that contains the keys of a DataLayerDimension.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – If not a dict or a str.

catalog.data_layer_dimension_return_from_dict(data_layer_dimension_return_dictionary: dict)

The method converts a dictionary of DataLayerDimensionReturn to a DataLayerDimensionReturn object.

Parameters:

data_layer_dimension_return_dict (dict) – A dictionary that contains the keys of a DataLayerDimensionReturn.

Return type:

ibmpairs.catalog.DataLayerDimensionReturn

Raises:

Exception – If not a dict.

catalog.data_layer_dimension_return_from_json(data_layer_dimension_return_json: Any)

The method converts a dictionary or json string of DataLayerDimensionReturn to a DataLayerDimensionReturn object.

Parameters:

data_layer_dimension_return_json (Any) – A dictionary or json string that contains the keys of a DataLayerDimensionReturn.

Return type:

ibmpairs.catalog.DataLayerDimensionReturn

Raises:

Exception – If not a dict or a str.

catalog.data_layer_dimension_return_to_dict(data_layer_dimension_return: DataLayerDimensionReturn)

The method converts an object of DataLayerDimensionReturn to a dict.

Parameters:

data_layer_dimension_return (ibmpairs.catalog.DataLayerDimensionReturn) – A DataLayerDimensionReturn object.

Return type:

dict

catalog.data_layer_dimension_return_to_json(data_layer_dimension_return: DataLayerDimensionReturn)

The method converts an object of DataLayerDimensionReturn to a json string.

Parameters:

data_layer_dimension_return (ibmpairs.catalog.DataLayerDimensionReturn) – A DataLayerDimensionReturn object.

Return type:

str

catalog.data_layer_dimension_to_dict(data_layer_dimension: DataLayerDimension)

The method converts an object of DataLayerDimension to a dict.

Parameters:

data_layer_dimension (ibmpairs.catalog.DataLayerDimension) – A DataLayerDimension object.

Return type:

dict

catalog.data_layer_dimension_to_dict_post(data_layer_dimension: DataLayerDimension)

The method converts an object of DataLayerDimension to a dict ready for a POST call.

Parameters:

data_layer_dimension (ibmpairs.catalog.DataLayerDimension) – A DataLayerDimension object.

Return type:

dict

catalog.data_layer_dimension_to_json(data_layer_dimension: DataLayerDimension)

The method converts an object of DataLayerDimension to a json string.

Parameters:

data_layer_dimension (ibmpairs.catalog.DataLayerDimension) – A DataLayerDimension object.

Return type:

str

catalog.data_layer_dimension_to_json_post(data_layer_dimension: DataLayerDimension)

The method converts an object of DataLayerDimension to a json string ready for a POST call.

Parameters:

data_layer_dimension (ibmpairs.catalog.DataLayerDimension) – A DataLayerDimension object.

Return type:

str

catalog.data_layer_dimensions_from_dict(data_layer_dimensions_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayerDimensions to a DataLayerDimensions object.

Parameters:
  • data_layer_dimensions_dict (dict) – A dictionary that contains the keys of a DataLayerDimensions.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerDimensions

Raises:

Exception – If not a dict.

catalog.data_layer_dimensions_from_json(data_layer_dimensions_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayerDimensions to a DataLayerDimensions object.

Parameters:
  • data_layer_dimensions_json (Any) – A dictionary or json string that contains the keys of a DataLayerDimensions.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerDimensions

Raises:

Exception – If not a dict or a str.

catalog.data_layer_dimensions_to_dict(data_layer_dimensions: DataLayerDimensions)

The method converts an object of DataLayerDimensions to a dict.

Parameters:

data_layer_dimensions (ibmpairs.catalog.DataLayerDimensions) – A DataLayerDimensions object.

Return type:

dict

catalog.data_layer_dimensions_to_json(data_layer_dimensions: DataLayerDimensions)

The method converts an object of DataLayerDimensions to a json string.

Parameters:

data_layer_dimensions (ibmpairs.catalog.DataLayerDimensions) – A DataLayerDimensions object.

Return type:

str

catalog.data_layer_from_dict(data_layer_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayer to a DataLayer object.

Parameters:
  • data_layer_dict (dict) – A dictionary that contains the keys of a DataLayer.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If not a dict.

catalog.data_layer_from_json(data_layer_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayer to a DataLayer object.

Parameters:
  • data_layer_json (Any) – A dictionary or json string that contains the keys of a DataLayer.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If not a dict or a str.

catalog.data_layer_properties_from_dict(data_layer_properties_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayerProperties to a DataLayerProperties object.

Parameters:
  • data_layer_properties_dict (dict) – A dictionary that contains the keys of a DataLayerProperties.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – if not a dict.

catalog.data_layer_properties_from_json(data_layer_properties_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayerProperties to a DataLayerProperties object.

Parameters:
  • data_layer_properties_json (Any) – A dictionary or json string that contains the keys of a DataLayerProperties.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – If not a dict or a str.

catalog.data_layer_properties_to_dict(data_layer_properties: DataLayerProperties)

The method converts an object of DataLayerProperties to a dict.

Parameters:

data_layer_properties (ibmpairs.catalog.DataLayerProperties) – A DataLayerProperties object.

Return type:

dict

catalog.data_layer_properties_to_json(data_layer_properties: DataLayerProperties)

The method converts an object of DataLayerProperties to a json string.

Parameters:

data_layer_properties (ibmpairs.catalog.DataLayerProperties) – A DataLayerProperties object.

Return type:

str

catalog.data_layer_property_from_dict(data_layer_property_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayerProperty to a DataLayerProperty object.

Parameters:
  • data_layer_property_dict (dict) – A dictionary that contains the keys of a DataLayerProperty.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – If not a dict.

catalog.data_layer_property_from_json(data_layer_property_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayerProperty to a DataLayerProperty object.

Parameters:
  • data_layer_property_json (Any) – A dictionary or json string that contains the keys of a DataLayerProperty.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – If not a dict or a str.

catalog.data_layer_property_return_from_dict(data_layer_property_return_dictionary: dict)

The method converts a dictionary of DataLayerPropertyReturn to a DataLayerPropertyReturn object.

Parameters:

data_layer_property_return_dict (dict) – A dictionary that contains the keys of a DataLayerPropertyReturn.

Return type:

ibmpairs.catalog.DataLayerPropertyReturn

Raises:

Exception – If not a dict.

catalog.data_layer_property_return_from_json(data_layer_property_return_json: Any)

The method converts a dictionary or json string of DataLayerPropertyReturn to a DataLayerPropertyReturn object.

Parameters:

data_layer_property_return_json (Any) – A dictionary or json string that contains the keys of a DataLayerPropertyReturn.

Return type:

ibmpairs.catalog.DataLayerPropertyReturn

Raises:

Exception – If not a dict or a str.

catalog.data_layer_property_return_to_dict(data_layer_property_return: DataLayerPropertyReturn)

The method converts an object of DataLayerPropertyReturn to a dict.

Parameters:

data_layer_property_return (ibmpairs.catalog.DataLayerPropertyReturn) – A DataLayerPropertyReturn object.

Return type:

dict

catalog.data_layer_property_return_to_json(data_layer_property_return: DataLayerPropertyReturn)

The method converts an object of DataLayerPropertyReturn to a json string.

Parameters:

data_layer_property_return (ibmpairs.catalog.DataLayerPropertyReturn) – A DataLayerPropertyReturn object.

Return type:

str

catalog.data_layer_property_to_dict(data_layer_property: DataLayerProperty)

The method converts an object of DataLayerProperty to a dict.

Parameters:

data_layer_property (ibmpairs.catalog.DataLayerProperty) – A DataLayerProperty object.

Return type:

dict

catalog.data_layer_property_to_dict_post(data_layer_property: DataLayerProperty)

The method converts an object of DataLayerProperty to a dict ready for a POST call.

Parameters:

data_layer_property (ibmpairs.catalog.DataLayerProperty) – A DataLayerProperty object.

Return type:

dict

catalog.data_layer_property_to_json(data_layer_property: DataLayerProperty)

The method converts an object of DataLayerProperty to a json string.

Parameters:

data_layer_property (ibmpairs.catalog.DataLayerProperty) – A DataLayerProperty object.

Return type:

str

catalog.data_layer_property_to_json_post(data_layer_property: DataLayerProperty)

The method converts an object of DataLayerProperty to a json string ready for a POST call.

Parameters:

data_layer_property (ibmpairs.catalog.DataLayerProperty) – A DataLayerProperty object.

Return type:

str

catalog.data_layer_return_from_dict(data_layer_return_dictionary: dict)

The method converts a dictionary of DataLayerReturn to a DataLayerReturn object.

Parameters:

data_layer_return_dict (dict) – A dictionary that contains the keys of a DataLayerReturn.

Return type:

ibmpairs.catalog.DataLayerReturn

Raises:

Exception – If not a dict.

catalog.data_layer_return_from_json(data_layer_return_json: Any)

The method converts a dictionary or json string of DataLayerReturn to a DataLayerReturn object.

Parameters:

data_layer_return_json (Any) – A dictionary or json string that contains the keys of a DataLayerReturn.

Return type:

ibmpairs.catalog.DataLayerReturn

Raises:

Exception – If not a dict or a str.

catalog.data_layer_return_to_dict(data_layer_return: DataLayerReturn)

The method converts an object of DataLayerReturn to a dict.

Parameters:

data_layer_return (ibmpairs.catalog.DataLayerReturn) – A DataLayerReturn object.

Return type:

dict

catalog.data_layer_return_to_json(data_layer_return: DataLayerReturn)

The method converts an object of DataLayerReturn to a json string.

Parameters:

data_layer_return (ibmpairs.catalog.DataLayerReturn) – A DataLayerReturn object.

Return type:

str

catalog.data_layer_to_dict(data_layer: DataLayer)

The method converts an object of DataLayer to a dict.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

dict

catalog.data_layer_to_dict_post(data_layer: DataLayer)

The method converts an object of DataLayer to a dict ready for a POST call.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

dict

catalog.data_layer_to_dict_put(data_layer: DataLayer)

The method converts an object of DataLayer to a dict ready for a PUT call.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

dict

catalog.data_layer_to_json(data_layer: DataLayer)

The method converts an object of DataLayer to a json string.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

str

catalog.data_layer_to_json_post(data_layer: DataLayer)

The method converts an object of DataLayer to a json string ready for a POST call.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

str

catalog.data_layer_to_json_put(data_layer: DataLayer)

The method converts an object of DataLayer to a json string ready for a PUT call.

Parameters:

data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

Return type:

str

catalog.data_layers_from_dict(data_layers_dictionary: dict, client: Client = None)

The method converts a dictionary of DataLayers to a DataLayers object.

Parameters:
  • data_layers_dict (dict) – A dictionary that contains the keys of a DataLayers.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If not a dict.

catalog.data_layers_from_json(data_layers_json: Any, client: Client = None)

The method converts a dictionary or json string of DataLayers to a DataLayers object.

Parameters:
  • data_layers_json (Any) – A dictionary or json string that contains the keys of a DataLayers.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If not a dict or a str.

catalog.data_layers_to_dict(data_layers: DataLayers)

The method converts an object of DataLayers to a dict.

Parameters:

data_layers (ibmpairs.catalog.DataLayers) – A DataLayers object.

Return type:

dict

catalog.data_layers_to_dict_post(data_layers: DataLayers)

The method converts an object of DataLayers to a dict ready for a POST call.

Parameters:

data_layers (ibmpairs.catalog.DataLayers) – A DataLayers object.

Return type:

dict

catalog.data_layers_to_json(data_layers: DataLayers)

The method converts an object of DataLayers to a json string.

Parameters:

data_layers (ibmpairs.catalog.DataLayers) – A DataLayers object.

Return type:

str

catalog.data_layers_to_json_post(data_layers: DataLayers)

The method converts an object of DataLayers to a json string ready for a POST call.

Parameters:

data_layers (ibmpairs.catalog.DataLayers) – A DataLayers object.

Return type:

str

catalog.data_set_from_dict(data_set_dictionary: dict, client: Client = None)

The method converts a dictionary of DataSet to a DataSet object.

Parameters:
  • data_set_dict (dict) – A dictionary that contains the keys of a DataSet.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If not a dict.

catalog.data_set_from_json(data_set_json: Any, client: Client = None)

The method converts a dictionary or json string of DataSet to a DataSet object.

Parameters:
  • data_set_json (Any) – A dictionary or json string that contains the keys of a DataSet.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If not a dict or a str.

catalog.data_set_return_from_dict(data_set_return_dictionary: dict)

The method converts a dictionary of DataSetReturn to a DataSetReturn object.

Parameters:

data_set_return_dict (dict) – A dictionary that contains the keys of a DataSetReturn.

Return type:

ibmpairs.catalog.DataSetReturn

Raises:

Exception – If not a dict.

catalog.data_set_return_from_json(data_set_return_json: Any)

The method converts a dictionary or json string of DataSetReturn to a DataSetReturn object.

Parameters:

data_set_return_json (Any) – A dictionary or json string that contains the keys of a DataSetReturn.

Return type:

ibmpairs.catalog.DataSetReturn

Raises:

Exception – If not a dict or a str.

catalog.data_set_return_to_dict(data_set_return: DataSetReturn)

The method converts an object of DataSetReturn to a dict.

Parameters:

data_set_return (ibmpairs.catalog.DataSetReturn) – A DataSetReturn object.

Return type:

dict

catalog.data_set_return_to_json(data_set_return: DataSetReturn)

The method converts an object of DataSetReturn to a json string.

Parameters:

data_set_return (ibmpairs.catalog.DataSetReturn) – A DataSetReturn object.

Return type:

str

catalog.data_set_to_dict(data_set: DataSet)

The method converts an object of DataSet to a dict.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

dict

catalog.data_set_to_dict_post(data_set: DataSet)

The method converts an object of DataSet to a dict ready for a POST call.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

dict

catalog.data_set_to_dict_put(data_set: DataSet)

The method converts an object of DataSet to a dict ready for a PUT call.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

dict

catalog.data_set_to_json(data_set: DataSet)

The method converts an object of DataSet to a json string.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

str

catalog.data_set_to_json_post(data_set: DataSet)

The method converts an object of DataSet to a json string ready for a POST call.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

str

catalog.data_set_to_json_put(data_set: DataSet)

The method converts an object of DataSet to a json string ready for a PUT call.

Parameters:

data_set (ibmpairs.catalog.DataSet) – A DataSet object.

Return type:

str

catalog.data_sets_from_dict(data_sets_dictionary: dict, client: Client = None)

The method converts a dictionary of DataSets to a DataSets object.

Parameters:
  • data_sets_dict (dict) – A dictionary that contains the keys of a DataSets.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – If not a dict.

catalog.data_sets_from_json(data_sets_json: Any, client: Client = None)

The method converts a dictionary or json string of DataSets to a DataSets object.

Parameters:
  • data_sets_json (Any) – A dictionary or json string that contains the keys of a DataSets.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – If not a dict or a str.

catalog.data_sets_to_dict(data_sets: DataSets)

The method converts an object of DataSets to a dict.

Parameters:

data_sets (ibmpairs.catalog.DataSets) – A DataSets object.

Return type:

dict

catalog.data_sets_to_json(data_sets: DataSets)

The method converts an object of DataSets to a json string.

Parameters:

data_sets (ibmpairs.catalog.DataSets) – A DataSets object.

Return type:

str

catalog.delete_data_layer(id, hard_delete: bool = False, client: Client = None, verify: bool = True)

Deletes a DataLayer.

Parameters:
  • id (ibmpairs.catalog.DataLayer) – A DataLayer ID number.

  • hard_delete (bool) – A flag to indicate whether a hard delete should be performed. This is necessary where the intention is to re-create a DataLayer in a DataSet with the same name. WARNING: when a hard delete is performed any data associated with the DataLayer is deleted too.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If a global client is not yet and no client is provided

catalog.delete_data_set(id, hard_delete: bool = False, client: Client = None, verify: bool = True)

Deletes a DataSet.

Parameters:
  • id (ibmpairs.catalog.DataSet) – A DataSet ID number.

  • hard_delete (bool) – A flag to indicate whether a hard delete should be performed. This is necessary where the intention is to re-create a DataSet with the same name. WARNING: when a hard delete is performed any data associated with the DataSet is deleted too.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layer(id, client: Client = None, verify: bool = True)

The method gets metadata about a DataLayer from the server.

Parameters:
  • data_set_id (int or str) – A DataLayer ID number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layer_dimension(id, client: Client = None, verify: bool = True)

The method gets metadata about a DataLayerDimension from the server.

Parameters:
  • id (int or str) – A DataLayerDimension ID Number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerDimension

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layer_dimensions(data_layer_id=None, client: Client = None, verify: bool = True)

The method gets metadata about all DataLayerDimensions in a DataLayer from the server.

Parameters:
  • data_layer_id (int or str) – A DataLayer ID Number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerDimesnions

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layer_properties(data_layer_id=None, client: Client = None, verify: bool = True)

The method gets metadata about all DataLayerProperties in a DataLayer from the server.

Parameters:
  • data_layer_id (int or str) – A DataLayer ID Number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerProperties

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layer_property(id, client: Client = None, verify: bool = True)

The method gets metadata about a DataLayerProperty from the server.

Parameters:
  • id (int or str) – A DataLayerProperty ID Number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayerProperty

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_layers(data_set_id=None, data_layer_group_id: str = None, data_layer_group: str = None, client: Client = None, verify: bool = True)

The method gets metadata about all DataLayers from the server or a selection by DataSet.

Parameters:
  • data_set_id (int or str) – A DataSet ID Number (if desire is to get only DataLayers that belong to a certain DataSet).

  • data_layer_group_id (str) – The Data Layer Group ID to filter the results on.

  • data_layer_group (str) – The Data Layer Group name to filter the results on.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayers

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_set(id, client: Client = None, verify: bool = True)

The method gets metadata about a DataSet from the server.

Parameters:
  • id (int or str) – A DataSet ID number.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If a global client is not yet and no client is provided

catalog.get_data_sets(client: Client = None, verify: bool = True)

The method gets metadata about all DataSets from the server side.

Parameters:
  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataSets

Raises:

Exception – If a global client is not yet and no client is provided

catalog.properties_from_dict(properties_dictionary: dict)

The method converts a dictionary of Properties to a Properties object.

Parameters:

properties_dict (dict) – A dictionary that contains the keys of a Properties.

Return type:

ibmpairs.catalog.Properties

Raises:

Exception – If not a dict.

catalog.properties_from_json(properties_json: Any)

The method converts a dictionary or json string of Properties to a Properties object.

Parameters:

properties_json (Any) – A dictionary or json string that contains the keys of a Properties.

Return type:

ibmpairs.catalog.Properties

Raises:

Exception – If not a dict or a str.

catalog.properties_to_dict(properties: Properties)

The method converts an object of Properties to a dict.

Parameters:

properties (ibmpairs.catalog.Properties) – A Properties object.

Return type:

dict

catalog.properties_to_json(properties: Properties)

The method converts an object of Properties to a json string.

Parameters:

properties (ibmpairs.catalog.Properties) – A Properties object.

Return type:

str

catalog.search(search_term: str, client: Client = None, verify: bool = True)

Searches the catalog for DataSets and Datalayers.

Parameters:
  • search_term (str) – A free text search term used to search DataSets and DataLayers.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL verification

Return type:

pandas.DataFrame

Raises:

Exception – If a global client is not yet and no client is provided

catalog.spatial_coverage_from_dict(spatial_coverage_dictionary: dict)

The method converts a dictionary of SpatialCoverage to a SpatialCoverage object.

Parameters:

spatial_coverage_dict (dict) – A dictionary that contains the keys of a SpatialCoverage.

Return type:

ibmpairs.catalog.SpatialCoverage

Raises:

Exception – If not a dict.

catalog.spatial_coverage_from_json(spatial_coverage_json: Any)

The method converts a dictionary or json string of SpatialCoverage to a SpatialCoverage object.

Parameters:

spatial_coverage_json (Any) – A dictionary or json string that contains the keys of a SpatialCoverage.

Return type:

ibmpairs.catalog.SpatialCoverage

Raises:

Exception – If not a dict or a str.

catalog.spatial_coverage_to_dict(spatial_coverage: SpatialCoverage)

The method converts an object of SpatialCoverage to a dict.

Parameters:

spatial_coverage (ibmpairs.catalog.SpatialCoverage) – A SpatialCoverage object.

Return type:

dict

catalog.spatial_coverage_to_json(spatial_coverage: SpatialCoverage)

The method converts an object of SpatialCoverage to a json string.

Parameters:

spatial_coverage (ibmpairs.catalog.SpatialCoverage) – A SpatialCoverage object.

Return type:

str

catalog.update_data_layer(data_layer: DataLayer, id=None, client: Client = None, verify: bool = True)

Updates a DataLayer from a DataLayer object.

Parameters:
  • data_layer (ibmpairs.catalog.DataLayer) – A DataLayer object.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataLayer

Raises:

Exception – If a global client is not yet and no client is provided

catalog.update_data_set(data_set: DataSet, id=None, client: Client = None, verify: bool = True)

Updates a DataSet from a DataSet object.

Parameters:
  • data_set (ibmpairs.catalog.DataSet) – A DataSet object.

  • client (ibmpairs.client.Client) – An IBM PAIRS client.

  • verify (bool) – SSL Verification flag.

Return type:

ibmpairs.catalog.DataSet

Raises:

Exception – If a global client is not yet and no client is provided