#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
import gi
gi.require_version('RwYang', '1.0')
gi.require_version('RwVnfdYang', '1.0')
gi.require_version('VnfdYang', '1.0')
import gi
gi.require_version('RwYang', '1.0')
gi.require_version('RwVnfdYang', '1.0')
gi.require_version('VnfdYang', '1.0')
internal_cp.name = cp_name + "/icp{}".format(i)
internal_cp.id = cp_name + "/icp{}".format(i)
internal_cp.type_yang = 'VPORT'
internal_cp.name = cp_name + "/icp{}".format(i)
internal_cp.id = cp_name + "/icp{}".format(i)
internal_cp.type_yang = 'VPORT'
group_desc.min_instance_count = scale_group.min_count
for vnfd, count in scale_group.vnfd_count_map.items():
member = group_desc.vnfd_member.add()
group_desc.min_instance_count = scale_group.min_count
for vnfd, count in scale_group.vnfd_count_map.items():
member = group_desc.vnfd_member.add()
member.vnfd_id_ref = member_vnfd.descriptor.vnfd[0].id
member.member_vnf_index_ref = vnfd_index_map[member_vnfd]
member.vnfd_id_ref = member_vnfd.descriptor.vnfd[0].id
member.member_vnf_index_ref = vnfd_index_map[member_vnfd]