1 from sdcBePy.tosca.models.normativeElementCandidate import NormativeElementCandidate
4 def get_normative_element_candidate_list(base_file_location):
6 get_data(base_file_location),
7 get_capability(base_file_location),
8 get_relationship(base_file_location),
9 get_interface_lifecycle(base_file_location),
10 get_categories(base_file_location)
14 def get_normative_element_with_metadata_list(base_file_location):
16 get_group(base_file_location),
17 get_policy(base_file_location)
21 def get_data(base_file_location="/"):
22 return NormativeElementCandidate(base_file_location + "data-types/",
23 "/sdc2/rest/v1/catalog/uploadType/datatypes",
28 def get_capability(base_file_location="/"):
29 return NormativeElementCandidate(base_file_location + "capability-types/",
30 "/sdc2/rest/v1/catalog/uploadType/capability",
35 def get_relationship(base_file_location="/"):
36 return NormativeElementCandidate(base_file_location + "relationship-types/",
37 "/sdc2/rest/v1/catalog/uploadType/relationship",
39 "relationshipTypeZip")
42 def get_interface_lifecycle(base_file_location="../../../import/tosca/"):
43 return NormativeElementCandidate(base_file_location + "interface-lifecycle-types/",
44 "/sdc2/rest/v1/catalog/uploadType/interfaceLifecycle",
45 "interfaceLifecycleTypes",
46 "interfaceLifecycleTypeZip")
49 def get_categories(base_file_location="/"):
50 return NormativeElementCandidate(base_file_location + "categories/",
51 "/sdc2/rest/v1/catalog/uploadType/categories",
56 def get_group(base_file_location="/"):
57 return NormativeElementCandidate(base_file_location + "group-types/",
58 "/sdc2/rest/v1/catalog/uploadType/grouptypes",
64 def get_policy(base_file_location="/"):
65 return NormativeElementCandidate(base_file_location + "policy-types/",
66 "/sdc2/rest/v1/catalog/uploadType/policytypes",
72 def get_annotation(base_file_location="/"):
73 return NormativeElementCandidate(base_file_location + "annotation-types",
74 "/sdc2/rest/v1/catalog/uploadType/annotationtypes",