Ejemplo n.º 1
0
        public void addNewSource(DIDataSource datasource, List <DITableSource> tables)
        {
            DI_DAO dao = null;

            try
            {
                dao = new DI_DAO();
                dao.beginTransaction();
                dao.addDataSource(datasource);
                foreach (DITableSource table in tables)
                {
                    dao.addTableSource(table);
                }
                dao.commitTransaction();
            }
            catch (Exception ex)
            {
                dao.rollbackTransaction();
                throw ex;
            }
        }