public void BorrarMapaParaPaso(int id_paso)
        {
            /*PROTECTED REGION ID(WhateverGenNHibernate.CP.Whatever_Mapa_borrarMapaParaPaso) ENABLED START*/

            IMapaCAD mapaCAD = null;
            MapaCEN  mapaCEN = null;



            try
            {
                SessionInitializeTransaction();
                mapaCAD = new MapaCAD(session);
                mapaCEN = new  MapaCEN(mapaCAD);



                // Write here your custom transaction ...

                MapaEN mapen = new MapaEN();
                mapen = mapaCAD.FiltrarMapaPorPaso(id_paso);
                mapaCAD.UnrelationerMapaPaso(mapen.Id, id_paso);
                mapaCAD.Destroy(mapen.Id);


                SessionCommit();
            }
            catch (Exception ex)
            {
                SessionRollBack();
                throw ex;
            }
            finally
            {
                SessionClose();
            }


            /*PROTECTED REGION END*/
        }
Example #2
0
        public int CrearMapaParaPaso(int id_paso, string latitud, string longitud, int zoom)
        {
            /*PROTECTED REGION ID(WhateverGenNHibernate.CP.Whatever_Mapa_crearMapaParaPaso) ENABLED START*/

            IMapaCAD mapaCAD = null;
            MapaCEN  mapaCEN = null;



            try
            {
                SessionInitializeTransaction();
                mapaCAD = new MapaCAD(session);
                mapaCEN = new  MapaCEN(mapaCAD);



                // Write here your custom transaction ...

                int id = mapaCEN.New_(latitud, longitud, zoom);
                mapaCAD.RelationerMapaPaso(id, id_paso);


                SessionCommit();
                return(id);
            }
            catch (Exception ex)
            {
                SessionRollBack();
                throw ex;
            }
            finally
            {
                SessionClose();
            }


            /*PROTECTED REGION END*/
        }
Example #3
0
 public MapaCEN(IMapaCAD _IMapaCAD)
 {
     this._IMapaCAD = _IMapaCAD;
 }
Example #4
0
 public MapaCEN()
 {
     this._IMapaCAD = new MapaCAD();
 }