64 class(InterfaceMapType) :: this
65 class(InterfaceMapType) :: map_to_add
67 integer(I4B) :: im, ie
68 integer(I4B) :: m_id, m_index
69 integer(I4B) :: e_id, e_index
72 do im = 1, map_to_add%nr_models
73 m_id = map_to_add%model_ids(im)
74 m_index = ifind(this%model_ids, m_id)
77 call this%node_maps(m_index)%add(map_to_add%node_maps(im))
78 call this%conn_maps(m_index)%add(map_to_add%conn_maps(im))
81 m_index = ifind(this%model_ids, -1)
82 this%model_ids(m_index) = m_id
83 this%model_names(m_index) = map_to_add%model_names(im)
84 call this%node_maps(m_index)%copy(map_to_add%node_maps(im))
85 call this%conn_maps(m_index)%copy(map_to_add%conn_maps(im))
90 do ie = 1, map_to_add%nr_exchanges
91 e_id = map_to_add%exchange_ids(ie)
92 e_index = ifind(this%exchange_ids, e_id)
95 call this%exchange_maps(e_index)%add(map_to_add%exchange_maps(ie))
98 e_index = ifind(this%exchange_ids, -1)
99 this%exchange_ids(e_index) = e_id
100 this%exchange_names(e_index) = map_to_add%exchange_names(ie)
101 call this%exchange_maps(e_index)%copy(map_to_add%exchange_maps(ie))