class MetadataXpp3Writer {

    private final MetadataStaxWriter delegate;

    /**
     * Default constructor
     */
    public MetadataXpp3Writer() {
        delegate = new MetadataStaxWriter();
    }

    /**
     * Method setFileComment.
     *
     * @param fileComment a fileComment object.
     */
    public void setFileComment(String fileComment) {
        delegate.setFileComment(fileComment);
    }

    /**
     * Method write.
     *
     * @param writer   a writer object
     * @param metadata a Metadata object
     * @throws java.io.IOException java.io.IOException if any
     */
    public void write(Writer writer, Metadata metadata) throws java.io.IOException {
        try {
            delegate.write(writer, metadata.getDelegate());
        } catch (XMLStreamException e) {
            throw new IOException(e);
        }
    }

    /**
     * Method write.
     *
     * @param stream a stream object
     * @param metadata a Metadata object
     * @throws java.io.IOException java.io.IOException if any
     */
    public void write(OutputStream stream, Metadata metadata) throws java.io.IOException {<FILL_FUNCTION_BODY>}
}

        try {
            delegate.write(stream, metadata.getDelegate());
        } catch (XMLStreamException e) {
            throw new IOException(e);
        }
    
<no_super_class>