Package br.com.visualmidia.tools

Examples of br.com.visualmidia.tools.MergeSortAlgorithm


        List<State> states;
        try {
            states = (List<State>) system.query(new GetStatesList());
            for (State state : states) {
                List<City> citiesList = state.getCityList();
                MergeSortAlgorithm sortAlgorithm = new MergeSortAlgorithm();
                sortAlgorithm.sortCitiesByName(citiesList);
                for (City city : citiesList) {
                    TableItem item = new TableItem(citiesTable, SWT.LEFT);
                    item.setText(0, city.getId());
                    item.setText(1, state.getAcronym());
                    item.setText(2, city.getCityName());
View Full Code Here


            oldNumberOfParcels += Integer.parseInt(course.getDuration());
//          }
      }
     
      List<Parcel> registrationParcelList = registration.getParcels();
      MergeSortAlgorithm sort = new MergeSortAlgorithm();
      sort.sortParcelByDate(registrationParcelList);
     
      for (int i = 0; i < registrationParcelList.size(); i++) {
        Parcel parcel = registrationParcelList.get(i);
       
              GDDate date = new GDDate(parcel.getDate());
View Full Code Here

    data.bottom = new FormAttachment(100, 0);
    parcelTable.setLayoutData(data);
  }

  public void updateParcelTable(List<Parcel> parcels) {
    MergeSortAlgorithm sort = new MergeSortAlgorithm();
    sort.sortParcelByDate(parcels);
    parcelTable.removeAll();

    float payTotal = 0;
    for (int i = 0; i < parcels.size(); i++) {
      Parcel parcel = (Parcel) parcels.get(i);
View Full Code Here

      }

      parent.setText(7, (registration.getEndEmployee() == null ? "" : registration.getEndEmployee().getName()));

      List<Parcel> parcels = registration.getParcels();
      MergeSortAlgorithm sort = new MergeSortAlgorithm();
      sort.sortParcelByDate(parcels);

      int numberOfNotPayedParcels = 0;
      for (Parcel parcel : parcels) {
        GDDate todayPlusOneWeek = new GDDate();
        todayPlusOneWeek.addDays(7);
View Full Code Here

          JRPrintPage page = new JRBasePrintPage();
           
            registrations = (Map<String, Registration>) system.query(new GetRegistration());
            List<Registration> registrationList = new ArrayList<Registration>(registrations.values());
           
            MergeSortAlgorithm sortAlgorithm = new MergeSortAlgorithm();
            sortAlgorithm.sortRegistrationByName(registrationList);
           
            for (Registration registration : registrationList) {
                final List<Parcel> parcels = registration.getParcels();
                for (Parcel parcel : parcels) {
                    final GDDate parcelDate = new GDDate(parcel.getDate());
View Full Code Here

    Registration registration;
    try {
      registration = (Registration) system.query(new GetRegistration(idRegistration[0]));

      List<Parcel> list = registration.getParcels();
      MergeSortAlgorithm sort = new MergeSortAlgorithm();
      sort.sortParcelByDate(list);
     
      Parcel parcel = list.get(Integer.parseInt(idRegistration[1]) - 1);
     
      if (!parcel.isPayed() && !isParcelOpen(list, parcel)) {new ParcelPaymentDialog(getShell(), registration, Integer.parseInt(idRegistration[1]) - 1, true).open();
        getRegistration();
View Full Code Here

    float payTotal = 0;
    String idReg = "";
   
    for (Registration registration : registrations) {
      List<Parcel> parcels = registration.getParcels();
      MergeSortAlgorithm sort = new MergeSortAlgorithm();
      sort.sortParcelByDate(parcels);
     
      TableItem item = new TableItem(parcelTable, SWT.NONE, parcelTable.getItemCount());
      if (!registration.getParcels().isEmpty()){
        item.setBackground(new Color(null,255,255,255));
        item.setText(0, "Matr�cula: " + registration.getIdRegistration());
View Full Code Here

                          }
                      numberOfParcel++;
                  }
              }
             
              MergeSortAlgorithm sortAlgorithm= new MergeSortAlgorithm();

              if(parcelDataList.size() > 1){
                  sortAlgorithm.sortParcelByDate(parcelDataList);
              }
              if (registrationWithoutParcels.size() > 1){
                sortAlgorithm.sortRegistrationByDate(registrationWithoutParcels);
              }
              int totalOfStudents = 0;
             
              posY += 5;
              page.addElement(drawGrayRectangle(posX, posY, 535, 20, 3));
View Full Code Here

    _classRoom.hasExceedingStudents();
    _mapExceedent = _classRoom.getMapExceedent();
    _listHours = _classRoom.getListHours();
   
    if(_listHours.size() > 1) {
      MergeSortAlgorithm sortAlgorithm = new MergeSortAlgorithm();
      sortAlgorithm.sortNumbers(_listHours);
    }

    tabFolder = new TabFolder(aboutAreaComposite, SWT.NONE);
   
    FormData data = new FormData();
View Full Code Here

      _classRoom.hasExceedingStudents();
      _mapExceedent = _classRoom.getMapExceedent();
      _listHours = _classRoom.getListHours();
     
      if(_listHours.size() > 1) {
      MergeSortAlgorithm sortAlgorithm = new MergeSortAlgorithm();
      sortAlgorithm.sortNumbers(_listHours);
    }

      Table table = tablesMap.get(hour);
      for (TableItem item : table.getItems()) {
      item.dispose();
View Full Code Here

TOP

Related Classes of br.com.visualmidia.tools.MergeSortAlgorithm

Copyright © 2018 www.massapicom. 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.