Java String Divide div(String content, String extra)

Here you can find the source of div(String content, String extra)

Description

_more_

License

Open Source License

Parameter

Parameter Description
content _more_
extra _more_

Return

_more_

Declaration

public static String div(String content, String extra) 

Method Source Code

//package com.java2s;
/*/*from  w ww .j  a v a2 s . c  o  m*/
 * Copyright 1997-2016 Unidata Program Center/University Corporation for Atmospheric Research
 * Copyright 2010-2015 Jeff McWhirter
 * 
 * This library is free software; you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation; either version 2.1 of the License, or (at
 * your option) any later version.
 * 
 * This library is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser
 * General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public License
 * along with this library; if not, write to the Free Software Foundation,
 * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 * 
 */

public class Main {
    /** _more_ */
    public static final String TAG_DIV = "div";

    /**
     * _more_
     *
     * @param content _more_
     * @param extra _more_
     *
     * @return _more_
     */
    public static String div(String content, String extra) {
        return tag(TAG_DIV, extra, content);
    }

    /**
     * _more_
     *
     * @param comp _more_
     *
     * @return _more_
     */
    public static String tag(String comp) {
        return "<" + comp + "/>";
    }

    /**
     * _more_
     *
     * @param comp _more_
     * @param attrs _more_
     *
     * @return _more_
     */
    public static String tag(String comp, String attrs) {
        return "<" + comp + attrs + "/>";
    }

    /**
     * _more_
     *
     * @param tag _more_
     * @param attrs _more_
     * @param inner _more_
     *
     * @return _more_
     */
    public static String tag(String tag, String attrs, String inner) {
        return open(tag, attrs) + inner + close(tag);
    }

    /**
     * _more_
     *
     * @param comp _more_
     *
     * @return _more_
     */
    public static String open(String comp) {
        return "<" + comp + ">";
    }

    /**
     * _more_
     *
     * @param comp _more_
     * @param attrs _more_
     *
     * @return _more_
     */
    public static String open(String comp, String attrs) {
        return "<" + comp + attrs + ">";
    }

    /**
     * _more_
     *
     * @param comp _more_
     *
     * @return _more_
     */
    public static String close(String comp) {
        return "</" + comp + ">";
    }
}

Related

  1. div(String second, String first)
  2. div(String text)
  3. divide(final String s)
  4. divide(Object o1, Object o2, String type)