*/
package org.opendaylight.yangtools.yang.data.codec.gson;
-import java.io.Writer;
import java.net.URI;
+
/**
* The root node of a particular {@link JSONNormalizedNodeStreamWriter} instance.
* It holds the base namespace and can never be removed from the stack.
*/
-final class JSONStreamWriterRootContext extends JSONStreamWriterURIContext {
+abstract class JSONStreamWriterRootContext extends JSONStreamWriterURIContext {
+
JSONStreamWriterRootContext(final URI namespace) {
super(null, namespace);
}
- @Override
- protected void emitEnd(final Writer writer) {
- throw new IllegalArgumentException("Top-level node reached");
- }
}