All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.legaldocml.akn.element.Foreign Maven / Gradle / Ivy

package io.legaldocml.akn.element;

import io.legaldocml.akn.group.BlockElements;
import io.legaldocml.io.impl.Buffers;
import io.legaldocml.io.XmlWriter;

import java.io.IOException;

/**
 * the element foreign is a generic container for elements not belonging to the Akoma Ntoso namespace (e.g.,
 * mathematical formulas). It is a block element and thus can be placed in a container.
 *
 * 
 *   <xsd:element name="preservation" type="anyOtherType"/>
 * 
 *
 * @author Jacques Militello
 */
public final class Foreign extends AnyOtherType implements BlockElements {

    /**
     * XML tag element name.
     */
    public static final String ELEMENT = "foreign";

    private static final long ADDRESS = Buffers.address(ELEMENT);

    /**
     * {@inheritDoc}
     */
    @Override
    public void write(XmlWriter writer) throws IOException {
        writer.writeStart(ADDRESS, 7);
        super.write(writer);
        writer.writeEnd(ADDRESS, 7);
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public String name() {
        return ELEMENT;
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy