pushInput(name, text);
pushInput(name, text, !inAttr, normalize);
  private void expandEntity(String name, boolean inAttr)    throws IOException, XMLStreamException  {    if (doctype != null)      {        Object value = doctype.getEntity(name);        if (value != null)          {            if (xmlStandalone == Boolean.TRUE)              {                if (doctype.isEntityExternal(name))                  error("reference to external entity in standalone document");                else if (value instanceof ExternalIds)                  {                    ExternalIds ids = (ExternalIds) value;                    if (ids.notationName != null &&                        doctype.isNotationExternal(ids.notationName))                      error("reference to external notation in " +                            "standalone document");                  }              }            if (value instanceof String)              {                String text = (String) value;                if (inAttr && text.indexOf('<') != -1)                  error("< in attribute value");                pushInput(name, text);              }            else if (inAttr)              error("reference to external entity in attribute value", name);            else              pushInput(name, (ExternalIds) value);            if (name != null)              startEntityStack.addFirst(name);            return;          }      }    error("reference to undeclared entity", name);  }