Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Cancelled implements EstadoOrder{
- private static final Cancelled instancia = new Cancelled();
- private Cancelled(){}
- public static Cancelled getInstancia(){ return instancia; }
- @Override
- public void anadirProducto(Order order, Product producto) {
- }
- @Override
- public void eliminarProducto(Order order, Product producto) {
- }
- @Override
- public void siguienteEstado(Order order) {
- order.setEstado(Completed.getInstancia());
- }
- @Override
- public void anteriorEstado(Order order) {
- }
- @Override
- public void modificarCantidadProducto(Order order, Product producto) {
- }
- @Override
- public void pagar(Order order) {
- }
- @Override
- public void cancelar(Order order) {
- order.setConfirmado(false);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement