Package org.springframework.orm.hibernate3

Examples of org.springframework.orm.hibernate3.HibernateTemplate.update()


      List<Schedule> nextSchedules = htl.find("from Schedule where position > ?", schedule.getPosition());

      for (Schedule nextSchedule : nextSchedules)
      {
        nextSchedule.setPosition(nextSchedule.getPosition() - 1);
        htl.update(nextSchedule);
      }

      if (schedule.getPosition() != maxPosition)
      {
        schedule.setPosition(maxPosition);
View Full Code Here


      }

      if (schedule.getPosition() != maxPosition)
      {
        schedule.setPosition(maxPosition);
        htl.update(schedule);

        return true;
      }

      return false;
View Full Code Here

                });

        if (prevActions.size() > 0)
        {
          prevActions.get(0).setPosition(action.getPosition());
          htl.update(prevActions.get(0));
        }

        action.setPosition(action.getPosition() - 1);
        htl.update(action);
View Full Code Here

          prevActions.get(0).setPosition(action.getPosition());
          htl.update(prevActions.get(0));
        }

        action.setPosition(action.getPosition() - 1);
        htl.update(action);

        return true;
      }

      return false;
View Full Code Here

                });

        if (nextActions.size() > 0)
        {
          nextActions.get(0).setPosition(action.getPosition());
          htl.update(nextActions.get(0));
        }

        action.setPosition(action.getPosition() + 1);
        htl.update(action);
View Full Code Here

          nextActions.get(0).setPosition(action.getPosition());
          htl.update(nextActions.get(0));
        }

        action.setPosition(action.getPosition() + 1);
        htl.update(action);

        return true;
      }

      return false;
View Full Code Here

              });

      for (ScheduleAction prevAction : prevActions)
      {
        prevAction.setPosition(prevAction.getPosition() + 1);
        htl.update(prevAction);
      }

      if (action.getPosition() != 1)
      {
        action.setPosition(1);
View Full Code Here

      }

      if (action.getPosition() != 1)
      {
        action.setPosition(1);
        htl.update(action);

        return true;
      }

      return false;
View Full Code Here

              });

      for (ScheduleAction nextAction : nextActions)
      {
        nextAction.setPosition(nextAction.getPosition() - 1);
        htl.update(nextAction);
      }

      if (action.getPosition() != maxPosition)
      {
        action.setPosition(maxPosition);
View Full Code Here

      }

      if (action.getPosition() != maxPosition)
      {
        action.setPosition(maxPosition);
        htl.update(action);

        return true;
      }

      return false;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.