public DividaRepositorio(EnumTipoPersistencia tipoPersistencia)
 {
     switch (tipoPersistencia)
     {
     case EnumTipoPersistencia.XML:
         _persistenciaDivida = new DividaXML();
         break;
     }
 }
Exemple #2
0
        public ModeloObjetoBase(string tabela, string chavePrimaria)
        {
            this._tabela        = tabela;
            this._chavePrimaria = chavePrimaria;

            this.ItemsPersistencia = new ListaItemsPersistencia(this._tabela, this._chavePrimaria);

            this._tipoPersistencia = EnumTipoPersistencia.Normal;
            this._colecao          = null;
        }
Exemple #3
0
 /// <summary>
 /// Por padrão o tipo de persistência é Normal. Executando este método você irá utilizar persistência com coleção.
 /// </summary>
 public void DefinirTipoPersistencia(ColecaoPersistencia colecao)
 {
     this._colecao          = colecao;
     this._tipoPersistencia = EnumTipoPersistencia.Colecao;
 }
Exemple #4
0
 public static void DefinaPersistenciaDados(EnumTipoPersistencia tipoPersistencia)
 {
     TipoPersistencia = tipoPersistencia;
 }