예제 #1
0
        public List<Combustivel> listar()
        {
            List<Combustivel> lista = new List<Combustivel>();
            Combustivel combustivel;

            combustivel = new Combustivel();
            combustivel.ID = 1;
            combustivel.descricao = "Gasolina";
            lista.Add(combustivel);
            
            combustivel = new Combustivel();
            combustivel.ID = 2;
            combustivel.descricao = "Álcool";
            lista.Add(combustivel);
            
            combustivel = new Combustivel();
            combustivel.ID = 3;
            combustivel.descricao = "Diesel";
            lista.Add(combustivel);

            combustivel = new Combustivel();
            combustivel.ID = 4;
            combustivel.descricao = "GN";
            lista.Add(combustivel);
            return lista;
        }
예제 #2
0
 public Abastecimento()
 {
     _veiculo = new Veiculo();
     _posto = new Posto();
     _combustivel = new Combustivel();
 }