Package com.playlist.listainteligente.condicao

Examples of com.playlist.listainteligente.condicao.Condicao


        ArrayList<MusicaS> todasMusicas = PortaCDs.getMusicas();
        for (int i = 0; i < todasMusicas.size(); i++) {
            MusicaS musica = todasMusicas.get(i);
            boolean todasAsCondicoes = true;
            for (int j = 0; todasAsCondicoes && j < condicoes.size(); j++) {
                Condicao condicao = condicoes.get(j);
                todasAsCondicoes &= condicao.resolver(musica);
            }
            if (todasAsCondicoes) {
                musicas.add(musica);
            }
        }
View Full Code Here


        ArrayList<MusicaS> novaLista = new ArrayList<MusicaS>(500);
        for (int i = 0; i < musicas.size(); i++) {
            MusicaS musica = musicas.get(i);
            boolean add = true;
            for (int j = 0; add && j < condicoes.size(); j++) {
                Condicao condicao = condicoes.get(j);
                add &= condicao.resolver(musica);
            }
            if (add) {
                novaLista.add(musica);
            }
        }
View Full Code Here

TOP

Related Classes of com.playlist.listainteligente.condicao.Condicao

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.