Example #1
0
 /**
  * Defines the specified three-dimensional array member. For predefined members, the array is
  * populated when empty; custom members should use literal (populated) arrays.
  *
  * @param arrayMember the three-dimensional array member.
  * @return the specified array member.
  * @throws UnsupportedOperationException if the specified array is empty and the member type is
  *     unknown.
  */
 protected /* <M extends Member> M*/ Member[][][] array(/*M*/ Member[][][] arrayMember) {
   boolean resetIndexSaved = _resetIndex;
   if (_resetIndex) {
     _bitIndex = 0;
     _resetIndex = false; // Ensures the array elements are sequential.
   }
   for (int i = 0; i < arrayMember.length; i++) {
     array(arrayMember[i]);
   }
   _resetIndex = resetIndexSaved;
   return (/*M*/ Member[][][]) arrayMember;
 }
Example #2
0
 /**
  * Defines the specified three dimensional array of structs as inner structs. The array is
  * populated if necessary using the struct component default constructor (which must be public).
  *
  * @param structs the three dimensional struct array.
  * @return the specified struct array.
  * @throws IllegalArgumentException if the specified array contains inner structs.
  */
 protected /* <S extends Struct> S*/ Struct[][][] array(/*S*/ Struct[][][] structs) {
   boolean resetIndexSaved = _resetIndex;
   if (_resetIndex) {
     _bitIndex = 0;
     _resetIndex = false; // Ensures the array elements are sequential.
   }
   for (int i = 0; i < structs.length; i++) {
     array(structs[i]);
   }
   _resetIndex = resetIndexSaved;
   return (/*S*/ Struct[][][]) structs;
 }