private void handleCommissionMeemCreation(Meem meem, String identifier, int index) {
      commissionMeems[index] = meem;

      Meem categoryMeem = Meem.spi.get(MeemPath.spi.create(Space.HYPERSPACE, myHyperSpacePath));
      Category category =
          (Category) MeemUtility.spi.get().getTarget(categoryMeem, "category", Category.class);
      category.addEntry(identifier, meem);

      configureCommissionMeem(meem, identifier, index);

      LifeCycleLimit lifeCycleLimit =
          (LifeCycleLimit)
              MeemUtility.spi.get().getTarget(meem, "lifeCycleLimit", LifeCycleLimit.class);
      lifeCycleLimit.limitLifeCycleState(LifeCycleState.READY);

      LifeCycle lifeCycle =
          (LifeCycle) MeemUtility.spi.get().getTarget(meem, "lifeCycle", LifeCycle.class);
      lifeCycle.changeLifeCycleState(LifeCycleState.READY);
    }
Esempio n. 2
0
 /* (non-Javadoc)
  * @see org.eclipse.gef.commands.Command#undo()
  */
 public void undo() {
   lifeCycle.changeLifeCycleState(prevState);
 }
Esempio n. 3
0
 /* (non-Javadoc)
  * @see org.eclipse.gef.commands.Command#execute()
  */
 public void execute() {
   lifeCycle.changeLifeCycleState(state);
 }