public final OrderedPair<Processor> doEdit() throws EditException { if (applied) { throw new EditException("Edit has already been applied!"); } if (processors.getA() instanceof ProcessorImpl == false || processors.getB() instanceof ProcessorImpl == false) { throw new EditException( "Edit cannot be applied to a Processor which isn't an instance of ProcessorImpl"); } ProcessorImpl pia = (ProcessorImpl) processors.getA(); ProcessorImpl pib = (ProcessorImpl) processors.getB(); try { synchronized (processors) { doEditAction(pia, pib); applied = true; return this.processors; } } catch (EditException ee) { applied = false; throw ee; } }
public final OrderedPair<Processor> doEdit() throws EditException { if (applied) { throw new EditException("Edit has already been applied!"); } if (processors.getA() instanceof ProcessorImpl == false || processors.getB() instanceof ProcessorImpl == false) { throw new EditException( "Edit cannot be applied to a Processor which isn't an instance of ProcessorImpl"); } ProcessorImpl pia = (ProcessorImpl) processors.getA(); ProcessorImpl pib = (ProcessorImpl) processors.getB(); try { synchronized (processors) { doEditAction(pia, pib); applied = true; return this.processors; } } catch (EditException ee) { applied = false; throw ee; } }
public final OrderedPair<Processor> doEdit() throws EditException { if (applied) { throw new EditException("Edit has already been applied!"); } if (processors.getA() instanceof ProcessorImpl == false || processors.getB() instanceof ProcessorImpl == false) { throw new EditException( "Edit cannot be applied to a Processor which isn't an instance of ProcessorImpl"); } ProcessorImpl pia = (ProcessorImpl) processors.getA(); ProcessorImpl pib = (ProcessorImpl) processors.getB(); try { synchronized (processors) { doEditAction(pia, pib); applied = true; return this.processors; } } catch (EditException ee) { applied = false; throw ee; } }