001    /*
002     * Created on Nov 27, 2006
003     *
004     * Copyright 2006 John G. Wilson
005     *
006     *   Licensed under the Apache License, Version 2.0 (the "License");
007     *   you may not use this file except in compliance with the License.
008     *   You may obtain a copy of the License at
009     *
010     *       http://www.apache.org/licenses/LICENSE-2.0
011     *
012     *   Unless required by applicable law or agreed to in writing, software
013     *   distributed under the License is distributed on an "AS IS" BASIS,
014     *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
015     *   See the License for the specific language governing permissions and
016     *   limitations under the License.
017     *
018     */
019    package groovy.util.slurpersupport;
020    
021    import groovy.lang.Buildable;
022    import groovy.lang.GroovyObject;
023    import groovy.lang.Writable;
024    
025    import java.io.IOException;
026    import java.io.Writer;
027    import java.util.Map;
028    
029    public abstract class ReplacementNode implements Buildable, Writable {
030        public abstract void build(GroovyObject builder, Map namespaceMap, Map namespaceTagHints);
031        
032        public void build(final GroovyObject builder) {
033            build(builder, null, null);
034        }
035        
036        public Writer writeTo(final Writer out) throws IOException {
037            return out;
038        }
039    }