001 package videoautomat.contentcreator.stdactions; 002 003 import sale.Action; 004 import sale.GateChangeTransition; 005 import sale.SaleProcess; 006 import sale.SalesPoint; 007 import sale.UIGate; 008 009 /** 010 * Standart action to change next to commit gate. 011 * 012 * @author Tobias Ruch 013 */ 014 public class CommitAction implements Action { 015 016 /** 017 * ID for Serialization. 018 */ 019 private static final long serialVersionUID = 8653661717836066468L; 020 021 /** 022 * Changes to the commit gate. Called by an action listener, such as an button. 023 * The attribues are setted by the action listener. 024 * @param saleProcess - current {@link sale.SaleProecess} 025 * @param salePoint - current {@link sale.SalesPoint} 026 */ 027 public void doAction(SaleProcess saleProcess, SalesPoint salePoint) throws Throwable { 028 UIGate currentGate = (UIGate)saleProcess.getCurrentGate(); 029 currentGate.setNextTransition(GateChangeTransition.CHANGE_TO_COMMIT_GATE); 030 031 } 032 033 }