SheafSystem  0.0.0.0
explicit_index_space_interval.cc
Go to the documentation of this file.
1 
2 //
3 // Copyright (c) 2014 Limit Point Systems, Inc.
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 
20 
21 #include "SheafSystem/explicit_index_space_interval.h"
22 
23 #include "SheafSystem/abstract_product_structure.h"
24 #include "SheafSystem/assert_contract.h"
25 #include "SheafSystem/explicit_index_space_state.h"
26 #include "SheafSystem/hub_index_space_handle.h"
27 #include "SheafSystem/index_space_family.h"
28 #include "SheafSystem/index_space_iterator.h"
29 
30 // ===========================================================
31 // SPACE FACTORY FACET
32 // ===========================================================
33 
34 // PUBLIC MEMBER FUNCTIONS
35 
39  size_type xub)
40 {
41  // Preconditions:
42 
43  require(xub > 0);
44 
45  // Body:
46 
47  define_old_variable(size_type old_id_spaces_end = xid_spaces.end());
48 
50  result_ptr->new_state(xid_spaces, xub);
51 
52  result_ptr->_states.reserve(xub);
53 
54  const explicit_index_space_interval& result = *result_ptr;
55 
56  // Postconditions:
57 
58  ensure(&result.id_spaces() == &xid_spaces);
59  ensure(result.begin() == old_id_spaces_end);
60  ensure(result.end() == xid_spaces.end());
61  ensure(result.end() == result.begin() + xub);
62 
63  // Exit:
64 
65  return result;
66 }
67 
68 // PROTECTED MEMBER FUNCTIONS
69 
70 // PRIVATE MEMBER FUNCTIONS
71 
72 
73 // ===========================================================
74 // EXPLICIT_INDEX_SPACE_INTERVAL FACET
75 // ===========================================================
76 
77 // PUBLIC MEMBER FUNCTIONS
78 
81 {
82  // Preconditions:
83 
84  // Body:
85 
86  // Delete the explicit states.
87 
88  for(pod_type i = 0; i < _states.ub(); ++i)
89  {
90  if(_states[i] != 0)
91  {
92  delete _states[i];
93  }
94  }
95 
96  // Postconditions:
97 
98  // Exit:
99 
100  return;
101 }
102 
103 void
106 {
107  // Preconditions:
108 
109  require(!contains(local_scope(xid_space.index())));
110  require(in_bounds(xid_space.index()));
111 
112  // Body:
113 
114  _states.set_item(xid_space.index() - _begin, &xid_space);
115 
116  // Postconditions:
117 
118  ensure(contains(local_scope(xid_space.index())));
119 
120  // Exit:
121 
122  return;
123 }
124 
125 // PROTECTED MEMBER FUNCTIONS
126 
130 {
131  // Preconditions:
132 
133  // Body:
134 
135  // Postconditions:
136 
137  ensure(invariant());
138 
139  // Exit:
140 
141  return;
142 }
143 
144 // PRIVATE MEMBER FUNCTIONS
145 
146 
147 // ===========================================================
148 // INDEX_SPACE_INTERVAL FACET
149 // ===========================================================
150 
151 // PUBLIC MEMBER FUNCTIONS
152 
153 // PROTECTED MEMBER FUNCTIONS
154 
155 bool
158 {
159  // Preconditions:
160 
161  // Body:
162 
163  // Postconditions:
164 
165  ensure(is_basic_query);
166 
167  // Exit:
168 
169  return true;
170 }
171 
172 // PRIVATE MEMBER FUNCTIONS
173 
174 
175 // ===========================================================
176 // FACTORY FACET
177 // ===========================================================
178 
179 // PUBLIC MEMBER FUNCTIONS
180 
181 const std::string&
183 class_name() const
184 {
185  static const std::string result("explicit_index_space_interval");
186  return result;
187 }
188 
191 clone() const
192 {
193  // Preconditions:
194 
195  // Body:
196 
199 
200  // Postconditions:
201 
202  ensure(result != 0);
203  ensure(is_same_type(result));
204 
205  // Exit:
206 
207  return result;
208 }
209 
210 // PROTECTED MEMBER FUNCTIONS
211 
212 // PRIVATE MEMBER FUNCTIONS
213 
214 bool
215 sheaf::explicit_index_space_interval::
216 make_prototype()
217 {
218  // Preconditions:
219 
220  // Body:
221 
223 
224  id_space_interval_factory().insert_prototype(lproto);
225 
226  // Postconditions:
227 
228  // Exit:
229 
230  return true;
231 }
232 
233 
234 // ===========================================================
235 // INDEX_SPACE_COLLECTION FACET
236 // ===========================================================
237 
238 // PUBLIC MEMBER FUNCTIONS
239 
240 bool
242 operator==(const index_space_collection& xother) const
243 {
244  // Preconditions:
245 
246  require(is_ancestor_of(&xother));
247 
248  // Body:
249 
250  const explicit_index_space_interval& lother =
251  dynamic_cast<const explicit_index_space_interval&>(xother);
252 
253  bool result = index_space_interval::operator==(xother);
254 
255  result = result && (_states == lother._states);
256 
257  // Postconditions:
258 
259  // Exit
260 
261  return result;
262 }
263 
264 bool
266 contains(pod_type xlocal_id) const
267 {
268  // Preconditions:
269 
270  // Body:
271 
272  pod_type lspace_id = xlocal_id + _begin;
273 
274  bool result =
275  (_begin <= lspace_id) &&
276  (lspace_id < _end) &&
277  (_states[xlocal_id] != 0);
278 
279  // Postconditions:
280 
281  ensure(is_basic_query);
282 
283  // Exit:
284 
285  return result;
286 }
287 
288 bool
290 contains_family(pod_type xspace_id) const
291 {
292  // Preconditions:
293 
294  // Body:
295 
296  bool result =
297  (_begin <= xspace_id) &&
298  (xspace_id < _end) &&
299  (_states[xspace_id - _begin] != 0);
300 
301  // Postconditions:
302 
303  ensure(is_basic_query);
304 
305  // Exit:
306 
307  return result;
308 }
309 
312 deep_size(bool xinclude_shallow) const
313 {
314  // Preconditions:
315 
316  // Body:
317 
318  size_type result = sheaf::deep_size(*this, xinclude_shallow);
319 
320  // Postconditions:
321 
322  ensure(result >= 0);
323 
324  // Exit:
325 
326  return result;
327 }
328 
329 // PROTECTED MEMBER FUNCTIONS
330 
334 {
335  // Preconditions:
336 
337  require(is_ancestor_of(&xother));
338 
339  // Body:
340 
341  const explicit_index_space_interval& lother =
342  dynamic_cast<const explicit_index_space_interval&>(xother);
343 
344  _states = lother._states;
345 
347 
348  // Postconditions:
349 
350  ensure(invariant());
351  ensure((*this) == xother);
352 
353  // Exit:
354 
355  return *this;
356 }
357 
360 explicit_state(pod_type xlocal_id) const
361 {
362  // Preconditions:
363 
364  // Body:
365 
367  contains(xlocal_id) ? _states[xlocal_id] : 0;
368 
369  // Postconditions:
370 
371  ensure(is_basic_query);
372 
373  // Exit:
374 
375  return result;
376 }
377 
378 // PRIVATE MEMBER FUNCTIONS
379 
380 
381 // ===========================================================
382 // INDEX SPACE FACET
383 // ===========================================================
384 
385 // PUBLIC MEMBER FUNCTIONS
386 
387 void
389 remove(pod_type xlocal_id)
390 {
391  // Preconditions:
392 
393  // Body:
394 
395  _states[xlocal_id] = 0;
396 
397  // Postconditions:
398 
399  ensure(!contains(xlocal_id));
400 
401  // Exit:
402 
403  return;
404 }
405 
408 ct(pod_type xlocal_id) const
409 {
410  // Preconditions:
411 
412  require(contains(xlocal_id));
413 
414  // Body:
415 
416  size_type result = _states[xlocal_id]->ct();
417 
418  // Postconditions:
419 
420  ensure(is_basic_query);
421 
422  // Exit:
423 
424  return result;
425 }
426 
429 begin(pod_type xlocal_id) const
430 {
431  // Preconditions:
432 
433  require(contains(xlocal_id));
434 
435  // Body:
436 
437  pod_type result = _states[xlocal_id]->begin();
438 
439  // Postconditions:
440 
441  ensure(is_basic_query);
442 
443  // Exit:
444 
445  return result;
446 }
447 
450 end(pod_type xlocal_id) const
451 {
452  // Preconditions:
453 
454  require(contains(xlocal_id));
455 
456  // Body:
457 
458  pod_type result = _states[xlocal_id]->end();
459 
460  // Postconditions:
461 
462  ensure(is_basic_query);
463 
464  // Exit:
465 
466  return result;
467 }
468 
469 bool
471 contains(pod_type xlocal_id, pod_type xid) const
472 {
473  // Preconditions:
474 
475  require(contains(xlocal_id));
476 
477  // Body:
478 
479  bool result = _states[xlocal_id]->contains(xid);
480 
481  // Postconditions:
482 
483  ensure(is_basic_query);
484 
485  // Exit:
486 
487  return result;
488 }
489 
490 bool
493 {
494  // Preconditions:
495 
496  require(contains(xlocal_id));
497 
498  // Body:
499 
500  bool result = _states[xlocal_id]->contains_unglued_hub(xid);
501 
502  // Postconditions:
503 
504  ensure(is_basic_query);
505 
506  // Exit:
507 
508  return result;
509 }
510 
511 bool
513 contains(pod_type xlocal_id, pod_type xid, pod_type xhub_id) const
514 {
515  // Preconditions:
516 
517  require(contains(xlocal_id));
518 
519  // Body:
520 
521  bool result = _states[xlocal_id]->contains(xid, xhub_id);
522 
523  // Postconditions:
524 
525  ensure(is_basic_query);
526 
527  // Exit:
528 
529  return result;
530 }
531 
534 pod(pod_type xlocal_id, pod_type xid) const
535 {
536  // Preconditions:
537 
538  require(contains(xlocal_id));
539 
540  // Body:
541 
542  pod_type result = _states[xlocal_id]->pod(xid);
543 
544  // Postconditions:
545 
546  ensure(!is_valid(result) || contains(xlocal_id, result));
547 
548  // Exit:
549 
550  return result;
551 }
552 
555 unglued_hub_pod(pod_type xlocal_id, pod_type xid) const
556 {
557  // Preconditions:
558 
559  require(contains(xlocal_id));
560 
561  // Body:
562 
563  pod_type result = _states[xlocal_id]->unglued_hub_pod(xid);
564 
565  // Postconditions:
566 
567  ensure(!is_valid(result) || contains_unglued_hub(xlocal_id, result));
568 
569  // Exit:
570 
571  return result;
572 }
573 
574 bool
576 is_persistent(pod_type xlocal_id) const
577 {
578  // Preconditions:
579 
580  require(contains(xlocal_id));
581 
582  // Body:
583 
584  bool result = _states[xlocal_id]->is_persistent();
585 
586  // Postconditions:
587 
588  ensure(is_basic_query);
589 
590  // Exit:
591 
592  return result;
593 }
594 
595 // PROTECTED MEMBER FUNCTIONS
596 
597 // PRIVATE MEMBER FUNCTIONS
598 
599 
600 // ===========================================================
601 // PRODUCT STRUCTURE FACET
602 // ===========================================================
603 
604 // PUBLIC MEMBER FUNCTIONS
605 
606 void
609  const abstract_product_structure& xproduct)
610 {
611  // Preconditions:
612 
613  require(contains(xlocal_id));
614 
615  // Body:
616 
617  _states[xlocal_id]->new_product_structure(xproduct);
618 
619  // Postconditions:
620 
621  ensure(has_product_structure(xlocal_id));
622 
623  // Exit:
624 
625  return;
626 }
627 
628 void
631 {
632  // Preconditions:
633 
634  require(contains(xlocal_id));
635 
636  // Body:
637 
638  _states[xlocal_id]->delete_product_structure();
639 
640  // Postconditions:
641 
642  ensure(!has_product_structure(xlocal_id));
643 
644  // Exit:
645 
646  return;
647 }
648 
651 product_structure(pod_type xlocal_id) const
652 {
653  // Preconditions:
654 
655  require(contains(xlocal_id));
656  require(has_product_structure(xlocal_id));
657 
658  // Body:
659 
660  const abstract_product_structure& result =
661  _states[xlocal_id]->product_structure();
662 
663  // Postconditions:
664 
665  ensure(is_basic_query);
666 
667  // Exit:
668 
669  return result;
670 }
671 
675 {
676  // Preconditions:
677 
678  require(contains(xlocal_id));
679  require(has_product_structure(xlocal_id));
680 
681  // Body:
682 
683  abstract_product_structure& result =
684  _states[xlocal_id]->product_structure();
685 
686  // Postconditions:
687 
688  ensure(is_basic_query);
689 
690  // Exit:
691 
692  return result;
693 }
694 
695 bool
698 {
699  // Preconditions:
700 
701  require(contains(xlocal_id));
702 
703  // Body:
704 
705  bool result = _states[xlocal_id]->has_product_structure();
706 
707  // Postconditions:
708 
709  ensure(is_basic_query);
710 
711  // Exit:
712 
713  return result;
714 }
715 
716 // PROTECTED MEMBER FUNCTIONS
717 
718 // PRIVATE MEMBER FUNCTIONS
719 
720 
721 // ===========================================================
722 // HANDLE POOL FACET
723 // ===========================================================
724 
725 // PUBLIC MEMBER FUNCTIONS
726 
729 get_id_space(pod_type xlocal_id) const
730 {
731  // Preconditions:
732 
733  require(contains(xlocal_id));
734 
735  // Body:
736 
737  index_space_handle& result = _states[xlocal_id]->get_id_space();
738 
739  // Postconditions:
740 
741  ensure(result.is_attached());
742 
743  // Exit:
744 
745  return result;
746 }
747 
748 void
751 {
752  // Preconditions:
753 
754  require(allocated_id_space(xid_space));
755 
756  // Body:
757 
758  _states[local_scope(xid_space.index())]->release_id_space(xid_space);
759 
760  // Postconditions:
761 
762  ensure(is_basic_query);
763 
764  // Exit:
765 
766  return;
767 }
768 
769 bool
771 allocated_id_space(const index_space_handle& xid_space) const
772 {
773  // Preconditions:
774 
775  // Body:
776 
777  pod_type local_id = local_scope(xid_space.index());
778 
779  bool result =
780  contains(local_id) && _states[local_id]->allocated_id_space(xid_space);
781 
782  // Postconditions:
783 
784  ensure(is_basic_query);
785 
786  // Exit:
787 
788  return result;
789 }
790 
791 // PROTECTED MEMBER FUNCTIONS
792 
793 // PRIVATE MEMBER FUNCTIONS
794 
795 
796 // ===========================================================
797 // ITERATOR POOL FACET
798 // ===========================================================
799 
800 // PUBLIC MEMBER FUNCTIONS
801 
805 {
806  // Preconditions:
807 
808  require(contains(xlocal_id));
809 
810  // Body:
811 
812  index_space_iterator& result = _states[xlocal_id]->get_iterator();
813 
814  // Postconditions:
815 
816  ensure(result.is_attached());
817 
818  // Exit:
819 
820  return result;
821 }
822 
823 void
826 {
827  // Preconditions:
828 
829  require(allocated_id_space_iterator(xitr));
830 
831  // Body:
832 
833  _states[local_scope(xitr.index())]->release_iterator(xitr);
834 
835  // Postconditions:
836 
837  ensure(is_basic_query);
838 
839  // Exit:
840 
841  return;
842 }
843 
844 bool
847 {
848  // Preconditions:
849 
850  // Body:
851 
852  pod_type local_id = local_scope(xitr.index());
853 
854  bool result =
855  contains(local_id) && _states[local_id]->allocated_iterator(xitr);
856 
857  // Postconditions:
858 
859  ensure(is_basic_query);
860 
861  // Exit:
862 
863  return result;
864 }
865 
866 // PROTECTED MEMBER FUNCTIONS
867 
868 // PRIVATE MEMBER FUNCTIONS
869 
870 
871 // ===========================================================
872 // ANY FACET
873 // ===========================================================
874 
875 // PUBLIC MEMBER FUNCTIONS
876 
877 bool
879 is_ancestor_of(const any *other) const
880 {
881  // Preconditions:
882 
883  require(other != 0);
884 
885  // Body:
886 
887  // True if other conforms to this
888 
889  bool result = dynamic_cast<const explicit_index_space_interval*>(other) != 0;
890 
891  // Postconditions:
892 
893  // Exit:
894 
895  return result;
896 }
897 
898 bool
900 invariant() const
901 {
902  bool result = true;
903 
904  if(invariant_check())
905  {
906  // Prevent recursive calls to invariant
907 
909 
910  // Must satisfy base class invariant
911 
912  invariance(index_space_interval::invariant());
913 
914  // Invariances for this class:
915 
916  // Finished, turn invariant checking back on.
917 
919  }
920 
921  // Exit
922 
923  return result;
924 }
925 
926 // PROTECTED MEMBER FUNCTIONS
927 
928 // PRIVATE MEMBER FUNCTIONS
929 
930 
931 // ===========================================================
932 // NON-MEMBER FUNCTIONS
933 // ===========================================================
934 
935 #include "SheafSystem/index_space_family.h"
936 
937 size_t
938 sheaf::
939 deep_size(const explicit_index_space_interval& xn, bool xinclude_shallow)
940 {
941  // Preconditions:
942 
943  // Body:
944 
945  size_t result = xinclude_shallow ? sizeof(xn) : 0;
946 
947  // Add memory associated with member _states.
948 
951 
952 // result += deep_size(xn._states, false);
953 
954  for(pod_index_type i = 0; i < xn._states.ub(); ++i)
955  {
956  if(xn._states[i] != 0)
957  {
958  result += xn._states[i]->deep_size(true);
959  }
960  }
961 
962  // Postconditions:
963 
964  ensure(result >= 0);
965 
966  // Exit
967 
968  return result;
969 }
virtual explicit_index_space_state * explicit_state(pod_type xlocal_id) const
The explicit id space state for id xlocal_id. Returns null if there is no explicit id space for xloca...
virtual pod_type local_scope(pod_type xspace_id) const
Id relative to this collection equivalent to the id space family id xspace_id.
pod_type end() const
The ending index of the id spaces.
index_type ub() const
The upper bound on the storage array. The number of items current allocated in the storage array...
An abstract class that defines the product structure for an id space.
size_type ct() const
The number of items currently in use.
virtual const index_space_family & id_spaces() const
The id space family for this (const version).
An abstract iterator over the ids of an id space.
virtual const std::string & class_name() const
The name of this class.
explicit_states_type _states
The block of explicit_index_space_state.
virtual bool has_product_structure(pod_type xlocal_id) const
True if the id space with id xlocal_id has a product structure.
virtual bool is_ancestor_of(const any *other) const
Conformance test; true if other conforms to this.
virtual void release_id_space_iterator(index_space_iterator &xitr) const
Returns the id space iterator xitr to the iterator pool.
virtual index_space_interval & operator=(const index_space_collection &xother)
Assignment operator.
virtual bool invariant() const
Class invariant.
An abstract handle to a space of alternate integer identifiers (aliases) for a subset of a hub set of...
virtual bool operator==(const index_space_collection &xother) const
True if this is equivalent to xother.
pod_index_type pod_type
The "plain old data" index type for this.
virtual pod_type pod(pod_type xlocal_id, pod_type xid) const
The pod index in the space with id xlocal_id equivalent to xid in the hub id space.
virtual pod_type unglued_hub_pod(pod_type xlocal_id, pod_type xid) const
The pod index in the unglued hub id space equivalent to xid in the id space with id xlocal_id...
virtual bool contains_unglued_hub(pod_type xlocal_id, pod_type xid) const
True if the space with id xlocal_id contains an id equivalent to xid in the unglued hub id space...
virtual pod_type index() const =0
Index of this space.
virtual bool is_attached() const =0
True if this handle is attached to a state.
virtual bool allocated_id_space_iterator(const index_space_iterator &xitr) const
True if and only if id space iterator xitr was allocated by the iterator pool.
virtual size_type ct(pod_type xlocal_id) const
The number of members for the id space with id xlocal_id.
virtual index_space_handle & get_id_space(pod_type xlocal_id) const
Allocates an id space handle from the handle pool attached to state with id xlocal_id.
Abstract base class with useful features for all objects.
Definition: any.h:39
An implemenation of index_space_collection that adds an interface for the interval [begin()...
friend SHEAF_DLL_SPEC size_t deep_size(const explicit_index_space_interval &xn, bool xinclude_shallow)
The deep size of explicit_index_space_interval& xn.
pod_type _begin
Beginning space id of this interval in the id space family scope.
virtual bool operator==(const index_space_collection &xother) const
True if this is equivalent to xother.
An immutable abstract state for a space of alternate integer identifiers (aliases) for a subset of th...
virtual bool supports_persistent_id_spaces() const
True, if this interval supports persistent id spaces.
virtual bool contains_family(pod_type xspace_id) const
True if this collection contains the id space with family id xspace_id.
SHEAF_DLL_SPEC size_t deep_size(const dof_descriptor_array &xp, bool xinclude_shallow=true)
The deep size of the referenced object of type dof_descriptor_array.
unsigned long size_type
An unsigned integral type used to represent sizes and capacities.
Definition: sheaf.h:52
virtual bool is_persistent(pod_type xlocal_id) const
True if the id space with id xlocal_id should be written to disk.
void set_item(index_type xindex, const_reference_type xitem)
Puts the item xitem at index xindex, but will not resize.
virtual void delete_product_structure(pod_type xlocal_id)
Deletes the product structure for the id space with id xlocal_id.
pod_type _end
Ending space id of this interval in the id space family scope.
virtual void release_id_space(index_space_handle &xid_space) const
Returns the id space handle xid_space to the handle pool.
A collection of id space states. This is a virtual class with provides an interface for accessing the...
void disable_invariant_check() const
Disable invariant check. Intended for preventing recursive calls to invariant and for suppressing inv...
Definition: any.h:97
virtual explicit_index_space_interval * clone() const
Virtual constructor; create a new instance of the same type at this.
static factory< index_space_interval > & id_space_interval_factory()
A factory for making descendants of this class.
virtual pod_type index() const =0
Index of this space.
An implementation of index_space_interval for an interval of explicit id spaces.
void insert(explicit_index_space_state &xid_space)
Insert the explicit id space xid_space into this interval.
virtual bool allocated_id_space(const index_space_handle &xid_space) const
True if and only if id space handle xid_space was allocated by the handle pool.
virtual bool is_attached() const =0
True if this iterator is attached to a state.
bool invariant_check() const
True if invariant checking is enabled.
Definition: any.h:79
virtual explicit_index_space_interval & operator=(const index_space_collection &xother)
Assignment operator.
pod_type index() const
The index of this id space.
int_type pod_index_type
The plain old data index type.
Definition: pod_types.h:49
pod_type end() const
Ending space id of this interval in the id space family scope.
Factory and container for a family of id spaces.
virtual pod_type begin(pod_type xlocal_id) const
Beginning id of the space with id xlocal_id.
virtual bool contains(pod_type xlocal_id) const
True if this collection contains the id space with local id xlocal_id.
virtual pod_type end(pod_type xlocal_id) const
Ending id of the space with id xlocal_id.
virtual bool invariant() const
Class invariant.
SHEAF_DLL_SPEC bool is_valid(pod_index_type xpod_index)
True if an only if xpod_index is valid.
Definition: pod_types.cc:37
pod_type begin() const
Beginning space id of this interval in the id space family scope.
bool is_same_type(const any *other) const
True if other is the same type as this.
Definition: any.cc:79
virtual void remove(pod_type xlocal_id)
Remove the id space with id xlocal_id.
void enable_invariant_check() const
Enable invariant checking.
Definition: any.h:87
virtual const abstract_product_structure & product_structure(pod_type xlocal_id) const
The product structure for the id space with id xlocal_id (const version).
virtual index_space_iterator & get_id_space_iterator(pod_type xlocal_id) const
Allocates an id space iterator from the iterator pool attached to state with id xlocal_id.
bool in_bounds(pod_type xspace_id) const
True if id xspace_id is in the bounds [begin(), end()).
static const explicit_index_space_interval & new_space(index_space_family &xid_spaces, size_type xub)
Create a new interval of id spaces for explicit id spaces in the id space family xid_spaces with uppe...
virtual void new_product_structure(pod_type xlocal_id, const abstract_product_structure &xproduct)
Creates a new product structure for the id space with id xlocal_id by cloning the product structure...