public IExpressionBuilder addExpression ( ) { final IExpressionBuilder builder = this . expressionProvider . get ( ) ; builder . eInit ( getXBlockExpression ( ) , new Procedures . Procedure1 < XExpression > ( ) { private int index = - 1 ; public void apply ( XExpression it ) { if ( this . index >= 0 ) { getXBlockExpression ( ) . getExpressions ( ) . set ( index , it ) ; } else { getXBlockExpression ( ) . getExpressions ( ) . add ( it ) ; this . index = getXBlockExpression ( ) . getExpressions ( ) . size ( ) - 1 ; } } } , getTypeResolutionContext ( ) ) ; return builder ; }
Add an expression inside the block .