void addToOutputVar ( PyExpr pyExpr ) { boolean isList = pyExpr instanceof PyListExpr ; if ( isList && ! getOutputVarIsInited ( ) ) { appendLine ( getOutputVarName ( ) , " = " , pyExpr . getText ( ) ) ; } else { initOutputVarIfNecessary ( ) ; String function = isList ? ".extend(" : ".append(" ; appendLine ( getOutputVarName ( ) , function , pyExpr . getText ( ) , ")" ) ; } setOutputVarInited ( ) ; }
Add a single PyExpr object to the output variable .