Bug 121019 Java based scripting -> TextItemInstance/setText, getText does not work properly
textItemInstance.setText( "Actuate Shanghai" ); System.out.println( textItemInstance.getText( ) ); after executing the codes above, i got "text/template". expected behavior: - Actuate Shanghai actual behavior: - text/template
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/script/internal/ElementUtil.java
if ( element instanceof ImageContent )
			return new ImageInstance( ( ImageContent ) element );
		if ( element instanceof LabelContent )
			return new LabelInstance( ( LabelContent ) element );
		if ( element instanceof ContainerContent )
			return new ListInstance( ( ContainerContent ) element );
		if ( element instanceof RowContent )
			return new RowInstance( ( RowContent ) element );
		if ( element instanceof TableContent )
		{
			Object genBy = ( ( TableContent ) element ).getGenerateBy( );
			if ( genBy instanceof TableItemDesign )
				return new TableInstance( ( TableContent ) element );
			else if ( genBy instanceof GridItemDesign )
				return new GridInstance( ( TableContent ) element );
		}
		if ( element instanceof TextContent )
			return new TextItemInstance( ( TextContent ) element );
		if ( element instanceof ForeignContent )
		{
			ForeignContent fc = ( ForeignContent ) element;
			if ( IForeignContent.HTML_TYPE.equals( fc.getRawType( ) )
					|| IForeignContent.TEXT_TYPE.equals( fc.getRawType( ) )
					|| IForeignContent.TEMPLATE_TYPE.equals( fc.getRawType( ) ) )
				return new TextItemInstance( fc );
		}
		return null;
	}
	public static IDesignElement getElement( DesignElementHandle element )
	{