Package modele.commun

Examples of modele.commun.TypeUnite


    try {
      dlgDialog = new TypeUniteEditionFenetre();
      dlgDialog.affiche();

      if (dlgDialog.OK_Button()) {
        TypeUnite typeUnite = dlgDialog.renvoiTypeUnite();
        getTypeUniteDao().insert(typeUnite);
      }
    } catch (PrjException e) {
      throw new PrjException(e.RetourMessage());
    }
View Full Code Here


    public int getRowCount() {
      return typeUnite.size();
    }

    public Object getValueAt(int rowIndex, int columnIndex) {
      TypeUnite typeUniteAtRow = typeUnite.get(rowIndex);
      switch (columnIndex) {
      case 0:
        return typeUniteAtRow.getId();
      case 1:
        return typeUniteAtRow.getValeur();
      case 2:
        return typeUniteAtRow.getLibelle();



      default:
        throw new IllegalStateException("Le nombre de colonne ne peut pas d�passer " + NOMBRE_COLONNE + ". index demand� " + columnIndex);
View Full Code Here

          try {
            smt = connection.prepareStatement(GET_TYPE_UNITE_BY_ID);
            smt.setInt(1, id);
            res = smt.executeQuery();
            if (res.next()) {
              result[0] = new TypeUnite(res.getInt(1));
              result[0].setValeur(res.getInt(2));
              result[0].setLibelle(res.getString(3));
            }
          } finally {
            try {
View Full Code Here

          ResultSet res = null;
          try {
            smt = connection.prepareStatement(GET_ALL_TYPE_UNITE);
            res = smt.executeQuery();
            while (res.next()) {
              TypeUnite typeUnite = new TypeUnite(res.getInt(1));
              typeUnite.setValeur(res.getInt(2));
              typeUnite.setLibelle(res.getString(3));
              listeTypeUnite.add(typeUnite);
            }
          } finally {
            try {
              if (res != null) {
View Full Code Here

          ResultSet res = null;
          try {
            smt = connection.createStatement();
            res = smt.executeQuery("SELECT idTypeUnite, valeurTypeUnite, descripTypeUnite from ttypeunite where idTypeUnite = LAST_INSERT_ID()");
            if (res.next()) {
              result[0] = new TypeUnite(res.getInt(1));
              result[0].setValeur(res.getInt(2));
              result[0].setLibelle(res.getString(3));
            }
          } finally {
            try {
View Full Code Here

            if (res.next()) {
              result[0] = new TypeCharge(res.getInt(1));
              result[0].setLibelle(res.getString(2));
              result[0].setNbUnite(res.getInt(3));

              TypeUnite typeUnite = new TypeUnite(res.getInt(4));
              typeUnite.setLibelle(res.getString(4));
              result[0].setTypeUnite(typeUnite);
            }
          } finally {
            try {
              if (res != null) {
View Full Code Here

            while (res.next()) {
              TypeCharge typeCharge = new TypeCharge(res.getInt(1));
              typeCharge.setLibelle(res.getString(2));
              typeCharge.setNbUnite(res.getInt(3));

              TypeUnite typeUnite = new TypeUnite(res.getInt(4));
              typeUnite.setLibelle(res.getString(5));
              typeCharge.setTypeUnite(typeUnite);

              listeTypeCharge.add(typeCharge);
            }
          } finally {
View Full Code Here

            if (res.next()) {
              result[0] = new TypeCharge(res.getInt(1));
              result[0].setLibelle(res.getString(2));
              result[0].setNbUnite(res.getInt(3));
             
              TypeUnite typeUnite = new TypeUnite(res.getInt(4));             
              typeUnite.setLibelle(res.getString(5));
              result[0].setTypeUnite(typeUnite);
            }
          } finally {
            try {
              if (res != null) {
View Full Code Here

             
              TypeEntretien typeEntretien = new TypeEntretien(res.getInt(2));
              typeEntretien.setLibelle(res.getString(3));
              result[0].setTypeEntretien(typeEntretien);
             
              TypeUnite typeUnite = new TypeUnite(res.getInt(2));
              typeUnite.setLibelle(res.getString(3));
              result[0].setTypeUnite(typeUnite);
            }
          } finally {
            try {
              if (res != null) {
View Full Code Here

              ficheEntretien.setKmPrevenirAvantEntretien(res.getLong(11));
             
              ficheEntretien.setCoutEntretien(res.getDouble(12));
              ficheEntretien.setNbUnite(res.getInt(13));
             
              TypeUnite typeUnite = new TypeUnite(res.getInt(14));
              typeUnite.setLibelle(res.getString(15));
              ficheEntretien.setTypeUnite(typeUnite);

              listeFicheEntretien.add(ficheEntretien);
            }
          } finally {
View Full Code Here

TOP

Related Classes of modele.commun.TypeUnite

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.