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

sortpom.wrapper.Wrapper Maven / Gradle / Ivy

There is a newer version: 2.3.1
Show newest version
package sortpom.wrapper;

import org.jdom.Content;

/**
 * A wrapping of an xml fragment. The fragment might be an element or a comment etc.
 *
 * @param  *
 * @author Bjorn Ekryd
 */
public interface Wrapper {

    /**
     * Gets the wrapped content.
     *
     * @return the content
     */
    T getContent();

    /**
     * Checks if wrapper should be placed before another wrapper.
     *
     * @param wrapper the wrapper
     * @return true, if is before
     */
    boolean isBefore(Wrapper wrapper);

    /**
     * Checks if is content is of type Element.
     *
     * @return true, if is content element
     */
    boolean isContentElement();

    /**
     * Checks if wrapper should be sorted.
     *
     * @return true, if is resortable
     */
    boolean isResortable();

    /**
     * Output debug-friendly string
     *
     * @param indent The indentation indicates nested elements
     * @return The debug string
     */
    String toString(String indent);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy