예제 #1
0
 public ImmuTable combineWith(ImmuTable other) {
   MuTable newTable;
   TableStepper others;
   newTable = (MuTable) myTable.copy().asMuTable();
   others = other.stepper();
   while (others.hasValue()) {
     newTable.store((myDsp.inverseOf(others.position())), others.fetch());
     others.step();
   }
   others.destroy();
   return new OffsetImmuTable(newTable.asImmuTable(), myDsp);
   /*
   udanax-top.st:47646:OffsetImmuTable methodsFor: 'SEF manipulation'!
   {ImmuTable} combineWith: other {ImmuTable}
   	| newTable {MuTable} others {TableStepper} |
   	newTable _ myTable copy asMuTable.
   	others _ other stepper.
   	[others hasValue] whileTrue:
   		[newTable at: (myDsp inverseOf: others position) store: others fetch.
   		others step].
   	others destroy.
   	^OffsetImmuTable create: newTable asImmuTable with: myDsp!
   */
 }
예제 #2
0
 public MuTable asMuTable() {
   MuTable newTab;
   TableStepper s;
   newTab = (myTable.emptySize(myTable.count())).asMuTable();
   Stepper stomper = (s = myTable.stepper());
   for (; stomper.hasValue(); stomper.step()) {
     Heaper e = (Heaper) stomper.fetch();
     if (e == null) {
       continue;
     }
     newTab.store((myDsp.of(s.position())), e);
   }
   stomper.destroy();
   return newTab;
   /*
   udanax-top.st:47617:OffsetImmuTable methodsFor: 'conversion'!
   {MuTable} asMuTable
   	| newTab {MuTable} s {TableStepper} |
   	newTab _ (myTable emptySize: myTable count) asMuTable.
   	(s _ myTable stepper) forEach: [ :e {Heaper} |
   		newTab at: (myDsp of: s position) store: e].
   	^ newTab!
   */
 }