Exemple #1
0
        public static EtudeHasEspeceViewModel getEtudeHasEspece(int idEtude, int idEspece)
        {
            EtudeHasEspeceDAO eDAO = EtudeHasEspeceDAO.getEtudeHasEspece(idEtude, idEspece);

            int            Etude_idEtude = eDAO.Etude_idEtudeDAO;
            EtudeViewModel et            = EtudeORM.getEtude(Etude_idEtude);

            int             Espece_idEspece = eDAO.Espece_idEspeceDAO;
            EspeceViewModel e = EspeceORM.getEspece(Espece_idEspece);

            EtudeHasEspeceViewModel ee = new EtudeHasEspeceViewModel(et, e, eDAO.densiteTotaleEspeceDAO);

            return(ee);
        }
        public static EtudeHasPlageViewModel getEtudeHasPlage(int idEtude, int idPlage, int idZone)
        {
            EtudeHasPlageDAO eDAO = EtudeHasPlageDAO.getEtudeHasPlage(idEtude, idPlage, idZone);

            int            Etude_idEtude = eDAO.Etude_idEtudeDAO;
            EtudeViewModel et            = EtudeORM.getEtude(Etude_idEtude);

            int            Plage_idPlage = eDAO.Plage_idPlageDAO;
            PlageViewModel p             = PlageORM.getPlage(Plage_idPlage);

            int           Zone_idZone = eDAO.Zone_idZoneDAO;
            ZoneViewModel z           = ZoneORM.getZone(Zone_idZone);

            EtudeHasPlageViewModel ep = new EtudeHasPlageViewModel(et, p, z, eDAO.name_concatenationDAO);

            return(ep);
        }
Exemple #3
0
        public static ObservableCollection <EtudeHasEspeceViewModel> listeEtudeHasEspeces()
        {
            ObservableCollection <EtudeHasEspeceDAO>       lDAO = EtudeHasEspeceDAO.listeEtudeHasEspeces();
            ObservableCollection <EtudeHasEspeceViewModel> l    = new ObservableCollection <EtudeHasEspeceViewModel>();

            foreach (EtudeHasEspeceDAO element in lDAO)
            {
                int            Etude_idEtude = element.Etude_idEtudeDAO;
                EtudeViewModel et            = EtudeORM.getEtude(Etude_idEtude);

                int             Espece_idEspece = element.Espece_idEspeceDAO;
                EspeceViewModel e = EspeceORM.getEspece(Espece_idEspece);

                EtudeHasEspeceViewModel ee = new EtudeHasEspeceViewModel(et, e, element.densiteTotaleEspeceDAO);
                l.Add(ee);
            }
            return(l);
        }
        public static ObservableCollection <EtudeHasPlageViewModel> listeEtudeHasPlages()
        {
            ObservableCollection <EtudeHasPlageDAO>       lDAO = EtudeHasPlageDAO.listeEtudeHasPlages();
            ObservableCollection <EtudeHasPlageViewModel> l    = new ObservableCollection <EtudeHasPlageViewModel>();

            foreach (EtudeHasPlageDAO element in lDAO)
            {
                int            Etude_idEtude = element.Etude_idEtudeDAO;
                EtudeViewModel et            = EtudeORM.getEtude(Etude_idEtude);

                int            Plage_idPlage = element.Plage_idPlageDAO;
                PlageViewModel p             = PlageORM.getPlage(Plage_idPlage);

                int           Zone_idZone = element.Zone_idZoneDAO;
                ZoneViewModel z           = ZoneORM.getZone(Zone_idZone);

                EtudeHasPlageViewModel ep = new EtudeHasPlageViewModel(et, p, z, element.name_concatenationDAO);
                l.Add(ep);
            }
            return(l);
        }