private void flushWriter( JspWriter writerToFlush ) throws JspException,IOException {
if (getFacesContext() == null)
return;
BodyContent tempwriter;
_componentInstance = findComponent(_facesContext);
if (writerToFlush instanceof BodyContent)
{
int count = 0;
char [] readChars = new char[READ_LENGTH];
tempwriter = (BodyContent) writerToFlush;
Reader read =tempwriter.getReader();
count = read.read(readChars,0,READ_LENGTH);
String readString = new String(readChars,0,count);
if(!readString.trim().equals(""))
{
//_componentInstance = findComponent(_facesContext);
UIComponentTag parentTag = getParentUIComponentTag(pageContext);
addOutputComponentAfterComponent(parentTag,createUIOutputComponentFromString(readString),_componentInstance);
tempwriter.clearBody();
}
}
else
{