Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.openfuxml.addon.wiki.processor.ofx.emitter;
 
 
 
public class NestingEmitter implements Emitter
	private Emitter next = null;
	private String elementName = null;
	private int nestLevel = 0;
	protected EmitterFactory ef;
	{
		this. = ef;
	}
	public void content(XMLStreamWriter writerchar[] chint startint lengththrows XMLStreamException
	{
		if ( != null) {.content(writerchstartlength);}
		else {localContent(writerchstartlength);}
	}
	public final boolean end(XMLStreamWriter writerString htmlElementNamethrows XMLStreamException {
		if ( > 0 &&  != null) {
			if (.end(writerhtmlElementName)) {
				 = null;
			}
			return false;
else {
			if ( != null) {
				 = null;
			}
			return localEnd(writerhtmlElementName);
		}
	}
	protected boolean localEnd(XMLStreamWriter writerString htmlElementNamethrows XMLStreamException {
		return true;
	}
	protected boolean localStart(XMLStreamWriter writerString htmlElementNameAttributes attsthrows XMLStreamException {
		return true;
	}
	protected void localContent(XMLStreamWriter writerchar[] chint startint lengththrows XMLStreamException {
		writer.writeCharacters(chstartlength);
	}
	public final boolean start(XMLStreamWriter writerString htmlElementNameAttributes attsthrows XMLStreamException {
		if ( == null) {
			 = htmlElementName;
			return localStart(writerhtmlElementNameatts);
else {
			if ( == null) {
				 = .getEmitter(htmlElementName);
			}
			if (!.start(writerhtmlElementNameatts)) {
				 = null;
					 = .getEmitter(htmlElementName);
					if (!.start(writerhtmlElementNameatts)) {
						throw new IllegalStateException();
					}
					return true;
else {
					return false;
				}
			}
			return true;
		}
	}
	protected boolean permitsMultipleNexting() {
		return true;
	}
	public void close() throws XMLStreamException {
		if ( != null) {
			 = null;
		}
	}
New to GrepCode? Check out our FAQ X