public CAS process(String text) {
        CAS cas = retrieve();
        if (cas == null)
            return null;

        cas.setDocumentText(text);
        try {
            analysisEngine.process(cas);
        } catch (AnalysisEngineProcessException e) {
            log.warn("Unable to process text " + text, e);
        }

        return cas;


    }
public CAS process ( String text ) { CAS cas = retrieve ( ) ; if ( cas == null ) return null ; cas . setDocumentText ( text ) ; try { analysisEngine . process ( cas ) ; } catch ( AnalysisEngineProcessException e ) { log . warn ( "Unable to process text " + text , e ) ; } return cas ; }
Use the given analysis engine and process the given text
You must release the return cas yourself
@param text the text to process
@return the processed cas