pyegeria 5.4.0.dev10__py3-none-any.whl → 5.4.0.dev12__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.
- commands/cat/debug_log +6290 -6042
- commands/cat/debug_log.2025-07-01_15-22-20_102237.zip +0 -0
- commands/cat/debug_log.2025-07-04_15-43-28_460900.zip +0 -0
- commands/cat/debug_log.2025-07-06_20-48-04_338314.zip +0 -0
- commands/cat/debug_log.2025-07-09_10-17-09_526262.zip +0 -0
- commands/cat/dr_egeria_md.py +24 -14
- commands/cat/list_collections.py +11 -4
- md_processing/__init__.py +3 -1
- md_processing/data/commands.json +7842 -2231
- md_processing/md_commands/data_designer_commands.py +67 -80
- md_processing/md_commands/glossary_commands.py +3 -1
- md_processing/md_commands/product_manager_commands.py +1746 -0
- md_processing/md_commands/solution_architect_commands.py +390 -236
- md_processing/md_processing_utils/common_md_proc_utils.py +8 -6
- md_processing/md_processing_utils/md_processing_constants.py +25 -4
- pyegeria/__init__.py +1 -0
- pyegeria/_client.py +0 -1
- pyegeria/collection_manager_omvs.py +504 -546
- pyegeria/data_designer_omvs.py +16 -8
- pyegeria/egeria_tech_client.py +9 -25
- pyegeria/governance_officer_omvs.py +1446 -1343
- pyegeria/output_formatter.py +96 -8
- pyegeria/solution_architect_omvs.py +2278 -1728
- {pyegeria-5.4.0.dev10.dist-info → pyegeria-5.4.0.dev12.dist-info}/METADATA +1 -1
- {pyegeria-5.4.0.dev10.dist-info → pyegeria-5.4.0.dev12.dist-info}/RECORD +28 -25
- commands/cat/debug_log.2025-06-24_15-51-28_769553.zip +0 -0
- commands/cat/debug_log.2025-06-26_11-18-40_644650.zip +0 -0
- {pyegeria-5.4.0.dev10.dist-info → pyegeria-5.4.0.dev12.dist-info}/LICENSE +0 -0
- {pyegeria-5.4.0.dev10.dist-info → pyegeria-5.4.0.dev12.dist-info}/WHEEL +0 -0
- {pyegeria-5.4.0.dev10.dist-info → pyegeria-5.4.0.dev12.dist-info}/entry_points.txt +0 -0
@@ -10,7 +10,7 @@ import asyncio
|
|
10
10
|
from pyegeria._client import Client
|
11
11
|
from pyegeria._globals import NO_ELEMENTS_FOUND
|
12
12
|
from pyegeria._validators import validate_guid, validate_search_string
|
13
|
-
from pyegeria.output_formatter import (extract_mermaid_only, extract_basic_dict, generate_output)
|
13
|
+
from pyegeria.output_formatter import (extract_mermaid_only, extract_basic_dict, generate_output, markdown_to_html)
|
14
14
|
from pyegeria.utils import body_slimmer
|
15
15
|
|
16
16
|
|
@@ -33,6 +33,8 @@ def query_string(params):
|
|
33
33
|
return result
|
34
34
|
|
35
35
|
|
36
|
+
|
37
|
+
|
36
38
|
class CollectionManager(Client):
|
37
39
|
"""
|
38
40
|
Maintain and explore the contents of nested collections. These collections can be used to represent digital
|
@@ -150,6 +152,10 @@ class CollectionManager(Client):
|
|
150
152
|
the class instance.
|
151
153
|
body: dict, optional, default = None
|
152
154
|
If supplied, adds addition request details - for instance, to filter the results on collectionType
|
155
|
+
output_format: str, default = "JSON"
|
156
|
+
- one of "MD", "LIST", "FORM", "REPORT", "DICT", "MERMAID" or "JSON"
|
157
|
+
|
158
|
+
|
153
159
|
Returns
|
154
160
|
-------
|
155
161
|
List
|
@@ -186,7 +192,7 @@ class CollectionManager(Client):
|
|
186
192
|
self._async_get_attached_collections(parent_guid, start_from, page_size, body, output_format))
|
187
193
|
|
188
194
|
async def _async_find_collections_w_body(self, body: dict, classification_name: str = None,
|
189
|
-
starts_with: bool =
|
195
|
+
starts_with: bool = True, ends_with: bool = False,
|
190
196
|
ignore_case: bool = False, start_from: int = 0, page_size: int = 0,
|
191
197
|
output_format: str = 'JSON', output_profile: str = "CORE") -> list | str:
|
192
198
|
""" Returns the list of collections matching the search string filtered by the optional classification.
|
@@ -273,7 +279,7 @@ class CollectionManager(Client):
|
|
273
279
|
return self.generate_collection_output(elements, None, None, output_format)
|
274
280
|
return elements
|
275
281
|
|
276
|
-
def find_collections_w_body(self, body: dict, classification_name: str = None, starts_with: bool =
|
282
|
+
def find_collections_w_body(self, body: dict, classification_name: str = None, starts_with: bool = True,
|
277
283
|
ends_with: bool = False, ignore_case: bool = False, start_from: int = 0,
|
278
284
|
page_size: int = 0, output_format: str = 'JSON',
|
279
285
|
output_profile: str = "CORE") -> list | str:
|
@@ -340,7 +346,7 @@ class CollectionManager(Client):
|
|
340
346
|
start_from, page_size, output_format, output_profile))
|
341
347
|
|
342
348
|
async def _async_find_collections(self, search_string: str = '*', classification_name: str = None,
|
343
|
-
starts_with: bool =
|
349
|
+
starts_with: bool = True, ends_with: bool = False, ignore_case: bool = False,
|
344
350
|
start_from: int = 0, page_size: int = 0, output_format: str = 'JSON',
|
345
351
|
output_profile: str = "CORE") -> list | str:
|
346
352
|
""" Returns the list of collections matching the search string filtered by the optional classification.
|
@@ -397,9 +403,9 @@ class CollectionManager(Client):
|
|
397
403
|
start_from, page_size, output_format, output_profile)
|
398
404
|
return resp
|
399
405
|
|
400
|
-
def find_collections(self, search_string: str = '*', classification_name: str = None, starts_with: bool =
|
401
|
-
ends_with: bool = False, ignore_case: bool = False,
|
402
|
-
|
406
|
+
def find_collections(self, search_string: str = '*', classification_name: str = None, starts_with: bool = True,
|
407
|
+
ends_with: bool = False, ignore_case: bool = False,
|
408
|
+
start_from: int = 0, page_size: int = 0, output_format: str = 'JSON', output_profile: str = "CORE") -> list | str:
|
403
409
|
""" Returns the list of collections matching the search string filtered by the optional classification.
|
404
410
|
The search string is located in the request body and is interpreted as a plain string. The full
|
405
411
|
body allows complete control including status, asOfTime and effectiveTime.
|
@@ -795,8 +801,8 @@ class CollectionManager(Client):
|
|
795
801
|
self._async_get_collection_by_guid(collection_guid, collection_type, body, output_format))
|
796
802
|
|
797
803
|
async def _async_get_collection_members(self, collection_guid: str = None, collection_name: str = None,
|
798
|
-
collection_qname: str = None, body: dict= None, start_from: int = 0,
|
799
|
-
output_format: str = "JSON") -> list | str:
|
804
|
+
collection_qname: str = None, body: dict = None, start_from: int = 0,
|
805
|
+
page_size: int = 0, output_format: str = "JSON") -> list | str:
|
800
806
|
"""Return a list of elements that are a member of a collection. Async version.
|
801
807
|
|
802
808
|
Parameters
|
@@ -930,9 +936,8 @@ class CollectionManager(Client):
|
|
930
936
|
|
931
937
|
return resp
|
932
938
|
|
933
|
-
|
934
|
-
|
935
|
-
output_format: str = "JSON") -> list | str:
|
939
|
+
async def _async_get_collection_graph(self, collection_guid: str, body: dict = None, start_from: int = 0,
|
940
|
+
page_size: int = 0, output_format: str = "JSON") -> list | str:
|
936
941
|
""" Return a graph of elements that are the nested members of a collection along
|
937
942
|
with elements immediately connected to the starting collection. The result
|
938
943
|
includes a mermaid graph of the returned elements. Async version.
|
@@ -997,8 +1002,8 @@ class CollectionManager(Client):
|
|
997
1002
|
return self.generate_collection_output(elements, None, None, output_format)
|
998
1003
|
return elements
|
999
1004
|
|
1000
|
-
def get_collection_graph(self, collection_guid: str = None, body: dict = None, start_from: int = 0,
|
1001
|
-
output_format: str = "JSON") -> list | str:
|
1005
|
+
def get_collection_graph(self, collection_guid: str = None, body: dict = None, start_from: int = 0,
|
1006
|
+
page_size: int = 0, output_format: str = "JSON") -> list | str:
|
1002
1007
|
""" Return a graph of elements that are the nested members of a collection along
|
1003
1008
|
with elements immediately connected to the starting collection. The result
|
1004
1009
|
includes a mermaid graph of the returned elements.
|
@@ -1112,8 +1117,8 @@ class CollectionManager(Client):
|
|
1112
1117
|
return self.generate_collection_output(elements, None, None, output_format)
|
1113
1118
|
return elements
|
1114
1119
|
|
1115
|
-
def get_collection_graph_w_body(self, collection_guid: str, body: dict = None, start_from: int = 0,
|
1116
|
-
output_format: str = "JSON") -> list | str:
|
1120
|
+
def get_collection_graph_w_body(self, collection_guid: str, body: dict = None, start_from: int = 0,
|
1121
|
+
page_size: int = None, output_format: str = "JSON") -> list | str:
|
1117
1122
|
|
1118
1123
|
""" Return a graph of elements that are the nested members of a collection along
|
1119
1124
|
with elements immediately connected to the starting collection. The result
|
@@ -1315,14 +1320,14 @@ class CollectionManager(Client):
|
|
1315
1320
|
}
|
1316
1321
|
"""
|
1317
1322
|
|
1318
|
-
return asyncio.get_event_loop().run_until_complete(
|
1323
|
+
return asyncio.get_event_loop().run_until_complete(
|
1324
|
+
self._async_create_collection_w_body(body, classification_name))
|
1319
1325
|
|
1320
1326
|
async def _async_create_collection(self, display_name: str, description: str, is_own_anchor: bool = True,
|
1321
1327
|
classification_name: str = None, anchor_guid: str = None,
|
1322
1328
|
parent_guid: str = None, parent_relationship_type_name: str = None,
|
1323
1329
|
parent_at_end1: bool = True, collection_type: str = None,
|
1324
|
-
anchor_scope_guid: str = None,
|
1325
|
-
order_property_name: str = None, additional_properties: dict = None,
|
1330
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
1326
1331
|
extended_properties: dict = None) -> str:
|
1327
1332
|
""" Create a new generic collection.
|
1328
1333
|
Create Collections: https://egeria-project.org/concepts/collection
|
@@ -1354,11 +1359,6 @@ class CollectionManager(Client):
|
|
1354
1359
|
Adds an user supplied valid value for the collection type.
|
1355
1360
|
anchor_scope_guid: str, optional, defaults to None
|
1356
1361
|
optional GUID of search scope
|
1357
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1358
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1359
|
-
"OTHER"
|
1360
|
-
order_property_name: str, optional, defaults to "Something"
|
1361
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1362
1362
|
additional_properties: dict, optional, defaults to None
|
1363
1363
|
User specified Additional properties to add to the collection definition.
|
1364
1364
|
extended_properties: dict, optional, defaults to None
|
@@ -1397,9 +1397,8 @@ class CollectionManager(Client):
|
|
1397
1397
|
"parentRelationshipTypeName": parent_relationship_type_name, "parentAtEnd1": parent_at_end1_s,
|
1398
1398
|
"properties": {
|
1399
1399
|
"class": "CollectionProperties", "qualifiedName": qualified_name, "name": display_name,
|
1400
|
-
"description": description, "collectionType": collection_type,
|
1401
|
-
"
|
1402
|
-
"extendedProperties": extended_properties
|
1400
|
+
"description": description, "collectionType": collection_type,
|
1401
|
+
"additionalProperties": additional_properties, "extendedProperties": extended_properties
|
1403
1402
|
},
|
1404
1403
|
}
|
1405
1404
|
|
@@ -1409,9 +1408,8 @@ class CollectionManager(Client):
|
|
1409
1408
|
def create_collection(self, display_name: str, description: str, is_own_anchor: bool = True,
|
1410
1409
|
classification_name: str = None, anchor_guid: str = None, parent_guid: str = None,
|
1411
1410
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
1412
|
-
collection_type: str = None, anchor_scope_guid: str = None,
|
1413
|
-
|
1414
|
-
extended_properties: dict = None) -> str:
|
1411
|
+
collection_type: str = None, anchor_scope_guid: str = None,
|
1412
|
+
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
1415
1413
|
""" Create a new generic collection.
|
1416
1414
|
Create Collections: https://egeria-project.org/concepts/collection
|
1417
1415
|
|
@@ -1441,11 +1439,6 @@ class CollectionManager(Client):
|
|
1441
1439
|
Adds an user supplied valid value for the collection type.
|
1442
1440
|
anchor_scope_guid: str, optional, defaults to None
|
1443
1441
|
optional GUID of search scope
|
1444
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1445
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1446
|
-
"OTHER"
|
1447
|
-
order_property_name: str, optional, defaults to "Something"
|
1448
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1449
1442
|
additional_properties: dict, optional, defaults to None
|
1450
1443
|
User specified Additional properties to add to the collection definition.
|
1451
1444
|
extended_properties: dict, optional, defaults to None
|
@@ -1469,17 +1462,14 @@ class CollectionManager(Client):
|
|
1469
1462
|
return asyncio.get_event_loop().run_until_complete(
|
1470
1463
|
self._async_create_collection(display_name, description, is_own_anchor, classification_name, anchor_guid,
|
1471
1464
|
parent_guid, parent_relationship_type_name, parent_at_end1, collection_type,
|
1472
|
-
anchor_scope_guid,
|
1473
|
-
additional_properties, extended_properties))
|
1474
|
-
|
1465
|
+
anchor_scope_guid, additional_properties, extended_properties))
|
1475
1466
|
|
1476
|
-
|
1477
|
-
|
1467
|
+
async def _async_create_generic_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1468
|
+
is_own_anchor: bool = True, url_item=None,
|
1478
1469
|
classification_name: str = None, anchor_guid: str = None,
|
1479
1470
|
parent_guid: str = None, parent_relationship_type_name: str = None,
|
1480
1471
|
parent_at_end1: bool = True, collection_type: str = None,
|
1481
|
-
anchor_scope_guid: str = None,
|
1482
|
-
order_property_name: str = None, additional_properties: dict = None,
|
1472
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
1483
1473
|
extended_properties: dict = None) -> str:
|
1484
1474
|
""" Create a new generic collection.
|
1485
1475
|
Create Collections: https://egeria-project.org/concepts/collection
|
@@ -1491,6 +1481,8 @@ class CollectionManager(Client):
|
|
1491
1481
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1492
1482
|
description: str
|
1493
1483
|
A description of the collection.
|
1484
|
+
qualified_name: str, optional, defaults to None
|
1485
|
+
Allows user to specify a qualified name of the collection.
|
1494
1486
|
is_own_anchor: bool, optional, defaults to True
|
1495
1487
|
Indicates if the collection should be classified as its own anchor or not.
|
1496
1488
|
classification_name: str
|
@@ -1511,11 +1503,6 @@ class CollectionManager(Client):
|
|
1511
1503
|
Adds an user supplied valid value for the collection type.
|
1512
1504
|
anchor_scope_guid: str, optional, defaults to None
|
1513
1505
|
optional GUID of search scope
|
1514
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1515
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1516
|
-
"OTHER"
|
1517
|
-
order_property_name: str, optional, defaults to "Something"
|
1518
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1519
1506
|
additional_properties: dict, optional, defaults to None
|
1520
1507
|
User specified Additional properties to add to the collection definition.
|
1521
1508
|
extended_properties: dict, optional, defaults to None
|
@@ -1535,17 +1522,21 @@ class CollectionManager(Client):
|
|
1535
1522
|
NotAuthorizedException
|
1536
1523
|
The principle specified by the user_id does not have authorization for the requested action
|
1537
1524
|
|
1525
|
+
Args:
|
1526
|
+
url_item ():
|
1527
|
+
qualified_name ():
|
1528
|
+
|
1538
1529
|
"""
|
1539
1530
|
|
1540
1531
|
is_own_anchor_s = str(is_own_anchor).lower()
|
1541
1532
|
parent_at_end1_s = str(parent_at_end1).lower()
|
1542
1533
|
|
1543
|
-
|
1544
|
-
|
1545
|
-
|
1546
|
-
|
1547
|
-
|
1548
|
-
|
1534
|
+
url = f"{self.collection_command_root}/{url_item}"
|
1535
|
+
if qualified_name is None:
|
1536
|
+
if classification_name is not None:
|
1537
|
+
qualified_name = self.__create_qualified_name__(classification_name, display_name)
|
1538
|
+
else:
|
1539
|
+
qualified_name = self.__create_qualified_name__("Collection", display_name)
|
1549
1540
|
|
1550
1541
|
body = {
|
1551
1542
|
"class": "NewElementRequestBody", "anchorGUID": anchor_guid, "anchorScopeGUID": anchor_scope_guid,
|
@@ -1553,20 +1544,20 @@ class CollectionManager(Client):
|
|
1553
1544
|
"parentRelationshipTypeName": parent_relationship_type_name, "parentAtEnd1": parent_at_end1_s,
|
1554
1545
|
"properties": {
|
1555
1546
|
"class": "CollectionProperties", "qualifiedName": qualified_name, "name": display_name,
|
1556
|
-
"description": description, "collectionType": collection_type,
|
1557
|
-
"
|
1558
|
-
"extendedProperties": extended_properties
|
1547
|
+
"description": description, "collectionType": collection_type,
|
1548
|
+
"additionalProperties": additional_properties, "extendedProperties": extended_properties
|
1559
1549
|
},
|
1560
1550
|
}
|
1561
1551
|
|
1562
1552
|
resp = await self._async_make_request("POST", url, body_slimmer(body))
|
1563
1553
|
return resp.json().get("guid", "No GUID returned")
|
1564
1554
|
|
1565
|
-
async def _async_create_root_collection(self, display_name: str, description: str,
|
1566
|
-
|
1567
|
-
|
1568
|
-
|
1569
|
-
|
1555
|
+
async def _async_create_root_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1556
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
1557
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
1558
|
+
parent_at_end1: bool = True, collection_type: str = None,
|
1559
|
+
anchor_scope_guid: str = None,
|
1560
|
+
|
1570
1561
|
additional_properties: dict = None,
|
1571
1562
|
extended_properties: dict = None) -> str:
|
1572
1563
|
""" Create a new collection with the RootCollection classification. Used to identify the top of a collection
|
@@ -1580,6 +1571,8 @@ class CollectionManager(Client):
|
|
1580
1571
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1581
1572
|
description: str
|
1582
1573
|
A description of the collection.
|
1574
|
+
qualified_name: str, optional, defaults to None
|
1575
|
+
Allows user to specify a qualified name of the collection.
|
1583
1576
|
is_own_anchor: bool, optional, defaults to True
|
1584
1577
|
Indicates if the collection should be classified as its own anchor or not.
|
1585
1578
|
anchor_guid: str
|
@@ -1597,11 +1590,6 @@ class CollectionManager(Client):
|
|
1597
1590
|
Adds an user supplied valid value for the collection type.
|
1598
1591
|
anchor_scope_guid: str, optional, defaults to None
|
1599
1592
|
optional GUID of search scope
|
1600
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1601
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1602
|
-
"OTHER"
|
1603
|
-
order_property_name: str, optional, defaults to "Something"
|
1604
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1605
1593
|
additional_properties: dict, optional, defaults to None
|
1606
1594
|
User specified Additional properties to add to the collection definition.
|
1607
1595
|
extended_properties: dict, optional, defaults to None
|
@@ -1623,19 +1611,24 @@ class CollectionManager(Client):
|
|
1623
1611
|
|
1624
1612
|
"""
|
1625
1613
|
|
1626
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
1627
|
-
|
1628
|
-
|
1629
|
-
|
1630
|
-
|
1614
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
1615
|
+
is_own_anchor=is_own_anchor, url_item="root-collection",
|
1616
|
+
classification_name="RootCollection",
|
1617
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
1618
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
1619
|
+
parent_at_end1=parent_at_end1,
|
1620
|
+
collection_type=collection_type,
|
1621
|
+
anchor_scope_guid=anchor_scope_guid,
|
1622
|
+
additional_properties=additional_properties,
|
1623
|
+
extended_properties=extended_properties)
|
1631
1624
|
|
1632
1625
|
return resp
|
1633
1626
|
|
1634
|
-
def create_root_collection(self, display_name: str, description: str,
|
1635
|
-
anchor_guid: str = None, parent_guid: str = None,
|
1627
|
+
def create_root_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1628
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
1636
1629
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
1637
1630
|
collection_type: str = None, anchor_scope_guid: str = None,
|
1638
|
-
|
1631
|
+
|
1639
1632
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
1640
1633
|
""" Create a new collection with the RootCollection classification.
|
1641
1634
|
Used to identify the top of a collection hierarchy.
|
@@ -1647,6 +1640,8 @@ class CollectionManager(Client):
|
|
1647
1640
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1648
1641
|
description: str
|
1649
1642
|
A description of the collection.
|
1643
|
+
qualified_name: str, optional, defaults to None
|
1644
|
+
Allows user to specify a qualified name of the collection.
|
1650
1645
|
is_own_anchor: bool, optional, defaults to True
|
1651
1646
|
Indicates if the collection should be classified as its own anchor or not.
|
1652
1647
|
anchor_guid: str
|
@@ -1664,11 +1659,6 @@ class CollectionManager(Client):
|
|
1664
1659
|
Adds an user supplied valid value for the collection type.
|
1665
1660
|
anchor_scope_guid: str, optional, defaults to None
|
1666
1661
|
optional GUID of search scope
|
1667
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1668
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1669
|
-
"OTHER"
|
1670
|
-
order_property_name: str, optional, defaults to "Something"
|
1671
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1672
1662
|
additional_properties: dict, optional, defaults to None
|
1673
1663
|
User specified Additional properties to add to the collection definition.
|
1674
1664
|
extended_properties: dict, optional, defaults to None
|
@@ -1691,18 +1681,17 @@ class CollectionManager(Client):
|
|
1691
1681
|
"""
|
1692
1682
|
loop = asyncio.get_event_loop()
|
1693
1683
|
resp = loop.run_until_complete(
|
1694
|
-
self._async_create_root_collection(display_name, description, is_own_anchor, anchor_guid,
|
1695
|
-
parent_relationship_type_name, parent_at_end1,
|
1696
|
-
|
1697
|
-
|
1684
|
+
self._async_create_root_collection(display_name, description, qualified_name, is_own_anchor, anchor_guid,
|
1685
|
+
parent_guid, parent_relationship_type_name, parent_at_end1,
|
1686
|
+
collection_type, anchor_scope_guid, additional_properties,
|
1687
|
+
extended_properties))
|
1698
1688
|
return resp
|
1699
1689
|
|
1700
|
-
async def _async_create_data_spec_collection(self, display_name: str, description: str,
|
1701
|
-
|
1702
|
-
|
1703
|
-
|
1704
|
-
|
1705
|
-
additional_properties: dict = None,
|
1690
|
+
async def _async_create_data_spec_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1691
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
1692
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
1693
|
+
parent_at_end1: bool = True, collection_type: str = None,
|
1694
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
1706
1695
|
extended_properties: dict = None) -> str:
|
1707
1696
|
""" Create a new collection with the DataSpec classification. Used to identify a collection of data
|
1708
1697
|
structures and
|
@@ -1715,6 +1704,8 @@ class CollectionManager(Client):
|
|
1715
1704
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1716
1705
|
description: str
|
1717
1706
|
A description of the collection.
|
1707
|
+
qualified_name: str, optional, defaults to None
|
1708
|
+
Allows user to specify a qualified name of the collection.
|
1718
1709
|
is_own_anchor: bool, optional, defaults to True
|
1719
1710
|
Indicates if the collection should be classified as its own anchor or not.
|
1720
1711
|
anchor_guid: str
|
@@ -1732,11 +1723,6 @@ class CollectionManager(Client):
|
|
1732
1723
|
Adds an user supplied valid value for the collection type.
|
1733
1724
|
anchor_scope_guid: str, optional, defaults to None
|
1734
1725
|
optional GUID of search scope
|
1735
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1736
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1737
|
-
"OTHER"
|
1738
|
-
order_property_name: str, optional, defaults to "Something"
|
1739
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1740
1726
|
additional_properties: dict, optional, defaults to None
|
1741
1727
|
User specified Additional properties to add to the collection definition.
|
1742
1728
|
extended_properties: dict, optional, defaults to None
|
@@ -1758,20 +1744,24 @@ class CollectionManager(Client):
|
|
1758
1744
|
|
1759
1745
|
"""
|
1760
1746
|
|
1761
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
1762
|
-
"data-spec-collection",
|
1763
|
-
|
1764
|
-
|
1765
|
-
|
1766
|
-
|
1747
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
1748
|
+
is_own_anchor=is_own_anchor, url_item="data-spec-collection",
|
1749
|
+
classification_name="DataSpec", anchor_guid=anchor_guid,
|
1750
|
+
parent_guid=parent_guid,
|
1751
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
1752
|
+
parent_at_end1=parent_at_end1,
|
1753
|
+
collection_type=collection_type,
|
1754
|
+
anchor_scope_guid=anchor_scope_guid,
|
1755
|
+
additional_properties=additional_properties,
|
1756
|
+
extended_properties=extended_properties)
|
1767
1757
|
|
1768
1758
|
return resp
|
1769
1759
|
|
1770
|
-
def create_data_spec_collection(self, display_name: str, description: str,
|
1771
|
-
anchor_guid: str = None, parent_guid: str = None,
|
1760
|
+
def create_data_spec_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1761
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
1772
1762
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
1773
1763
|
collection_type: str = None, anchor_scope_guid: str = None,
|
1774
|
-
|
1764
|
+
|
1775
1765
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
1776
1766
|
""" Create a new collection with the DataSpec classification. Used to identify a collection of data
|
1777
1767
|
structures and
|
@@ -1783,6 +1773,8 @@ class CollectionManager(Client):
|
|
1783
1773
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1784
1774
|
description: str
|
1785
1775
|
A description of the collection.
|
1776
|
+
qualified_name: str, optional, defaults to None
|
1777
|
+
Allows user to specify a qualified name of the collection.
|
1786
1778
|
is_own_anchor: bool, optional, defaults to True
|
1787
1779
|
Indicates if the collection should be classified as its own anchor or not.
|
1788
1780
|
anchor_guid: str
|
@@ -1800,11 +1792,6 @@ class CollectionManager(Client):
|
|
1800
1792
|
Adds an user supplied valid value for the collection type.
|
1801
1793
|
anchor_scope_guid: str, optional, defaults to None
|
1802
1794
|
optional GUID of search scope
|
1803
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1804
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1805
|
-
"OTHER"
|
1806
|
-
order_property_name: str, optional, defaults to "Something"
|
1807
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1808
1795
|
additional_properties: dict, optional, defaults to None
|
1809
1796
|
User specified Additional properties to add to the collection definition.
|
1810
1797
|
extended_properties: dict, optional, defaults to None
|
@@ -1827,19 +1814,18 @@ class CollectionManager(Client):
|
|
1827
1814
|
"""
|
1828
1815
|
loop = asyncio.get_event_loop()
|
1829
1816
|
resp = loop.run_until_complete(
|
1830
|
-
self._async_create_data_spec_collection(display_name, description,
|
1831
|
-
|
1832
|
-
|
1817
|
+
self._async_create_data_spec_collection(display_name, description, qualified_name, is_own_anchor,
|
1818
|
+
anchor_guid, parent_guid, parent_relationship_type_name,
|
1819
|
+
parent_at_end1, collection_type, anchor_scope_guid,
|
1833
1820
|
additional_properties, extended_properties))
|
1834
1821
|
return resp
|
1835
1822
|
|
1836
1823
|
async def _async_create_data_dictionary_collection(self, display_name: str, description: str,
|
1837
|
-
|
1838
|
-
parent_guid: str = None,
|
1824
|
+
qualified_name: str = None, is_own_anchor: bool = True,
|
1825
|
+
anchor_guid: str = None, parent_guid: str = None,
|
1839
1826
|
parent_relationship_type_name: str = None,
|
1840
1827
|
parent_at_end1: bool = True, collection_type: str = None,
|
1841
|
-
anchor_scope_guid: str = None,
|
1842
|
-
order_property_name: str = None,
|
1828
|
+
anchor_scope_guid: str = None,
|
1843
1829
|
additional_properties: dict = None,
|
1844
1830
|
extended_properties: dict = None) -> str:
|
1845
1831
|
""" Create a new collection with the DataDictionary classification. Used to identify a collection of data
|
@@ -1853,6 +1839,8 @@ class CollectionManager(Client):
|
|
1853
1839
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1854
1840
|
description: str
|
1855
1841
|
A description of the collection.
|
1842
|
+
qualified_name: str, optional, defaults to None
|
1843
|
+
Allows user to specify a qualified name of the collection.
|
1856
1844
|
is_own_anchor: bool, optional, defaults to True
|
1857
1845
|
Indicates if the collection should be classified as its own anchor or not.
|
1858
1846
|
anchor_guid: str
|
@@ -1870,11 +1858,6 @@ class CollectionManager(Client):
|
|
1870
1858
|
Adds an user supplied valid value for the collection type.
|
1871
1859
|
anchor_scope_guid: str, optional, defaults to None
|
1872
1860
|
optional GUID of search scope
|
1873
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1874
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1875
|
-
"OTHER"
|
1876
|
-
order_property_name: str, optional, defaults to "Something"
|
1877
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1878
1861
|
additional_properties: dict, optional, defaults to None
|
1879
1862
|
User specified Additional properties to add to the collection definition.
|
1880
1863
|
extended_properties: dict, optional, defaults to None
|
@@ -1896,20 +1879,25 @@ class CollectionManager(Client):
|
|
1896
1879
|
|
1897
1880
|
"""
|
1898
1881
|
|
1899
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
1900
|
-
|
1901
|
-
|
1902
|
-
|
1903
|
-
|
1904
|
-
|
1882
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
1883
|
+
is_own_anchor=is_own_anchor,
|
1884
|
+
url_item="data-dictionary-collection",
|
1885
|
+
classification_name="DataDictionary",
|
1886
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
1887
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
1888
|
+
parent_at_end1=parent_at_end1,
|
1889
|
+
collection_type=collection_type,
|
1890
|
+
anchor_scope_guid=anchor_scope_guid,
|
1891
|
+
additional_properties=additional_properties,
|
1892
|
+
extended_properties=extended_properties)
|
1905
1893
|
|
1906
1894
|
return resp
|
1907
1895
|
|
1908
|
-
def create_data_dictionary_collection(self, display_name: str, description: str,
|
1909
|
-
anchor_guid: str = None, parent_guid: str = None,
|
1896
|
+
def create_data_dictionary_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1897
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
1910
1898
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
1911
1899
|
collection_type: str = None, anchor_scope_guid: str = None,
|
1912
|
-
|
1900
|
+
|
1913
1901
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
1914
1902
|
""" Create a new collection with the DataSpec classification. Used to identify a collection of data
|
1915
1903
|
structures and
|
@@ -1921,6 +1909,8 @@ class CollectionManager(Client):
|
|
1921
1909
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1922
1910
|
description: str
|
1923
1911
|
A description of the collection.
|
1912
|
+
qualified_name: str, optional, defaults to None
|
1913
|
+
Allows user to specify a qualified name of the collection.
|
1924
1914
|
is_own_anchor: bool, optional, defaults to True
|
1925
1915
|
Indicates if the collection should be classified as its own anchor or not.
|
1926
1916
|
anchor_guid: str
|
@@ -1938,11 +1928,6 @@ class CollectionManager(Client):
|
|
1938
1928
|
Adds an user supplied valid value for the collection type.
|
1939
1929
|
anchor_scope_guid: str, optional, defaults to None
|
1940
1930
|
optional GUID of search scope
|
1941
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
1942
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
1943
|
-
"OTHER"
|
1944
|
-
order_property_name: str, optional, defaults to "Something"
|
1945
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
1946
1931
|
additional_properties: dict, optional, defaults to None
|
1947
1932
|
User specified Additional properties to add to the collection definition.
|
1948
1933
|
extended_properties: dict, optional, defaults to None
|
@@ -1965,18 +1950,18 @@ class CollectionManager(Client):
|
|
1965
1950
|
"""
|
1966
1951
|
loop = asyncio.get_event_loop()
|
1967
1952
|
resp = loop.run_until_complete(
|
1968
|
-
self._async_create_data_dictionary_collection(display_name, description,
|
1969
|
-
parent_guid, parent_relationship_type_name,
|
1970
|
-
collection_type, anchor_scope_guid,
|
1971
|
-
|
1972
|
-
extended_properties))
|
1953
|
+
self._async_create_data_dictionary_collection(display_name, description, qualified_name, is_own_anchor,
|
1954
|
+
anchor_guid, parent_guid, parent_relationship_type_name,
|
1955
|
+
parent_at_end1, collection_type, anchor_scope_guid,
|
1956
|
+
additional_properties, extended_properties))
|
1973
1957
|
return resp
|
1974
1958
|
|
1975
|
-
async def _async_create_folder_collection(self, display_name: str, description: str,
|
1976
|
-
|
1977
|
-
|
1978
|
-
|
1979
|
-
|
1959
|
+
async def _async_create_folder_collection(self, display_name: str, description: str, qualified_name: str = None,
|
1960
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
1961
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
1962
|
+
parent_at_end1: bool = True, collection_type: str = None,
|
1963
|
+
anchor_scope_guid: str = None,
|
1964
|
+
|
1980
1965
|
additional_properties: dict = None,
|
1981
1966
|
extended_properties: dict = None) -> str:
|
1982
1967
|
""" Create a new collection with the Folder classification. This is used to identify the organizing collections
|
@@ -1989,6 +1974,8 @@ class CollectionManager(Client):
|
|
1989
1974
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
1990
1975
|
description: str
|
1991
1976
|
A description of the collection.
|
1977
|
+
qualified_name: str, optional, defaults to None
|
1978
|
+
Allows user to specify a qualified name of the collection.
|
1992
1979
|
is_own_anchor: bool, optional, defaults to True
|
1993
1980
|
Indicates if the collection should be classified as its own anchor or not.
|
1994
1981
|
anchor_guid: str
|
@@ -2006,11 +1993,6 @@ class CollectionManager(Client):
|
|
2006
1993
|
Adds an user supplied valid value for the collection type.
|
2007
1994
|
anchor_scope_guid: str, optional, defaults to None
|
2008
1995
|
optional GUID of search scope
|
2009
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2010
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2011
|
-
"OTHER"
|
2012
|
-
order_property_name: str, optional, defaults to "Something"
|
2013
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2014
1996
|
additional_properties: dict, optional, defaults to None
|
2015
1997
|
User specified Additional properties to add to the collection definition.
|
2016
1998
|
extended_properties: dict, optional, defaults to None
|
@@ -2032,19 +2014,24 @@ class CollectionManager(Client):
|
|
2032
2014
|
|
2033
2015
|
"""
|
2034
2016
|
|
2035
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
2036
|
-
|
2037
|
-
|
2038
|
-
|
2039
|
-
|
2017
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
2018
|
+
is_own_anchor=is_own_anchor, url_item="folder",
|
2019
|
+
classification_name="Folder", anchor_guid=anchor_guid,
|
2020
|
+
parent_guid=parent_guid,
|
2021
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
2022
|
+
parent_at_end1=parent_at_end1,
|
2023
|
+
collection_type=collection_type,
|
2024
|
+
anchor_scope_guid=anchor_scope_guid,
|
2025
|
+
additional_properties=additional_properties,
|
2026
|
+
extended_properties=extended_properties)
|
2040
2027
|
|
2041
2028
|
return resp
|
2042
2029
|
|
2043
|
-
def create_folder_collection(self, display_name: str, description: str,
|
2044
|
-
anchor_guid: str = None, parent_guid: str = None,
|
2030
|
+
def create_folder_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2031
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
2045
2032
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
2046
2033
|
collection_type: str = None, anchor_scope_guid: str = None,
|
2047
|
-
|
2034
|
+
|
2048
2035
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
2049
2036
|
""" Create a new collection with the Folder classification. This is used to identify the organizing collections
|
2050
2037
|
in a collection hierarchy.
|
@@ -2055,6 +2042,8 @@ class CollectionManager(Client):
|
|
2055
2042
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2056
2043
|
description: str
|
2057
2044
|
A description of the collection.
|
2045
|
+
qualified_name: str, optional, defaults to None
|
2046
|
+
Allows user to specify a qualified name of the collection.
|
2058
2047
|
is_own_anchor: bool, optional, defaults to True
|
2059
2048
|
Indicates if the collection should be classified as its own anchor or not.
|
2060
2049
|
anchor_guid: str
|
@@ -2072,11 +2061,6 @@ class CollectionManager(Client):
|
|
2072
2061
|
Adds an user supplied valid value for the collection type.
|
2073
2062
|
anchor_scope_guid: str, optional, defaults to None
|
2074
2063
|
optional GUID of search scope
|
2075
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2076
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2077
|
-
"OTHER"
|
2078
|
-
order_property_name: str, optional, defaults to "Something"
|
2079
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2080
2064
|
additional_properties: dict, optional, defaults to None
|
2081
2065
|
User specified Additional properties to add to the collection definition.
|
2082
2066
|
extended_properties: dict, optional, defaults to None
|
@@ -2099,19 +2083,18 @@ class CollectionManager(Client):
|
|
2099
2083
|
"""
|
2100
2084
|
loop = asyncio.get_event_loop()
|
2101
2085
|
resp = loop.run_until_complete(
|
2102
|
-
self._async_create_folder_collection(display_name, description, is_own_anchor, anchor_guid,
|
2103
|
-
parent_relationship_type_name, parent_at_end1,
|
2104
|
-
|
2105
|
-
|
2086
|
+
self._async_create_folder_collection(display_name, description, qualified_name, is_own_anchor, anchor_guid,
|
2087
|
+
parent_guid, parent_relationship_type_name, parent_at_end1,
|
2088
|
+
collection_type, anchor_scope_guid, additional_properties,
|
2089
|
+
extended_properties))
|
2106
2090
|
return resp
|
2107
2091
|
|
2108
2092
|
async def _async_create_context_event_collection(self, display_name: str, description: str,
|
2109
|
-
|
2110
|
-
|
2093
|
+
qualified_name: str = None, is_own_anchor: bool = True,
|
2094
|
+
anchor_guid: str = None, parent_guid: str = None,
|
2095
|
+
parent_relationship_type_name: str = None,
|
2111
2096
|
parent_at_end1: bool = True, collection_type: str = None,
|
2112
|
-
anchor_scope_guid: str = None,
|
2113
|
-
order_property_name: str = None,
|
2114
|
-
additional_properties: dict = None,
|
2097
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
2115
2098
|
extended_properties: dict = None) -> str:
|
2116
2099
|
""" Create a new collection with the ContextEventCollection classification. This is used to group context
|
2117
2100
|
events together.
|
@@ -2124,6 +2107,8 @@ class CollectionManager(Client):
|
|
2124
2107
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2125
2108
|
description: str
|
2126
2109
|
A description of the collection.
|
2110
|
+
qualified_name: str, optional, defaults to None
|
2111
|
+
Allows user to specify a qualified name of the collection.
|
2127
2112
|
is_own_anchor: bool, optional, defaults to True
|
2128
2113
|
Indicates if the collection should be classified as its own anchor or not.
|
2129
2114
|
anchor_guid: str
|
@@ -2141,11 +2126,6 @@ class CollectionManager(Client):
|
|
2141
2126
|
Adds an user supplied valid value for the collection type.
|
2142
2127
|
anchor_scope_guid: str, optional, defaults to None
|
2143
2128
|
optional GUID of search scope
|
2144
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2145
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2146
|
-
"OTHER"
|
2147
|
-
order_property_name: str, optional, defaults to "Something"
|
2148
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2149
2129
|
additional_properties: dict, optional, defaults to None
|
2150
2130
|
User specified Additional properties to add to the collection definition.
|
2151
2131
|
extended_properties: dict, optional, defaults to None
|
@@ -2167,20 +2147,25 @@ class CollectionManager(Client):
|
|
2167
2147
|
|
2168
2148
|
"""
|
2169
2149
|
|
2170
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
2171
|
-
|
2172
|
-
|
2173
|
-
|
2174
|
-
|
2175
|
-
|
2150
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
2151
|
+
is_own_anchor=is_own_anchor,
|
2152
|
+
url_item="context-event-collection",
|
2153
|
+
classification_name="CtxEventCollection",
|
2154
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
2155
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
2156
|
+
parent_at_end1=parent_at_end1,
|
2157
|
+
collection_type=collection_type,
|
2158
|
+
anchor_scope_guid=anchor_scope_guid,
|
2159
|
+
additional_properties=additional_properties,
|
2160
|
+
extended_properties=extended_properties)
|
2176
2161
|
|
2177
2162
|
return resp
|
2178
2163
|
|
2179
|
-
def create_context_event_collection(self, display_name: str, description: str,
|
2180
|
-
anchor_guid: str = None, parent_guid: str = None,
|
2164
|
+
def create_context_event_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2165
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
2181
2166
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
2182
2167
|
collection_type: str = None, anchor_scope_guid: str = None,
|
2183
|
-
|
2168
|
+
|
2184
2169
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
2185
2170
|
""" Create a new collection with the ContextEventCollection classification. This is used to group context
|
2186
2171
|
events together.
|
@@ -2192,6 +2177,8 @@ class CollectionManager(Client):
|
|
2192
2177
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2193
2178
|
description: str
|
2194
2179
|
A description of the collection.
|
2180
|
+
qualified_name: str, optional, defaults to None
|
2181
|
+
Allows user to specify a qualified name of the collection.
|
2195
2182
|
is_own_anchor: bool, optional, defaults to True
|
2196
2183
|
Indicates if the collection should be classified as its own anchor or not.
|
2197
2184
|
anchor_guid: str
|
@@ -2209,11 +2196,6 @@ class CollectionManager(Client):
|
|
2209
2196
|
Adds an user supplied valid value for the collection type.
|
2210
2197
|
anchor_scope_guid: str, optional, defaults to None
|
2211
2198
|
optional GUID of search scope
|
2212
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2213
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2214
|
-
"OTHER"
|
2215
|
-
order_property_name: str, optional, defaults to "Something"
|
2216
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2217
2199
|
additional_properties: dict, optional, defaults to None
|
2218
2200
|
User specified Additional properties to add to the collection definition.
|
2219
2201
|
extended_properties: dict, optional, defaults to None
|
@@ -2236,18 +2218,17 @@ class CollectionManager(Client):
|
|
2236
2218
|
"""
|
2237
2219
|
loop = asyncio.get_event_loop()
|
2238
2220
|
resp = loop.run_until_complete(
|
2239
|
-
self._async_create_context_event_collection(display_name, description,
|
2240
|
-
|
2241
|
-
|
2242
|
-
|
2221
|
+
self._async_create_context_event_collection(display_name, description, qualified_name, is_own_anchor,
|
2222
|
+
anchor_guid, parent_guid, parent_relationship_type_name,
|
2223
|
+
parent_at_end1, collection_type, anchor_scope_guid,
|
2224
|
+
additional_properties, extended_properties))
|
2243
2225
|
return resp
|
2244
2226
|
|
2245
|
-
async def _async_create_name_space_collection(self, display_name: str, description: str,
|
2246
|
-
|
2247
|
-
parent_relationship_type_name: str = None,
|
2227
|
+
async def _async_create_name_space_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2228
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
2229
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
2248
2230
|
parent_at_end1: bool = True, collection_type: str = None,
|
2249
|
-
anchor_scope_guid: str = None,
|
2250
|
-
order_property_name: str = None, additional_properties: dict = None,
|
2231
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
2251
2232
|
extended_properties: dict = None) -> str:
|
2252
2233
|
""" Create a new collection with the Namespace classification. This is used to group elements that belong to
|
2253
2234
|
the same namespace.
|
@@ -2261,6 +2242,8 @@ class CollectionManager(Client):
|
|
2261
2242
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2262
2243
|
description: str
|
2263
2244
|
A description of the collection.
|
2245
|
+
qualified_name: str, optional, defaults to None
|
2246
|
+
Allows user to specify a qualified name of the collection.
|
2264
2247
|
is_own_anchor: bool, optional, defaults to True
|
2265
2248
|
Indicates if the collection should be classified as its own anchor or not.
|
2266
2249
|
anchor_guid: str
|
@@ -2278,11 +2261,6 @@ class CollectionManager(Client):
|
|
2278
2261
|
Adds an user supplied valid value for the collection type.
|
2279
2262
|
anchor_scope_guid: str, optional, defaults to None
|
2280
2263
|
optional GUID of search scope
|
2281
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2282
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2283
|
-
"OTHER"
|
2284
|
-
order_property_name: str, optional, defaults to "Something"
|
2285
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2286
2264
|
additional_properties: dict, optional, defaults to None
|
2287
2265
|
User specified Additional properties to add to the collection definition.
|
2288
2266
|
extended_properties: dict, optional, defaults to None
|
@@ -2304,20 +2282,24 @@ class CollectionManager(Client):
|
|
2304
2282
|
|
2305
2283
|
"""
|
2306
2284
|
|
2307
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
2308
|
-
"namespace-collection",
|
2309
|
-
|
2310
|
-
|
2311
|
-
|
2312
|
-
|
2285
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
2286
|
+
is_own_anchor=is_own_anchor, url_item="namespace-collection",
|
2287
|
+
classification_name="NamespaceCollection",
|
2288
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
2289
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
2290
|
+
parent_at_end1=parent_at_end1,
|
2291
|
+
collection_type=collection_type,
|
2292
|
+
anchor_scope_guid=anchor_scope_guid,
|
2293
|
+
additional_properties=additional_properties,
|
2294
|
+
extended_properties=extended_properties)
|
2313
2295
|
|
2314
2296
|
return resp
|
2315
2297
|
|
2316
|
-
def create_name_space_collection(self, display_name: str, description: str,
|
2317
|
-
anchor_guid: str = None, parent_guid: str = None,
|
2298
|
+
def create_name_space_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2299
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
2318
2300
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
2319
2301
|
collection_type: str = None, anchor_scope_guid: str = None,
|
2320
|
-
|
2302
|
+
|
2321
2303
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
2322
2304
|
""" Create a new collection with the Namespace classification. This is used to group elements that belong to
|
2323
2305
|
the same namespace.
|
@@ -2330,6 +2312,8 @@ class CollectionManager(Client):
|
|
2330
2312
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2331
2313
|
description: str
|
2332
2314
|
A description of the collection.
|
2315
|
+
qualified_name: str, optional, defaults to None
|
2316
|
+
Allows user to specify a qualified name of the collection.
|
2333
2317
|
is_own_anchor: bool, optional, defaults to True
|
2334
2318
|
Indicates if the collection should be classified as its own anchor or not.
|
2335
2319
|
anchor_guid: str
|
@@ -2347,11 +2331,6 @@ class CollectionManager(Client):
|
|
2347
2331
|
Adds an user supplied valid value for the collection type.
|
2348
2332
|
anchor_scope_guid: str, optional, defaults to None
|
2349
2333
|
optional GUID of search scope
|
2350
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2351
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2352
|
-
"OTHER"
|
2353
|
-
order_property_name: str, optional, defaults to "Something"
|
2354
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2355
2334
|
additional_properties: dict, optional, defaults to None
|
2356
2335
|
User specified Additional properties to add to the collection definition.
|
2357
2336
|
extended_properties: dict, optional, defaults to None
|
@@ -2374,17 +2353,17 @@ class CollectionManager(Client):
|
|
2374
2353
|
"""
|
2375
2354
|
loop = asyncio.get_event_loop()
|
2376
2355
|
resp = loop.run_until_complete(
|
2377
|
-
self._async_create_name_space_collection(display_name, description,
|
2378
|
-
|
2379
|
-
|
2380
|
-
additional_properties, extended_properties))
|
2356
|
+
self._async_create_name_space_collection(display_name, description, qualified_name, is_own_anchor,
|
2357
|
+
anchor_guid, parent_guid, parent_relationship_type_name,
|
2358
|
+
parent_at_end1, collection_type, anchor_scope_guid))
|
2381
2359
|
return resp
|
2382
2360
|
|
2383
|
-
async def _async_create_event_set_collection(self, display_name: str, description: str,
|
2384
|
-
|
2385
|
-
|
2386
|
-
|
2387
|
-
|
2361
|
+
async def _async_create_event_set_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2362
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
2363
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
2364
|
+
parent_at_end1: bool = True, collection_type: str = None,
|
2365
|
+
anchor_scope_guid: str = None,
|
2366
|
+
|
2388
2367
|
additional_properties: dict = None,
|
2389
2368
|
extended_properties: dict = None) -> str:
|
2390
2369
|
""" Create a new collection with the EventSet classification. This is used to group event schemas together.
|
@@ -2398,6 +2377,8 @@ class CollectionManager(Client):
|
|
2398
2377
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2399
2378
|
description: str
|
2400
2379
|
A description of the collection.
|
2380
|
+
qualified_name: str, optional, defaults to None
|
2381
|
+
Allows user to specify a qualified name of the collection.
|
2401
2382
|
is_own_anchor: bool, optional, defaults to True
|
2402
2383
|
Indicates if the collection should be classified as its own anchor or not.
|
2403
2384
|
anchor_guid: str
|
@@ -2415,11 +2396,6 @@ class CollectionManager(Client):
|
|
2415
2396
|
Adds an user supplied valid value for the collection type.
|
2416
2397
|
anchor_scope_guid: str, optional, defaults to None
|
2417
2398
|
optional GUID of search scope
|
2418
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2419
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2420
|
-
"OTHER"
|
2421
|
-
order_property_name: str, optional, defaults to "Something"
|
2422
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2423
2399
|
additional_properties: dict, optional, defaults to None
|
2424
2400
|
User specified Additional properties to add to the collection definition.
|
2425
2401
|
extended_properties: dict, optional, defaults to None
|
@@ -2441,20 +2417,24 @@ class CollectionManager(Client):
|
|
2441
2417
|
|
2442
2418
|
"""
|
2443
2419
|
|
2444
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
2445
|
-
"event-set-collection",
|
2446
|
-
|
2447
|
-
|
2448
|
-
|
2449
|
-
|
2420
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
2421
|
+
is_own_anchor=is_own_anchor, url_item="event-set-collection",
|
2422
|
+
classification_name="EventSetCollection",
|
2423
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
2424
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
2425
|
+
parent_at_end1=parent_at_end1,
|
2426
|
+
collection_type=collection_type,
|
2427
|
+
anchor_scope_guid=anchor_scope_guid,
|
2428
|
+
additional_properties=additional_properties,
|
2429
|
+
extended_properties=extended_properties)
|
2450
2430
|
|
2451
2431
|
return resp
|
2452
2432
|
|
2453
|
-
def create_event_set_collection(self, display_name: str, description: str,
|
2454
|
-
anchor_guid: str = None, parent_guid: str = None,
|
2433
|
+
def create_event_set_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2434
|
+
is_own_anchor: bool = True, anchor_guid: str = None, parent_guid: str = None,
|
2455
2435
|
parent_relationship_type_name: str = None, parent_at_end1: bool = True,
|
2456
2436
|
collection_type: str = None, anchor_scope_guid: str = None,
|
2457
|
-
|
2437
|
+
|
2458
2438
|
additional_properties: dict = None, extended_properties: dict = None) -> str:
|
2459
2439
|
""" Create a new collection with the EventSet classification. This is used to group event schemas together.
|
2460
2440
|
For example, the collection may describe a set of events emitted by a specific system or to disseminate
|
@@ -2466,6 +2446,8 @@ class CollectionManager(Client):
|
|
2466
2446
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2467
2447
|
description: str
|
2468
2448
|
A description of the collection.
|
2449
|
+
qualified_name: str, optional, defaults to None
|
2450
|
+
Allows user to specify a qualified name of the collection.
|
2469
2451
|
is_own_anchor: bool, optional, defaults to True
|
2470
2452
|
Indicates if the collection should be classified as its own anchor or not.
|
2471
2453
|
anchor_guid: str
|
@@ -2483,11 +2465,6 @@ class CollectionManager(Client):
|
|
2483
2465
|
Adds an user supplied valid value for the collection type.
|
2484
2466
|
anchor_scope_guid: str, optional, defaults to None
|
2485
2467
|
optional GUID of search scope
|
2486
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2487
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2488
|
-
"OTHER"
|
2489
|
-
order_property_name: str, optional, defaults to "Something"
|
2490
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2491
2468
|
additional_properties: dict, optional, defaults to None
|
2492
2469
|
User specified Additional properties to add to the collection definition.
|
2493
2470
|
extended_properties: dict, optional, defaults to None
|
@@ -2510,20 +2487,18 @@ class CollectionManager(Client):
|
|
2510
2487
|
"""
|
2511
2488
|
loop = asyncio.get_event_loop()
|
2512
2489
|
resp = loop.run_until_complete(
|
2513
|
-
self._async_create_event_set_collection(display_name, description,
|
2514
|
-
|
2515
|
-
|
2490
|
+
self._async_create_event_set_collection(display_name, description, qualified_name, is_own_anchor,
|
2491
|
+
anchor_guid, parent_guid, parent_relationship_type_name,
|
2492
|
+
parent_at_end1, collection_type, anchor_scope_guid,
|
2516
2493
|
additional_properties, extended_properties))
|
2517
2494
|
return resp
|
2518
2495
|
|
2519
2496
|
async def _async_create_naming_standard_ruleset_collection(self, display_name: str, description: str,
|
2520
|
-
|
2521
|
-
parent_guid: str = None,
|
2497
|
+
qualified_name: str = None, is_own_anchor: bool = True,
|
2498
|
+
anchor_guid: str = None, parent_guid: str = None,
|
2522
2499
|
parent_relationship_type_name: str = None,
|
2523
2500
|
parent_at_end1: bool = True, collection_type: str = None,
|
2524
2501
|
anchor_scope_guid: str = None,
|
2525
|
-
collection_ordering: str = None,
|
2526
|
-
order_property_name: str = None,
|
2527
2502
|
additional_properties: dict = None,
|
2528
2503
|
extended_properties: dict = None) -> str:
|
2529
2504
|
""" Create a new collection with the NamingStandardRuleSet classification. This is used to group naming
|
@@ -2537,6 +2512,8 @@ class CollectionManager(Client):
|
|
2537
2512
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2538
2513
|
description: str
|
2539
2514
|
A description of the collection.
|
2515
|
+
qualified_name: str, optional, defaults to None
|
2516
|
+
Allows user to specify a qualified name of the collection.
|
2540
2517
|
is_own_anchor: bool, optional, defaults to True
|
2541
2518
|
Indicates if the collection should be classified as its own anchor or not.
|
2542
2519
|
anchor_guid: str
|
@@ -2554,11 +2531,6 @@ class CollectionManager(Client):
|
|
2554
2531
|
Adds an user supplied valid value for the collection type.
|
2555
2532
|
anchor_scope_guid: str, optional, defaults to None
|
2556
2533
|
optional GUID of search scope
|
2557
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2558
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2559
|
-
"OTHER"
|
2560
|
-
order_property_name: str, optional, defaults to "Something"
|
2561
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2562
2534
|
additional_properties: dict, optional, defaults to None
|
2563
2535
|
User specified Additional properties to add to the collection definition.
|
2564
2536
|
extended_properties: dict, optional, defaults to None
|
@@ -2580,21 +2552,25 @@ class CollectionManager(Client):
|
|
2580
2552
|
|
2581
2553
|
"""
|
2582
2554
|
|
2583
|
-
resp = await self._async_create_generic_collection(display_name, description,
|
2584
|
-
|
2585
|
-
|
2586
|
-
|
2587
|
-
|
2588
|
-
|
2555
|
+
resp = await self._async_create_generic_collection(display_name, description, qualified_name,
|
2556
|
+
is_own_anchor=is_own_anchor,
|
2557
|
+
url_item="naming-standard-rule-set-collection",
|
2558
|
+
classification_name="NamingRulesCollection",
|
2559
|
+
anchor_guid=anchor_guid, parent_guid=parent_guid,
|
2560
|
+
parent_relationship_type_name=parent_relationship_type_name,
|
2561
|
+
parent_at_end1=parent_at_end1,
|
2562
|
+
collection_type=collection_type,
|
2563
|
+
anchor_scope_guid=anchor_scope_guid,
|
2564
|
+
additional_properties=additional_properties,
|
2565
|
+
extended_properties=extended_properties)
|
2589
2566
|
|
2590
2567
|
return resp
|
2591
2568
|
|
2592
|
-
def create_naming_standard_ruleset_collection(self, display_name: str, description: str,
|
2593
|
-
|
2594
|
-
parent_relationship_type_name: str = None,
|
2569
|
+
def create_naming_standard_ruleset_collection(self, display_name: str, description: str, qualified_name: str = None,
|
2570
|
+
is_own_anchor: bool = True, anchor_guid: str = None,
|
2571
|
+
parent_guid: str = None, parent_relationship_type_name: str = None,
|
2595
2572
|
parent_at_end1: bool = True, collection_type: str = None,
|
2596
|
-
anchor_scope_guid: str = None,
|
2597
|
-
order_property_name: str = None, additional_properties: dict = None,
|
2573
|
+
anchor_scope_guid: str = None, additional_properties: dict = None,
|
2598
2574
|
extended_properties: dict = None) -> str:
|
2599
2575
|
""" Create a new collection with the NamingStandardRuleSet classification. This is used to group naming
|
2600
2576
|
standard rule
|
@@ -2606,6 +2582,8 @@ class CollectionManager(Client):
|
|
2606
2582
|
The display name of the element. Will also be used as the basis of the qualified_name.
|
2607
2583
|
description: str
|
2608
2584
|
A description of the collection.
|
2585
|
+
qualified_name: str, optional, defaults to None
|
2586
|
+
Allows user to specify a qualified name of the collection.
|
2609
2587
|
is_own_anchor: bool, optional, defaults to True
|
2610
2588
|
Indicates if the collection should be classified as its own anchor or not.
|
2611
2589
|
anchor_guid: str
|
@@ -2623,11 +2601,6 @@ class CollectionManager(Client):
|
|
2623
2601
|
Adds an user supplied valid value for the collection type.
|
2624
2602
|
anchor_scope_guid: str, optional, defaults to None
|
2625
2603
|
optional GUID of search scope
|
2626
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2627
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER", "DATE_CREATED",
|
2628
|
-
"OTHER"
|
2629
|
-
order_property_name: str, optional, defaults to "Something"
|
2630
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2631
2604
|
additional_properties: dict, optional, defaults to None
|
2632
2605
|
User specified Additional properties to add to the collection definition.
|
2633
2606
|
extended_properties: dict, optional, defaults to None
|
@@ -2650,11 +2623,10 @@ class CollectionManager(Client):
|
|
2650
2623
|
"""
|
2651
2624
|
loop = asyncio.get_event_loop()
|
2652
2625
|
resp = loop.run_until_complete(
|
2653
|
-
self._async_create_naming_standard_ruleset_collection(display_name, description,
|
2654
|
-
|
2655
|
-
|
2656
|
-
|
2657
|
-
additional_properties, extended_properties))
|
2626
|
+
self._async_create_naming_standard_ruleset_collection(display_name, description, qualified_name,
|
2627
|
+
is_own_anchor, anchor_guid, parent_guid,
|
2628
|
+
parent_relationship_type_name, parent_at_end1,
|
2629
|
+
collection_type, anchor_scope_guid))
|
2658
2630
|
return resp
|
2659
2631
|
|
2660
2632
|
#
|
@@ -2780,9 +2752,9 @@ class CollectionManager(Client):
|
|
2780
2752
|
#
|
2781
2753
|
async def _async_update_collection(self, collection_guid: str, qualified_name: str = None, display_name: str = None,
|
2782
2754
|
description: str = None, collection_type: str = None,
|
2783
|
-
|
2784
|
-
additional_properties: dict = None,
|
2785
|
-
|
2755
|
+
|
2756
|
+
additional_properties: dict = None, extended_properties: dict = None,
|
2757
|
+
replace_all_props: bool = False) -> None:
|
2786
2758
|
"""Update the properties of a collection. Async version.
|
2787
2759
|
|
2788
2760
|
Parameters
|
@@ -2797,11 +2769,6 @@ class CollectionManager(Client):
|
|
2797
2769
|
A description of the collection.
|
2798
2770
|
collection_type: str, optional, defaults to None
|
2799
2771
|
Add appropriate valid value for the collection type.
|
2800
|
-
collection_ordering: str, optional, defaults to None
|
2801
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER",
|
2802
|
-
"DATE_CREATED", "OTHER"
|
2803
|
-
order_property_name: str, optional, defaults to None
|
2804
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2805
2772
|
replace_all_props: bool, optional, defaults to False
|
2806
2773
|
Whether to replace all properties in the collection.
|
2807
2774
|
additional_properties: dict, optional, defaults to None
|
@@ -2831,17 +2798,16 @@ class CollectionManager(Client):
|
|
2831
2798
|
body = {
|
2832
2799
|
"class": "UpdateElementRequestBody", "properties": {
|
2833
2800
|
"class": "CollectionProperties", "qualifiedName": qualified_name, "name": display_name,
|
2834
|
-
"description": description, "collectionType": collection_type,
|
2835
|
-
"
|
2836
|
-
"extendedProperties": extended_properties
|
2801
|
+
"description": description, "collectionType": collection_type,
|
2802
|
+
"additionalProperties": additional_properties, "extendedProperties": extended_properties
|
2837
2803
|
}
|
2838
2804
|
}
|
2839
2805
|
body_s = body_slimmer(body)
|
2840
2806
|
await self._async_make_request("POST", url, body_s)
|
2841
2807
|
|
2842
2808
|
def update_collection(self, collection_guid, qualified_name: str = None, display_name: str = None,
|
2843
|
-
description: str = None, collection_type: str = None,
|
2844
|
-
|
2809
|
+
description: str = None, collection_type: str = None, additional_properties: dict = None,
|
2810
|
+
extended_properties: dict = None, replace_all_props: bool = False) -> None:
|
2845
2811
|
"""Update the properties of a collection.
|
2846
2812
|
|
2847
2813
|
Parameters
|
@@ -2856,11 +2822,6 @@ class CollectionManager(Client):
|
|
2856
2822
|
A description of the collection.
|
2857
2823
|
collection_type: str
|
2858
2824
|
Add appropriate valid value for the collection type.
|
2859
|
-
collection_ordering: str, optional, defaults to "OTHER"
|
2860
|
-
Specifies the sequencing to use in a collection. Examples include "NAME", "OWNER",
|
2861
|
-
"DATE_CREATED", "OTHER"
|
2862
|
-
order_property_name: str, optional, defaults to "Something"
|
2863
|
-
Property to use for sequencing if collection_ordering is "OTHER"
|
2864
2825
|
replace_all_props: bool, optional, defaults to False
|
2865
2826
|
Whether to replace all properties in the collection.
|
2866
2827
|
additional_properties: dict, optional, defaults to None
|
@@ -2885,11 +2846,11 @@ class CollectionManager(Client):
|
|
2885
2846
|
loop = asyncio.get_event_loop()
|
2886
2847
|
loop.run_until_complete(
|
2887
2848
|
self._async_update_collection(collection_guid, qualified_name, display_name, description, collection_type,
|
2888
|
-
collection_ordering, order_property_name,
|
2889
|
-
additional_properties, extended_properties, replace_all_props))
|
2890
2849
|
|
2850
|
+
additional_properties, extended_properties, replace_all_props))
|
2891
2851
|
|
2892
|
-
async def _async_update_collection_w_body(self, collection_guid: str, body: dict,
|
2852
|
+
async def _async_update_collection_w_body(self, collection_guid: str, body: dict,
|
2853
|
+
replace_all_props: bool = False) -> None:
|
2893
2854
|
"""Update the properties of a collection. Async version.
|
2894
2855
|
|
2895
2856
|
Parameters
|
@@ -2940,7 +2901,7 @@ class CollectionManager(Client):
|
|
2940
2901
|
body_s = body_slimmer(body)
|
2941
2902
|
await self._async_make_request("POST", url, body_s)
|
2942
2903
|
|
2943
|
-
def update_collection_w_body(self, collection_guid: str, body:dict, replace_all_props: bool=False) -> None:
|
2904
|
+
def update_collection_w_body(self, collection_guid: str, body: dict, replace_all_props: bool = False) -> None:
|
2944
2905
|
"""Update the properties of a collection.
|
2945
2906
|
|
2946
2907
|
Parameters
|
@@ -2986,15 +2947,16 @@ class CollectionManager(Client):
|
|
2986
2947
|
|
2987
2948
|
"""
|
2988
2949
|
loop = asyncio.get_event_loop()
|
2989
|
-
loop.run_until_complete(
|
2990
|
-
self._async_update_collection_w_body(collection_guid, body, replace_all_props))
|
2991
|
-
|
2950
|
+
loop.run_until_complete(self._async_update_collection_w_body(collection_guid, body, replace_all_props))
|
2992
2951
|
|
2993
2952
|
#
|
2994
2953
|
# Digital Products
|
2995
2954
|
#
|
2996
2955
|
async def _async_create_digital_product(self, body: dict) -> str:
|
2997
|
-
"""Create a new collection that represents a digital product.
|
2956
|
+
""" Create a new collection that represents a digital product. To set a lifecycle status
|
2957
|
+
use a NewDigitalProductRequestBody which has a default status of DRAFT. Using a
|
2958
|
+
NewElementRequestBody sets the status to ACTIVE.
|
2959
|
+
Async version.
|
2998
2960
|
|
2999
2961
|
Parameters
|
3000
2962
|
----------
|
@@ -3020,6 +2982,8 @@ class CollectionManager(Client):
|
|
3020
2982
|
be valid dates if specified, otherwise you will get a 400 error response.
|
3021
2983
|
|
3022
2984
|
JSON Structure looks like:
|
2985
|
+
|
2986
|
+
Without lifecycle status:
|
3023
2987
|
{
|
3024
2988
|
"class" : "NewElementRequestBody",
|
3025
2989
|
"anchorGUID" : "anchor GUID, if set then isOwnAnchor=false",
|
@@ -3102,64 +3066,111 @@ class CollectionManager(Client):
|
|
3102
3066
|
return resp.json().get("guid", "No GUID returned")
|
3103
3067
|
|
3104
3068
|
def create_digital_product(self, body: dict) -> str:
|
3105
|
-
"""Create a new collection that represents a digital product.
|
3106
|
-
|
3107
|
-
|
3108
|
-
|
3109
|
-
|
3110
|
-
|
3111
|
-
|
3112
|
-
|
3113
|
-
|
3114
|
-
|
3115
|
-
|
3116
|
-
|
3117
|
-
|
3118
|
-
|
3119
|
-
|
3120
|
-
|
3121
|
-
|
3122
|
-
|
3123
|
-
|
3069
|
+
""" Create a new collection that represents a digital product. To set a lifecycle status
|
3070
|
+
use a NewDigitalProductRequestBody which has a default status of DRAFT. Using a
|
3071
|
+
NewElementRequestBody sets the status to ACTIVE.
|
3072
|
+
|
3073
|
+
Parameters
|
3074
|
+
----------
|
3075
|
+
body: dict
|
3076
|
+
A dict representing the details of the collection to create.
|
3077
|
+
|
3078
|
+
Returns
|
3079
|
+
-------
|
3080
|
+
str - the guid of the created collection
|
3081
|
+
|
3082
|
+
Raises
|
3083
|
+
------
|
3084
|
+
InvalidParameterException
|
3085
|
+
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
3086
|
+
PropertyServerException
|
3087
|
+
Raised by the server when an issue arises in processing a valid request
|
3088
|
+
NotAuthorizedException
|
3089
|
+
The principle specified by the user_id does not have authorization for the requested action
|
3090
|
+
|
3091
|
+
Notes
|
3092
|
+
-----
|
3093
|
+
Note: the three dates: introductionDate, nextVersionDate and withdrawDate must
|
3094
|
+
be valid dates if specified, otherwise you will get a 400 error response.
|
3095
|
+
|
3096
|
+
JSON Structure looks like:
|
3097
|
+
|
3098
|
+
Without lifecycle status:
|
3099
|
+
{
|
3100
|
+
"class" : "NewElementRequestBody",
|
3101
|
+
"anchorGUID" : "anchor GUID, if set then isOwnAnchor=false",
|
3102
|
+
"isOwnAnchor" : false,
|
3103
|
+
"parentGUID" : "parent GUID, if set, set all parameters beginning 'parent'",
|
3104
|
+
"parentRelationshipTypeName" : "open metadata type name",
|
3105
|
+
"parentAtEnd1": true,
|
3106
|
+
"properties": {
|
3107
|
+
"class" : "CollectionProperties",
|
3108
|
+
"qualifiedName": "Must provide a unique name here",
|
3109
|
+
"name" : "Add display name here",
|
3110
|
+
"description" : "Add description of the collection here",
|
3111
|
+
"collectionType": "Add appropriate valid value for type",
|
3112
|
+
"collectionOrder" : "OTHER",
|
3113
|
+
"orderByPropertyName" : "Add property name if 'collectionOrder' is OTHER"
|
3114
|
+
},
|
3115
|
+
"digitalProductProperties" : {
|
3116
|
+
"class" : "DigitalProductProperties",
|
3117
|
+
"productStatus" : "ACTIVE",
|
3118
|
+
"productName" : "Add name here",
|
3119
|
+
"productType" : "Add valid value here",
|
3120
|
+
"description" : "Add description here",
|
3121
|
+
"introductionDate" : "date",
|
3122
|
+
"maturity" : "Add valid value here",
|
3123
|
+
"serviceLife" : "Add the estimated lifetime of the product",
|
3124
|
+
"currentVersion": "V1.0",
|
3125
|
+
"nextVersion": "V1.1",
|
3126
|
+
"withdrawDate": "date",
|
3127
|
+
"additionalProperties": {
|
3128
|
+
"property1Name" : "property1Value",
|
3129
|
+
"property2Name" : "property2Value"
|
3130
|
+
}
|
3131
|
+
}
|
3132
|
+
}
|
3124
3133
|
|
3125
|
-
|
3126
|
-
|
3127
|
-
|
3128
|
-
|
3129
|
-
|
3130
|
-
|
3131
|
-
|
3132
|
-
|
3133
|
-
|
3134
|
-
|
3135
|
-
|
3136
|
-
|
3137
|
-
|
3138
|
-
|
3139
|
-
|
3140
|
-
|
3141
|
-
|
3142
|
-
|
3143
|
-
|
3144
|
-
|
3145
|
-
|
3146
|
-
|
3147
|
-
|
3148
|
-
|
3149
|
-
|
3150
|
-
|
3151
|
-
|
3152
|
-
|
3153
|
-
|
3154
|
-
|
3155
|
-
|
3156
|
-
|
3157
|
-
|
3158
|
-
|
3159
|
-
|
3160
|
-
|
3161
|
-
|
3162
|
-
|
3134
|
+
With a lifecycle, the body is:
|
3135
|
+
{
|
3136
|
+
"class" : "NewDigitalProductRequestBody",
|
3137
|
+
"isOwnAnchor" : true,
|
3138
|
+
"anchorScopeGUID" : "optional GUID of search scope",
|
3139
|
+
"parentGUID" : "xxx",
|
3140
|
+
"parentRelationshipTypeName" : "CollectionMembership",
|
3141
|
+
"parentAtEnd1": true,
|
3142
|
+
"properties": {
|
3143
|
+
"class" : "DigitalProductProperties",
|
3144
|
+
"qualifiedName": "DigitalProduct:Add product name here",
|
3145
|
+
"userDefinedStatus" : "Optional value here - used when initial status is OTHER",
|
3146
|
+
"name" : "Product display name",
|
3147
|
+
"description" : "Add description of product and its expected usage here",
|
3148
|
+
"identifier" : "Add product identifier here",
|
3149
|
+
"productName" : "Add product name here",
|
3150
|
+
"productType" : "Periodic Delta",
|
3151
|
+
"maturity" : "Add valid value here",
|
3152
|
+
"serviceLife" : "Add the estimated lifetime of the product",
|
3153
|
+
"introductionDate" : "date",
|
3154
|
+
"nextVersionDate": "date",
|
3155
|
+
"withdrawDate": "date",
|
3156
|
+
"currentVersion": "V0.1",
|
3157
|
+
"additionalProperties": {
|
3158
|
+
"property1Name" : "property1Value",
|
3159
|
+
"property2Name" : "property2Value"
|
3160
|
+
}
|
3161
|
+
},
|
3162
|
+
"initialStatus" : "DRAFT",
|
3163
|
+
"externalSourceGUID": "add guid here",
|
3164
|
+
"externalSourceName": "add qualified name here",
|
3165
|
+
"effectiveTime" : "{{$isoTimestamp}}",
|
3166
|
+
"forLineage" : false,
|
3167
|
+
"forDuplicateProcessing" : false
|
3168
|
+
}
|
3169
|
+
|
3170
|
+
The valid values for initialStatus are: DRAFT, PREPARED, PROPOSED, APPROVED, REJECTED, APPROVED_CONCEPT,
|
3171
|
+
UNDER_DEVELOPMENT, DEVELOPMENT_COMPLETE, APPROVED_FOR_DEPLOYMENT, ACTIVE, DISABLED, DEPRECATED,
|
3172
|
+
OTHER. If using OTHER, set the userDefinedStatus with the status value you want.
|
3173
|
+
"""
|
3163
3174
|
loop = asyncio.get_event_loop()
|
3164
3175
|
resp = loop.run_until_complete(self._async_create_digital_product(body))
|
3165
3176
|
return resp
|
@@ -3219,7 +3230,6 @@ class CollectionManager(Client):
|
|
3219
3230
|
|
3220
3231
|
await self._async_make_request("POST", url, body)
|
3221
3232
|
|
3222
|
-
|
3223
3233
|
def update_digital_product(self, collection_guid: str, body: dict, replace_all_props: bool = False, ):
|
3224
3234
|
"""Update the properties of the DigitalProduct classification attached to a collection.
|
3225
3235
|
|
@@ -3270,7 +3280,6 @@ class CollectionManager(Client):
|
|
3270
3280
|
loop = asyncio.get_event_loop()
|
3271
3281
|
loop.run_until_complete(self._async_update_digital_product(collection_guid, body, replace_all_props))
|
3272
3282
|
|
3273
|
-
|
3274
3283
|
async def _async_update_digital_product_status(self, digital_prod_guid: str, body: dict):
|
3275
3284
|
"""Update the status of a DigitalProduct collection. Async version.
|
3276
3285
|
|
@@ -3308,12 +3317,13 @@ class CollectionManager(Client):
|
|
3308
3317
|
}
|
3309
3318
|
"""
|
3310
3319
|
|
3311
|
-
url = (
|
3312
|
-
|
3320
|
+
url = (
|
3321
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/digital"
|
3322
|
+
f"-products/"
|
3323
|
+
f"{digital_prod_guid}/update=status")
|
3313
3324
|
|
3314
3325
|
await self._async_make_request("POST", url, body)
|
3315
3326
|
|
3316
|
-
|
3317
3327
|
def update_digital_product_status(self, digital_prod_guid: str, body: dict):
|
3318
3328
|
"""Update the status of a DigitalProduct collection. Async version.
|
3319
3329
|
|
@@ -3354,8 +3364,6 @@ class CollectionManager(Client):
|
|
3354
3364
|
loop = asyncio.get_event_loop()
|
3355
3365
|
loop.run_until_complete(self._async_update_digital_product_status(digital_prod_guid, body))
|
3356
3366
|
|
3357
|
-
|
3358
|
-
|
3359
3367
|
async def _async_link_digital_product_dependency(self, upstream_digital_prod_guid: str,
|
3360
3368
|
downstream_digital_prod_guid: str, body: dict = None):
|
3361
3369
|
""" Link two dependent digital products. The linked elements are of type DigitalProduct.
|
@@ -3403,16 +3411,17 @@ class CollectionManager(Client):
|
|
3403
3411
|
}
|
3404
3412
|
"""
|
3405
3413
|
|
3406
|
-
|
3407
|
-
|
3408
|
-
|
3414
|
+
url = (
|
3415
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/digital"
|
3416
|
+
f"-products/"
|
3417
|
+
f"{upstream_digital_prod_guid}/product-dependencies/{downstream_digital_prod_guid}/attach")
|
3409
3418
|
if body:
|
3410
3419
|
await self._async_make_request("POST", url, body)
|
3411
3420
|
else:
|
3412
3421
|
await self._async_make_request("POST", url)
|
3413
3422
|
|
3414
|
-
|
3415
|
-
|
3423
|
+
def link_digital_product_dependency(self, upstream_digital_prod_guid: str, downstream_digital_prod_guid: str,
|
3424
|
+
body: dict = None):
|
3416
3425
|
""" Link two dependent digital products. The linked elements are of type DigitalProduct.
|
3417
3426
|
Request body is optional.
|
3418
3427
|
|
@@ -3461,7 +3470,6 @@ class CollectionManager(Client):
|
|
3461
3470
|
loop.run_until_complete(
|
3462
3471
|
self._async_link_digital_product_dependency(upstream_digital_prod_guid, downstream_digital_prod_guid, body))
|
3463
3472
|
|
3464
|
-
|
3465
3473
|
async def _async_detach_digital_product_dependency(self, upstream_digital_prod_guid: str,
|
3466
3474
|
downstream_digital_prod_guid: str, body: dict = None):
|
3467
3475
|
""" Unlink two dependent digital products. The linked elements are of type DigitalProduct.
|
@@ -3502,14 +3510,15 @@ class CollectionManager(Client):
|
|
3502
3510
|
}
|
3503
3511
|
"""
|
3504
3512
|
|
3505
|
-
url = (
|
3506
|
-
|
3513
|
+
url = (
|
3514
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/digital"
|
3515
|
+
f"-products/"
|
3516
|
+
f"{upstream_digital_prod_guid}/product-dependencies/{downstream_digital_prod_guid}/detach")
|
3507
3517
|
if body:
|
3508
3518
|
await self._async_make_request("POST", url, body)
|
3509
3519
|
else:
|
3510
3520
|
await self._async_make_request("POST", url)
|
3511
3521
|
|
3512
|
-
|
3513
3522
|
async def _async_link_product_manager(self, digital_prod_guid: str, digital_prod_manager_guid: str,
|
3514
3523
|
body: dict = None) -> None:
|
3515
3524
|
""" Attach a product manager to a digital product. Request body is optional.
|
@@ -3550,15 +3559,15 @@ class CollectionManager(Client):
|
|
3550
3559
|
}
|
3551
3560
|
"""
|
3552
3561
|
|
3553
|
-
|
3554
|
-
|
3555
|
-
|
3562
|
+
url = (
|
3563
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/digital"
|
3564
|
+
f"-products/"
|
3565
|
+
f"{digital_prod_guid}/product-managers/{digital_prod_manager_guid}/attach")
|
3556
3566
|
if body:
|
3557
3567
|
await self._async_make_request("POST", url, body)
|
3558
3568
|
else:
|
3559
3569
|
await self._async_make_request("POST", url)
|
3560
3570
|
|
3561
|
-
|
3562
3571
|
def link_product_manager(self, digital_prod_guid: str, digital_prod_manager_guid: str, body: dict = None):
|
3563
3572
|
""" Link a product manager to a digital product.
|
3564
3573
|
Request body is optional.
|
@@ -3598,11 +3607,10 @@ class CollectionManager(Client):
|
|
3598
3607
|
}
|
3599
3608
|
"""
|
3600
3609
|
loop = asyncio.get_event_loop()
|
3601
|
-
loop.run_until_complete(
|
3602
|
-
self._async_link_product_manager(digital_prod_guid, digital_prod_manager_guid, body))
|
3603
|
-
|
3610
|
+
loop.run_until_complete(self._async_link_product_manager(digital_prod_guid, digital_prod_manager_guid, body))
|
3604
3611
|
|
3605
|
-
async def _async_detach_product_manager(self, digital_prod_guid: str, digital_prod_manager_guid: str,
|
3612
|
+
async def _async_detach_product_manager(self, digital_prod_guid: str, digital_prod_manager_guid: str,
|
3613
|
+
body: dict = None):
|
3606
3614
|
""" Detach a product manager from a digital product. Request body is optional.
|
3607
3615
|
Async version.
|
3608
3616
|
|
@@ -3641,14 +3649,15 @@ class CollectionManager(Client):
|
|
3641
3649
|
}
|
3642
3650
|
"""
|
3643
3651
|
|
3644
|
-
url = (
|
3645
|
-
|
3652
|
+
url = (
|
3653
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/digital"
|
3654
|
+
f"-products/"
|
3655
|
+
f"{digital_prod_guid}/product-managers/{digital_prod_manager_guid}/detach")
|
3646
3656
|
if body:
|
3647
3657
|
await self._async_make_request("POST", url, body)
|
3648
3658
|
else:
|
3649
3659
|
await self._async_make_request("POST", url)
|
3650
3660
|
|
3651
|
-
|
3652
3661
|
def detach_product_manager(self, digital_prod_guid: str, digital_prod_manager_guid: str, body: dict = None):
|
3653
3662
|
""" Detach a product manager from a digital product. Request body is optional.
|
3654
3663
|
|
@@ -3687,9 +3696,7 @@ class CollectionManager(Client):
|
|
3687
3696
|
}
|
3688
3697
|
"""
|
3689
3698
|
loop = asyncio.get_event_loop()
|
3690
|
-
loop.run_until_complete(
|
3691
|
-
self._async_detach_product_manager(digital_prod_guid, digital_prod_manager_guid, body))
|
3692
|
-
|
3699
|
+
loop.run_until_complete(self._async_detach_product_manager(digital_prod_guid, digital_prod_manager_guid, body))
|
3693
3700
|
|
3694
3701
|
#
|
3695
3702
|
# Agreements
|
@@ -3775,7 +3782,8 @@ class CollectionManager(Client):
|
|
3775
3782
|
}
|
3776
3783
|
|
3777
3784
|
|
3778
|
-
The valid values for initialStatus are: DRAFT, PREPARED, PROPOSED, APPROVED, REJECTED, ACTIVE, DISABLED,
|
3785
|
+
The valid values for initialStatus are: DRAFT, PREPARED, PROPOSED, APPROVED, REJECTED, ACTIVE, DISABLED,
|
3786
|
+
DEPRECATED,
|
3779
3787
|
OTHER. If using OTHER, set the userDefinedStatus with the status value you want.
|
3780
3788
|
"""
|
3781
3789
|
|
@@ -3784,7 +3792,6 @@ class CollectionManager(Client):
|
|
3784
3792
|
resp = await self._async_make_request("POST", url, body_slimmer(body))
|
3785
3793
|
return resp.json().get("guid", "No GUID returned")
|
3786
3794
|
|
3787
|
-
|
3788
3795
|
def create_agreement(self, body: dict) -> str:
|
3789
3796
|
"""Create a new collection that represents am agreement. Async version.
|
3790
3797
|
|
@@ -3866,7 +3873,8 @@ class CollectionManager(Client):
|
|
3866
3873
|
}
|
3867
3874
|
|
3868
3875
|
|
3869
|
-
The valid values for initialStatus are: DRAFT, PREPARED, PROPOSED, APPROVED, REJECTED, ACTIVE, DISABLED,
|
3876
|
+
The valid values for initialStatus are: DRAFT, PREPARED, PROPOSED, APPROVED, REJECTED, ACTIVE, DISABLED,
|
3877
|
+
DEPRECATED,
|
3870
3878
|
OTHER. If using OTHER, set the userDefinedStatus with the status value you want.
|
3871
3879
|
"""
|
3872
3880
|
loop = asyncio.get_event_loop()
|
@@ -3930,12 +3938,12 @@ class CollectionManager(Client):
|
|
3930
3938
|
}
|
3931
3939
|
"""
|
3932
3940
|
|
3933
|
-
url = f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/data
|
3941
|
+
url = (f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections/data"
|
3942
|
+
f"-sharing-agreement")
|
3934
3943
|
|
3935
3944
|
resp = await self._async_make_request("POST", url, body_slimmer(body))
|
3936
3945
|
return resp.json().get("guid", "No GUID returned")
|
3937
3946
|
|
3938
|
-
|
3939
3947
|
def create_data_sharing_agreement(self, body: dict) -> str:
|
3940
3948
|
""" Create a new collection with the DataSharingAgreement classification. The collection is typically
|
3941
3949
|
an agreement which may use the NewElementRequestBody, or the NewAgreementRequestBody if the
|
@@ -3996,7 +4004,6 @@ class CollectionManager(Client):
|
|
3996
4004
|
resp = loop.run_until_complete(self._async_create_data_sharing_agreement(body))
|
3997
4005
|
return resp
|
3998
4006
|
|
3999
|
-
|
4000
4007
|
async def _async_update_agreement(self, agreement_guid: str, body: dict, replace_all_props: bool = False, ):
|
4001
4008
|
"""Update the properties of the agreement collection. Async version.
|
4002
4009
|
|
@@ -4055,7 +4062,6 @@ class CollectionManager(Client):
|
|
4055
4062
|
|
4056
4063
|
await self._async_make_request("POST", url, body)
|
4057
4064
|
|
4058
|
-
|
4059
4065
|
def update_agreement(self, agreement_guid: str, body: dict, replace_all_props: bool = False, ):
|
4060
4066
|
"""Update the properties of the DigitalProduct classification attached to a collection.
|
4061
4067
|
|
@@ -4110,7 +4116,6 @@ class CollectionManager(Client):
|
|
4110
4116
|
loop = asyncio.get_event_loop()
|
4111
4117
|
loop.run_until_complete(self._async_update_digital_product(agreement_guid, body, replace_all_props))
|
4112
4118
|
|
4113
|
-
|
4114
4119
|
async def _async_update_agreement_status(self, agreement_guid: str, body: dict):
|
4115
4120
|
"""Update the status of an agreement collection. Async version.
|
4116
4121
|
|
@@ -4148,12 +4153,13 @@ class CollectionManager(Client):
|
|
4148
4153
|
}
|
4149
4154
|
"""
|
4150
4155
|
|
4151
|
-
url = (
|
4152
|
-
|
4156
|
+
url = (
|
4157
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
4158
|
+
f"/agreements/"
|
4159
|
+
f"{agreement_guid}/update-status")
|
4153
4160
|
|
4154
4161
|
await self._async_make_request("POST", url, body)
|
4155
4162
|
|
4156
|
-
|
4157
4163
|
def update_agreement_status(self, agreement_guid: str, body: dict):
|
4158
4164
|
"""Update the status of an agreement collection. Async version.
|
4159
4165
|
|
@@ -4194,10 +4200,7 @@ class CollectionManager(Client):
|
|
4194
4200
|
loop = asyncio.get_event_loop()
|
4195
4201
|
loop.run_until_complete(self._async_update_agreement_status(agreement_guid, body))
|
4196
4202
|
|
4197
|
-
|
4198
|
-
|
4199
|
-
async def _async_link_agreement_actor(self, agreement_guid: str,
|
4200
|
-
actor_guid: str, body: dict = None):
|
4203
|
+
async def _async_link_agreement_actor(self, agreement_guid: str, actor_guid: str, body: dict = None):
|
4201
4204
|
""" Attach an actor to an agreement. The actor element may be an actor profile (person, team or IT profile);
|
4202
4205
|
actor role (person role, team role or IT profile role); or user identity. Request body is optional.
|
4203
4206
|
Async version.
|
@@ -4243,15 +4246,15 @@ class CollectionManager(Client):
|
|
4243
4246
|
}
|
4244
4247
|
"""
|
4245
4248
|
|
4246
|
-
|
4247
|
-
|
4248
|
-
|
4249
|
+
url = (
|
4250
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
4251
|
+
f"/agreements/"
|
4252
|
+
f"{agreement_guid}/agreement-actors/{actor_guid}/attach")
|
4249
4253
|
if body:
|
4250
4254
|
await self._async_make_request("POST", url, body)
|
4251
4255
|
else:
|
4252
4256
|
await self._async_make_request("POST", url)
|
4253
4257
|
|
4254
|
-
|
4255
4258
|
def link_agreement_actor(self, agreement_guid: str, actor_guid: str, body: dict = None):
|
4256
4259
|
""" Attach an actor to an agreement. The actor element may be an actor profile (person, team or IT profile);
|
4257
4260
|
actor role (person role, team role or IT profile role); or user identity. Request body is optional.
|
@@ -4298,12 +4301,9 @@ class CollectionManager(Client):
|
|
4298
4301
|
}
|
4299
4302
|
"""
|
4300
4303
|
loop = asyncio.get_event_loop()
|
4301
|
-
loop.run_until_complete(
|
4302
|
-
self._async_link_agreement_actor(agreement_guid, actor_guid, body))
|
4304
|
+
loop.run_until_complete(self._async_link_agreement_actor(agreement_guid, actor_guid, body))
|
4303
4305
|
|
4304
|
-
|
4305
|
-
async def _async_detach_agreement_actor(self, agreement_guid: str,
|
4306
|
-
actor_guid: str, body: dict = None):
|
4306
|
+
async def _async_detach_agreement_actor(self, agreement_guid: str, actor_guid: str, body: dict = None):
|
4307
4307
|
""" Unlink an actor from an agreement. Request body is optional. Async version.
|
4308
4308
|
|
4309
4309
|
Parameters
|
@@ -4341,14 +4341,15 @@ class CollectionManager(Client):
|
|
4341
4341
|
}
|
4342
4342
|
"""
|
4343
4343
|
|
4344
|
-
url = (
|
4345
|
-
|
4344
|
+
url = (
|
4345
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
4346
|
+
f"/agreements/"
|
4347
|
+
f"{agreement_guid}/agreement-actors/{actor_guid}/detach")
|
4346
4348
|
if body:
|
4347
4349
|
await self._async_make_request("POST", url, body)
|
4348
4350
|
else:
|
4349
4351
|
await self._async_make_request("POST", url)
|
4350
4352
|
|
4351
|
-
|
4352
4353
|
def detach_agreement_actor(self, agreement_guid: str, actor_guid: str, body: dict = None):
|
4353
4354
|
""" Unlink an actor from an agreement. Request body is optional.
|
4354
4355
|
|
@@ -4387,12 +4388,10 @@ class CollectionManager(Client):
|
|
4387
4388
|
}
|
4388
4389
|
"""
|
4389
4390
|
loop = asyncio.get_event_loop()
|
4390
|
-
loop.run_until_complete(
|
4391
|
-
self._async_detach_agreement_actor(agreement_guid, actor_guid, body))
|
4392
|
-
|
4393
|
-
|
4391
|
+
loop.run_until_complete(self._async_detach_agreement_actor(agreement_guid, actor_guid, body))
|
4394
4392
|
|
4395
|
-
async def _async_link_agreement_item(self, agreement_guid: str, agreement_item_guid: str,
|
4393
|
+
async def _async_link_agreement_item(self, agreement_guid: str, agreement_item_guid: str,
|
4394
|
+
body: dict = None) -> None:
|
4396
4395
|
""" Attach an agreement to an element referenced in its definition. The agreement item element is of type
|
4397
4396
|
'Referenceable' to allow the agreement to refer to many things. Request body is optional. Async version.
|
4398
4397
|
|
@@ -4460,9 +4459,7 @@ class CollectionManager(Client):
|
|
4460
4459
|
else:
|
4461
4460
|
await self._async_make_request("POST", url)
|
4462
4461
|
|
4463
|
-
|
4464
|
-
|
4465
|
-
def link_agreement_item(self, agreement_guid: str, agreement_item_guid: str, body: dict = None ) -> None:
|
4462
|
+
def link_agreement_item(self, agreement_guid: str, agreement_item_guid: str, body: dict = None) -> None:
|
4466
4463
|
""" Attach an agreement to an element referenced in its definition. The agreement item element is of type
|
4467
4464
|
'Referenceable' to allow the agreement to refer to many things. Request body is optional.
|
4468
4465
|
|
@@ -4522,11 +4519,10 @@ class CollectionManager(Client):
|
|
4522
4519
|
|
4523
4520
|
"""
|
4524
4521
|
loop = asyncio.get_event_loop()
|
4525
|
-
loop.run_until_complete(
|
4526
|
-
self._async_link_agreement_item(agreement_guid, agreement_item_guid, body ))
|
4527
|
-
|
4522
|
+
loop.run_until_complete(self._async_link_agreement_item(agreement_guid, agreement_item_guid, body))
|
4528
4523
|
|
4529
|
-
async def _async_detach_agreement_item(self, agreement_guid: str, agreement_item_guid: str,
|
4524
|
+
async def _async_detach_agreement_item(self, agreement_guid: str, agreement_item_guid: str,
|
4525
|
+
body: dict = None) -> None:
|
4530
4526
|
"""Detach an agreement item from an agreement. Request body is optional. Async version.
|
4531
4527
|
|
4532
4528
|
Parameters
|
@@ -4564,16 +4560,16 @@ class CollectionManager(Client):
|
|
4564
4560
|
|
4565
4561
|
"""
|
4566
4562
|
|
4567
|
-
url = (
|
4568
|
-
|
4563
|
+
url = (
|
4564
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
4565
|
+
f"/agreements"
|
4566
|
+
f"{agreement_guid}/agreement-items/{agreement_item_guid}/detach")
|
4569
4567
|
|
4570
4568
|
if body:
|
4571
4569
|
await self._async_make_request("POST", url, body)
|
4572
4570
|
else:
|
4573
4571
|
await self._async_make_request("POST", url)
|
4574
4572
|
|
4575
|
-
|
4576
|
-
|
4577
4573
|
def detach_agreement_item(self, agreement_guid: str, agreement_item_guid: str, body: dict = None) -> None:
|
4578
4574
|
"""Detach an agreement item from an agreement. Request body is optional. Async version.
|
4579
4575
|
|
@@ -4614,9 +4610,7 @@ class CollectionManager(Client):
|
|
4614
4610
|
loop = asyncio.get_event_loop()
|
4615
4611
|
loop.run_until_complete(self._async_detach_agreement_item(agreement_guid, agreement_item_guid, body))
|
4616
4612
|
|
4617
|
-
|
4618
|
-
async def _async_link_contract(self, agreement_guid: str, external_ref_guid: str,
|
4619
|
-
body: dict = None) -> None:
|
4613
|
+
async def _async_link_contract(self, agreement_guid: str, external_ref_guid: str, body: dict = None) -> None:
|
4620
4614
|
""" Attach an agreement to an external reference element that describes the location of the contract documents.
|
4621
4615
|
Request body is optional. Async version.
|
4622
4616
|
|
@@ -4673,8 +4667,6 @@ class CollectionManager(Client):
|
|
4673
4667
|
else:
|
4674
4668
|
await self._async_make_request("POST", url)
|
4675
4669
|
|
4676
|
-
|
4677
|
-
|
4678
4670
|
def link_contract(self, agreement_guid: str, external_ref_guid: str, body: dict = None) -> None:
|
4679
4671
|
""" Attach an agreement to an external reference element that describes the location of the contract documents.
|
4680
4672
|
Request body is optional.
|
@@ -4724,12 +4716,9 @@ class CollectionManager(Client):
|
|
4724
4716
|
|
4725
4717
|
"""
|
4726
4718
|
loop = asyncio.get_event_loop()
|
4727
|
-
loop.run_until_complete(
|
4728
|
-
self._async_link_contract(agreement_guid, external_ref_guid, body))
|
4729
|
-
|
4719
|
+
loop.run_until_complete(self._async_link_contract(agreement_guid, external_ref_guid, body))
|
4730
4720
|
|
4731
|
-
async def _async_detach_contract(self, agreement_guid: str, external_ref_guid: str,
|
4732
|
-
body: dict = None) -> None:
|
4721
|
+
async def _async_detach_contract(self, agreement_guid: str, external_ref_guid: str, body: dict = None) -> None:
|
4733
4722
|
"""Detach an external reference to a contract, from an agreement. Request body is optional. Async version.
|
4734
4723
|
|
4735
4724
|
Parameters
|
@@ -4768,7 +4757,8 @@ class CollectionManager(Client):
|
|
4768
4757
|
"""
|
4769
4758
|
|
4770
4759
|
url = (
|
4771
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections
|
4760
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
4761
|
+
f"/agreements"
|
4772
4762
|
f"{agreement_guid}/contract-links/{external_ref_guid}/detach")
|
4773
4763
|
|
4774
4764
|
if body:
|
@@ -4776,8 +4766,6 @@ class CollectionManager(Client):
|
|
4776
4766
|
else:
|
4777
4767
|
await self._async_make_request("POST", url)
|
4778
4768
|
|
4779
|
-
|
4780
|
-
|
4781
4769
|
def detach_contract(self, agreement_guid: str, external_ref_guid: str, body: dict = None) -> None:
|
4782
4770
|
"""Detach an external reference to a contract, from an agreement. Request body is optional.
|
4783
4771
|
|
@@ -4818,7 +4806,6 @@ class CollectionManager(Client):
|
|
4818
4806
|
loop = asyncio.get_event_loop()
|
4819
4807
|
loop.run_until_complete(self._async_detach_contract(agreement_guid, external_ref_guid, body))
|
4820
4808
|
|
4821
|
-
|
4822
4809
|
#
|
4823
4810
|
# Digital Subscriptions
|
4824
4811
|
#
|
@@ -4927,7 +4914,6 @@ class CollectionManager(Client):
|
|
4927
4914
|
resp = await self._async_make_request("POST", url, body_slimmer(body))
|
4928
4915
|
return resp.json().get("guid", "No GUID returned")
|
4929
4916
|
|
4930
|
-
|
4931
4917
|
def create_digital_subscription(self, body: dict) -> str:
|
4932
4918
|
"""Create a new collection that represents a type of agreement called a digital_subscription.
|
4933
4919
|
|
@@ -4999,8 +4985,8 @@ class CollectionManager(Client):
|
|
4999
4985
|
resp = loop.run_until_complete(self._async_create_digital_subscription(body))
|
5000
4986
|
return resp
|
5001
4987
|
|
5002
|
-
|
5003
|
-
|
4988
|
+
async def _async_update_digital_subscription(self, digital_subscription_guid: str, body: dict,
|
4989
|
+
replace_all_props: bool = False, ):
|
5004
4990
|
"""Update the properties of the digital_subscription collection. Async version.
|
5005
4991
|
|
5006
4992
|
Parameters
|
@@ -5062,8 +5048,8 @@ class CollectionManager(Client):
|
|
5062
5048
|
|
5063
5049
|
await self._async_make_request("POST", url, body)
|
5064
5050
|
|
5065
|
-
|
5066
|
-
|
5051
|
+
def update_digital_subscription(self, digital_subscription_guid: str, body: dict,
|
5052
|
+
replace_all_props: bool = False, ):
|
5067
5053
|
"""Update the properties of the DigitalProduct classification attached to a collection.
|
5068
5054
|
|
5069
5055
|
Parameters
|
@@ -5115,8 +5101,8 @@ class CollectionManager(Client):
|
|
5115
5101
|
|
5116
5102
|
"""
|
5117
5103
|
loop = asyncio.get_event_loop()
|
5118
|
-
loop.run_until_complete(
|
5119
|
-
|
5104
|
+
loop.run_until_complete(
|
5105
|
+
self._async_update_digital_subscription(digital_subscription_guid, body, replace_all_props))
|
5120
5106
|
|
5121
5107
|
async def _async_update_digital_subscription_status(self, digital_subscription_guid: str, body: dict):
|
5122
5108
|
"""Update the status of an digital_subscription collection. Async version.
|
@@ -5155,12 +5141,13 @@ class CollectionManager(Client):
|
|
5155
5141
|
}
|
5156
5142
|
"""
|
5157
5143
|
|
5158
|
-
url = (
|
5159
|
-
|
5144
|
+
url = (
|
5145
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
5146
|
+
f"/agreements/"
|
5147
|
+
f"{digital_subscription_guid}/update-status")
|
5160
5148
|
|
5161
5149
|
await self._async_make_request("POST", url, body)
|
5162
5150
|
|
5163
|
-
|
5164
5151
|
def update_digital_digital_subscription_status(self, digital_subscription_guid: str, body: dict):
|
5165
5152
|
"""Update the status of an digital_subscription collection. Async version.
|
5166
5153
|
|
@@ -5201,12 +5188,10 @@ class CollectionManager(Client):
|
|
5201
5188
|
loop = asyncio.get_event_loop()
|
5202
5189
|
loop.run_until_complete(self._async_update_digital_subscription_status(digital_subscription_guid, body))
|
5203
5190
|
|
5204
|
-
|
5205
|
-
|
5206
|
-
async def _async_link_subscriber(self, subscriber_guid: str,
|
5207
|
-
subscription_guid: str, body: dict = None):
|
5191
|
+
async def _async_link_subscriber(self, subscriber_guid: str, subscription_guid: str, body: dict = None):
|
5208
5192
|
""" Attach a subscriber to a subscription. The subscriber is of type 'Referenceable' to allow digital
|
5209
|
-
products, team or business capabilities to be the subscriber. The subscription is an element of type
|
5193
|
+
products, team or business capabilities to be the subscriber. The subscription is an element of type
|
5194
|
+
DigitalSubscription.
|
5210
5195
|
Async version.
|
5211
5196
|
|
5212
5197
|
Parameters
|
@@ -5250,18 +5235,19 @@ class CollectionManager(Client):
|
|
5250
5235
|
}
|
5251
5236
|
"""
|
5252
5237
|
|
5253
|
-
|
5254
|
-
|
5255
|
-
|
5238
|
+
url = (
|
5239
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
5240
|
+
f"/subscribers/"
|
5241
|
+
f"{subscriber_guid}/subscriptions/{subscription_guid}/attach")
|
5256
5242
|
if body:
|
5257
5243
|
await self._async_make_request("POST", url, body)
|
5258
5244
|
else:
|
5259
5245
|
await self._async_make_request("POST", url)
|
5260
5246
|
|
5261
|
-
|
5262
5247
|
def link_subscriber(self, subscriber_guid: str, subscription_guid: str, body: dict = None):
|
5263
5248
|
""" Attach a subscriber to a subscription. The subscriber is of type 'Referenceable' to allow digital
|
5264
|
-
products, team or business capabilities to be the subscriber. The subscription is an element of type
|
5249
|
+
products, team or business capabilities to be the subscriber. The subscription is an element of type
|
5250
|
+
DigitalSubscription.
|
5265
5251
|
Async version.
|
5266
5252
|
|
5267
5253
|
Parameters
|
@@ -5305,12 +5291,9 @@ class CollectionManager(Client):
|
|
5305
5291
|
}
|
5306
5292
|
"""
|
5307
5293
|
loop = asyncio.get_event_loop()
|
5308
|
-
loop.run_until_complete(
|
5309
|
-
self._async_link_subscriber(subscriber_guid, subscription_guid, body))
|
5310
|
-
|
5294
|
+
loop.run_until_complete(self._async_link_subscriber(subscriber_guid, subscription_guid, body))
|
5311
5295
|
|
5312
|
-
async def _async_detach_subscriber(self, subscriber_guid: str,
|
5313
|
-
subscription_guid: str, body: dict = None):
|
5296
|
+
async def _async_detach_subscriber(self, subscriber_guid: str, subscription_guid: str, body: dict = None):
|
5314
5297
|
""" Detach a subscriber from a subscription Request body is optional. Async version.
|
5315
5298
|
|
5316
5299
|
Parameters
|
@@ -5348,14 +5331,15 @@ class CollectionManager(Client):
|
|
5348
5331
|
}
|
5349
5332
|
"""
|
5350
5333
|
|
5351
|
-
url = (
|
5352
|
-
|
5334
|
+
url = (
|
5335
|
+
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/collections"
|
5336
|
+
f"/agreements/"
|
5337
|
+
f"{subscriber_guid}/agreement-actors/{subscription_guid}/detach")
|
5353
5338
|
if body:
|
5354
5339
|
await self._async_make_request("POST", url, body)
|
5355
5340
|
else:
|
5356
5341
|
await self._async_make_request("POST", url)
|
5357
5342
|
|
5358
|
-
|
5359
5343
|
def detach_subscriber(self, subscriber_guid: str, subscription_guid: str, body: dict = None):
|
5360
5344
|
""" Detach a subscriber from a subscription. Request body is optional.
|
5361
5345
|
|
@@ -5394,18 +5378,13 @@ class CollectionManager(Client):
|
|
5394
5378
|
}
|
5395
5379
|
"""
|
5396
5380
|
loop = asyncio.get_event_loop()
|
5397
|
-
loop.run_until_complete(
|
5398
|
-
self._async_detach_subscriber(subscriber_guid, subscription_guid, body))
|
5399
|
-
|
5400
|
-
|
5401
|
-
|
5381
|
+
loop.run_until_complete(self._async_detach_subscriber(subscriber_guid, subscription_guid, body))
|
5402
5382
|
|
5403
5383
|
#
|
5404
5384
|
#
|
5405
5385
|
#
|
5406
5386
|
|
5407
|
-
async def _async_attach_collection(self, parent_guid: str,
|
5408
|
-
collection_guid: str, body: dict = None):
|
5387
|
+
async def _async_attach_collection(self, parent_guid: str, collection_guid: str, body: dict = None, make_anchor: bool = False):
|
5409
5388
|
""" Connect an existing collection to an element using the ResourceList relationship (0019).
|
5410
5389
|
Async version.
|
5411
5390
|
|
@@ -5417,6 +5396,8 @@ class CollectionManager(Client):
|
|
5417
5396
|
The identifier of the collection being attached.
|
5418
5397
|
body: dict, optional, default = None
|
5419
5398
|
A dict representing the details of the relationship.
|
5399
|
+
make_anchor: bool, optional, default = False
|
5400
|
+
Indicates if the collection should be anchored to the element.
|
5420
5401
|
|
5421
5402
|
Returns
|
5422
5403
|
-------
|
@@ -5456,15 +5437,14 @@ class CollectionManager(Client):
|
|
5456
5437
|
|
5457
5438
|
"""
|
5458
5439
|
|
5459
|
-
|
5460
5440
|
url = (f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/collection-manager/metadata-elements/"
|
5461
|
-
f"{parent_guid}/collections/{collection_guid}/attach")
|
5441
|
+
f"{parent_guid}/collections/{collection_guid}/attach?makeAchor={make_anchor}")
|
5462
5442
|
if body:
|
5463
5443
|
await self._async_make_request("POST", url, body)
|
5464
5444
|
else:
|
5465
5445
|
await self._async_make_request("POST", url)
|
5466
5446
|
|
5467
|
-
def attach_collection(self, parent_guid: str, collection_guid: str, body: dict = None):
|
5447
|
+
def attach_collection(self, parent_guid: str, collection_guid: str, body: dict = None, make_anchor: bool = False):
|
5468
5448
|
""" Connect an existing collection to an element using the ResourceList relationship (0019).
|
5469
5449
|
|
5470
5450
|
Parameters
|
@@ -5475,6 +5455,8 @@ class CollectionManager(Client):
|
|
5475
5455
|
The identifier of the collection being attached.
|
5476
5456
|
body: dict, optional, default = None
|
5477
5457
|
A dict representing the details of the relationship.
|
5458
|
+
make_anchor: bool, optional, default = False
|
5459
|
+
Indicates if the collection should be anchored to the element.
|
5478
5460
|
|
5479
5461
|
Returns
|
5480
5462
|
-------
|
@@ -5513,11 +5495,9 @@ class CollectionManager(Client):
|
|
5513
5495
|
}
|
5514
5496
|
"""
|
5515
5497
|
loop = asyncio.get_event_loop()
|
5516
|
-
loop.run_until_complete(
|
5517
|
-
self._async_attach_collection(parent_guid, collection_guid, body))
|
5498
|
+
loop.run_until_complete(self._async_attach_collection(parent_guid, collection_guid, body, make_anchor))
|
5518
5499
|
|
5519
|
-
async def _async_detach_collection(self, parent_guid: str,
|
5520
|
-
collection_guid: str, body: dict = None):
|
5500
|
+
async def _async_detach_collection(self, parent_guid: str, collection_guid: str, body: dict = None):
|
5521
5501
|
""" Detach an existing collection from an element. If the collection is anchored to the element, it is delete.
|
5522
5502
|
Async version.
|
5523
5503
|
|
@@ -5530,6 +5510,7 @@ class CollectionManager(Client):
|
|
5530
5510
|
body: dict, optional, default = None
|
5531
5511
|
A dict representing the details of the relationship.
|
5532
5512
|
|
5513
|
+
|
5533
5514
|
Returns
|
5534
5515
|
-------
|
5535
5516
|
Nothing
|
@@ -5601,8 +5582,7 @@ class CollectionManager(Client):
|
|
5601
5582
|
}
|
5602
5583
|
"""
|
5603
5584
|
loop = asyncio.get_event_loop()
|
5604
|
-
loop.run_until_complete(
|
5605
|
-
self._async_detach_collection(parent_guid, collection_guid, body))
|
5585
|
+
loop.run_until_complete(self._async_detach_collection(parent_guid, collection_guid, body))
|
5606
5586
|
|
5607
5587
|
async def _async_delete_collection(self, collection_guid: str, body: dict = None, cascade: bool = False) -> None:
|
5608
5588
|
"""Delete a collection. It is detected from all parent elements. If members are anchored to the collection
|
@@ -5699,7 +5679,6 @@ class CollectionManager(Client):
|
|
5699
5679
|
loop = asyncio.get_event_loop()
|
5700
5680
|
loop.run_until_complete(self._async_delete_collection(collection_guid, body, cascade))
|
5701
5681
|
|
5702
|
-
|
5703
5682
|
async def _async_add_to_collection(self, collection_guid: str, element_guid: str, body: dict = None, ) -> None:
|
5704
5683
|
"""Add an element to a collection. The request body is optional. Async version.
|
5705
5684
|
|
@@ -5948,7 +5927,7 @@ class CollectionManager(Client):
|
|
5948
5927
|
loop.run_until_complete(
|
5949
5928
|
self._async_update_collection_membership(collection_guid, element_guid, body, replace_all_props))
|
5950
5929
|
|
5951
|
-
async def _async_remove_from_collection(self, collection_guid: str, element_guid: str, body:dict = None) -> None:
|
5930
|
+
async def _async_remove_from_collection(self, collection_guid: str, element_guid: str, body: dict = None) -> None:
|
5952
5931
|
"""Remove an element from a collection. Async version.
|
5953
5932
|
|
5954
5933
|
Parameters
|
@@ -5993,7 +5972,6 @@ class CollectionManager(Client):
|
|
5993
5972
|
body = {"class": "NullRequestBody"}
|
5994
5973
|
await self._async_make_request("POST", url, body)
|
5995
5974
|
|
5996
|
-
|
5997
5975
|
def remove_from_collection(self, collection_guid: str, element_guid: str, body: dict = None) -> None:
|
5998
5976
|
"""Remove an element from a collection. Async version.
|
5999
5977
|
|
@@ -6035,7 +6013,6 @@ class CollectionManager(Client):
|
|
6035
6013
|
loop = asyncio.get_event_loop()
|
6036
6014
|
loop.run_until_complete(self._async_remove_from_collection(collection_guid, element_guid, body))
|
6037
6015
|
|
6038
|
-
|
6039
6016
|
#
|
6040
6017
|
#
|
6041
6018
|
#
|
@@ -6141,6 +6118,7 @@ class CollectionManager(Client):
|
|
6141
6118
|
for classification in classifications:
|
6142
6119
|
classification_names += f"{classification['classificationName']}, "
|
6143
6120
|
classification_names = classification_names[:-2]
|
6121
|
+
mermaid = element.get('mermaidGraph', "") or ""
|
6144
6122
|
|
6145
6123
|
member_names = ""
|
6146
6124
|
members = self.get_member_list(collection_guid=guid)
|
@@ -6151,8 +6129,9 @@ class CollectionManager(Client):
|
|
6151
6129
|
|
6152
6130
|
return {
|
6153
6131
|
'GUID': guid, 'display_name': display_name, 'qualified_name': qualified_name, 'description': description,
|
6154
|
-
'classifications': classification_names, 'collection_type': collection_type, 'members': member_names,
|
6155
|
-
'
|
6132
|
+
'classifications': classification_names, 'collection_type': collection_type, 'members': member_names,
|
6133
|
+
'properties': properties, 'additional_properties': additional_properties,
|
6134
|
+
'extended_properties': extended_properties, 'mermaid': mermaid
|
6156
6135
|
}
|
6157
6136
|
|
6158
6137
|
def generate_basic_structured_output(self, elements, filter, output_format: str = 'DICT',
|
@@ -6163,7 +6142,7 @@ class CollectionManager(Client):
|
|
6163
6142
|
Args:
|
6164
6143
|
elements: Dictionary or list of dictionaries containing element data
|
6165
6144
|
filter: The search string used to find the elements
|
6166
|
-
output_format: The desired output format (MD, FORM, REPORT, LIST, DICT, MERMAID)
|
6145
|
+
output_format: The desired output format (MD, FORM, REPORT, LIST, DICT, MERMAID, HTML)
|
6167
6146
|
|
6168
6147
|
Returns:
|
6169
6148
|
Formatted output as string or list of dictionaries
|
@@ -6173,6 +6152,19 @@ class CollectionManager(Client):
|
|
6173
6152
|
return extract_mermaid_only(elements)
|
6174
6153
|
elif output_format == "DICT":
|
6175
6154
|
return extract_basic_dict(elements)
|
6155
|
+
elif output_format == "HTML":
|
6156
|
+
if collection_type is None:
|
6157
|
+
entity_type = "Collection"
|
6158
|
+
else:
|
6159
|
+
entity_type = collection_type
|
6160
|
+
|
6161
|
+
return generate_output(
|
6162
|
+
elements=elements,
|
6163
|
+
search_string=filter,
|
6164
|
+
entity_type=entity_type,
|
6165
|
+
output_format="HTML",
|
6166
|
+
extract_properties_func=self._extract_collection_properties
|
6167
|
+
)
|
6176
6168
|
|
6177
6169
|
# For other formats (MD, FORM, REPORT, LIST), use generate_output
|
6178
6170
|
elif output_format in ["MD", "FORM", "REPORT", "LIST"]:
|
@@ -6192,7 +6184,6 @@ class CollectionManager(Client):
|
|
6192
6184
|
extract_properties_func=self._extract_collection_properties,
|
6193
6185
|
columns=columns if output_format == 'LIST' else None)
|
6194
6186
|
|
6195
|
-
|
6196
6187
|
def generate_collection_output(self, elements, filter, classification_name, output_format) -> str | list:
|
6197
6188
|
"""
|
6198
6189
|
Generate output for collections in the specified format.
|
@@ -6202,7 +6193,7 @@ class CollectionManager(Client):
|
|
6202
6193
|
classification_name: str
|
6203
6194
|
The type of collection.
|
6204
6195
|
filter: The search string used to find the elements
|
6205
|
-
output_format: The desired output format (MD, FORM, REPORT, LIST, DICT, MERMAID)
|
6196
|
+
output_format: The desired output format (MD, FORM, REPORT, LIST, DICT, MERMAID, HTML)
|
6206
6197
|
|
6207
6198
|
Returns:
|
6208
6199
|
Formatted output as a string or list of dictionaries
|
@@ -6212,10 +6203,20 @@ class CollectionManager(Client):
|
|
6212
6203
|
else:
|
6213
6204
|
entity_type = classification_name
|
6214
6205
|
|
6215
|
-
if output_format
|
6206
|
+
if output_format == "HTML":
|
6207
|
+
return generate_output(
|
6208
|
+
elements=elements,
|
6209
|
+
search_string=filter,
|
6210
|
+
entity_type=entity_type,
|
6211
|
+
output_format="HTML",
|
6212
|
+
extract_properties_func=self._extract_collection_properties
|
6213
|
+
)
|
6214
|
+
|
6215
|
+
elif output_format in ["MD", "FORM", "REPORT", "LIST", "DICT", "MERMAID"]:
|
6216
6216
|
# Define columns for LIST format
|
6217
6217
|
columns = [{'name': 'Name', 'key': 'display_name'},
|
6218
6218
|
{'name': 'Qualified Name', 'key': 'qualified_name', 'format': True},
|
6219
|
+
{'name': 'Collection Type', 'key': 'collection_type'},
|
6219
6220
|
{'name': 'Description', 'key': 'description', 'format': True},
|
6220
6221
|
{'name': "Classifications", 'key': 'classifications'},
|
6221
6222
|
{'name': 'Members', 'key': 'members', 'format': True}, ]
|
@@ -6227,49 +6228,6 @@ class CollectionManager(Client):
|
|
6227
6228
|
else:
|
6228
6229
|
return self.generate_basic_structured_output(elements, filter, output_format)
|
6229
6230
|
|
6230
|
-
# def generate_collection_output(self, elements, filter, collection_type: str, output_format,
|
6231
|
-
# # output_profile: str = "CORE") -> str | list | dict: # """ # Generate output in the specified
|
6232
|
-
# format # for the given elements. # # Args: # elements: Dictionary or list of dictionaries
|
6233
|
-
# containing # element data # filter: The search string used to find the elements #
|
6234
|
-
# output_format: The # desired output format (MD, FORM, REPORT, LIST, DICT, MERMAID, JSON) #
|
6235
|
-
# output_profile: str, optional, # default = "CORE" # The desired output profile - BASIC, CORE,
|
6236
|
-
# FULL # Returns: # # Formatted output as string or list of dictionaries # """ # if
|
6237
|
-
# collection_type is None: # # entity_type = "Collection" # else: # entity_type =
|
6238
|
-
# collection_type # # # For LIST and DICT # formats, get member information # # if output_format in
|
6239
|
-
# ["LIST", "DICT"]: # # Get the collection # GUID # collection_guid = None # if
|
6240
|
-
# isinstance(elements, dict): # collection_guid # = elements.get('elementHeader', {}).get('guid')
|
6241
|
-
# elif isinstance(elements, list) and len(elements) > # 0: # collection_guid = elements[
|
6242
|
-
# 0].get('elementHeader', {}).get('guid') # # # Get member # list if we have a valid
|
6243
|
-
# collection GUID # members = [] # if collection_guid: # # members =
|
6244
|
-
# self.get_member_list(collection_guid=collection_guid) # if isinstance(members,
|
6245
|
-
# str): # "No members found" case # members = [] # # # For DICT format, include all
|
6246
|
-
# member information in the result # if output_format == "DICT": # result = #
|
6247
|
-
# self.generate_basic_structured_output(elements, filter, output_format, collection_type) # if #
|
6248
|
-
# isinstance(result, list): # for item in result: # item['members'] = #
|
6249
|
-
# members # return result # elif isinstance(result, dict): # # result['members']
|
6250
|
-
# = members # return result # # # For LIST format, add a column with # bulleted list
|
6251
|
-
# of qualified names # elif output_format == "LIST": # # Define columns for # LIST format,
|
6252
|
-
# including the new Members column # columns = [{'name': 'Collection Name',
|
6253
|
-
# 'key': 'display_name'}, # {'name': 'Qualified Name', 'key': 'qualified_name'}, # # {'name':
|
6254
|
-
# 'Collection Type', 'key': 'collection_type'}, # {'name': 'Description',
|
6255
|
-
# 'key': 'description', 'format': True}, # {'name': 'Classifications',
|
6256
|
-
# 'key': 'classifications'}, # {'name': 'Members', 'key': 'members', 'format': True}] # # #
|
6257
|
-
# Create a function to add member information to the properties # def get_additional_props(element,
|
6258
|
-
# guid, output_format): # if not members: # return {'members': ''} # # #
|
6259
|
-
# Create a comma-separated list of qualified names (no newlines to avoid table formatting issues) # #
|
6260
|
-
# member_list = ", ".join([member.get('qualifiedName', '') for member in members]) # return { #
|
6261
|
-
# 'members': member_list} # # # Generate output with the additional properties # # # return
|
6262
|
-
# generate_output(elements=elements, search_string=filter, entity_type=entity_type,
|
6263
|
-
# # output_format=output_format, extract_properties_func=self._extract_collection_properties,
|
6264
|
-
# # get_additional_props_func=get_additional_props, columns=columns) # # # For FORM, REPORT, JSON formats,
|
6265
|
-
# keep behavior unchanged # return self.generate_basic_structured_output(elements, filter, output_format,
|
6266
|
-
# collection_type)
|
6267
|
-
|
6268
|
-
# def generate_data_class_output(self, elements, filter, output_format) -> str | list: # return # #
|
6269
|
-
# self.generate_basic_structured_output(elements, filter, output_format) # # def generate_data_field_output( #
|
6270
|
-
# self, elements, filter, output_format) -> str | list: # return self.generate_basic_structured_output( #
|
6271
|
-
# elements, filter, output_format)
|
6272
|
-
|
6273
6231
|
|
6274
6232
|
if __name__ == "__main__":
|
6275
6233
|
print("Main-Collection Manager")
|