lojix/logic/src/main/com/thesett/aima/logic/fol/interpreter/ResolutionEngine.java
public void consultInputStream(InputStream stream) throws SourceCodeException
    {
        // Create a token source to read from the specified input stream.
        Source<Token> tokenSource = TokenSource.getTokenSourceForInputStream(stream);
        getParser().setTokenSource(tokenSource);

        // Consult the type checking rules and add them to the knowledge base.
        while (true)
        {
            Sentence<S> sentence = getParser().parse();

            if (sentence == null)
            {
                break;
            }

            getCompiler().compile(sentence);
        }
    }
public void consultInputStream(InputStream stream) throws SourceCodeException
    {
        // Create a token source to read from the specified input stream.
        Source<Token> tokenSource = TokenSource.getTokenSourceForInputStream(stream);
        getParser().setTokenSource(tokenSource);

        // Consult the type checking rules and add them to the knowledge base.
        while (true)
        {
            Sentence<S> sentence = getParser().parse();

            if (sentence == null)
            {
                break;
            }

            getCompiler().compile(sentence);
        }
    }
Consults an input stream, reading first order logic clauses from it, and inserting them into the resolvers
knowledge base.

@param  stream The input stream to consult.

@throws SourceCodeException If any code read from the input stream fails to parse, compile or link.