Java List Create createSymbolNameString_From_Parts(List descTagName_Parts)

Here you can find the source of createSymbolNameString_From_Parts(List descTagName_Parts)

Description

create Symbol Name Strin Fro Parts

License

Open Source License

Declaration

public static String createSymbolNameString_From_Parts(List<String> descTagName_Parts) 

Method Source Code


//package com.java2s;
/* Copyright 2012, 2013 Unconventional Thinking
 *
 * This file is part of Hierarchy./*  w  ww  .j av a  2s .  c  o m*/
 *
 * Hierarchy is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License 
 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
 *
 * Hierarchy 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 General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with Hierarchy.  
 * If not, see <http://www.gnu.org/licenses/>.
 */

import java.util.*;

public class Main {
    public static String createSymbolNameString_From_Parts(List<String> descTagName_Parts) {

        if (descTagName_Parts == null)
            return null;

        StringBuffer descTagBuffer = new StringBuffer();

        boolean firstPart = true;
        for (String part : descTagName_Parts) {
            if (!firstPart)
                descTagBuffer.append(".");
            else
                firstPart = false;

            descTagBuffer.append(part);
        }

        return descTagBuffer.toString();
    }
}

Related

  1. createStringList(String csvString)
  2. createStringList(String spaceDelimitedString)
  3. createStringListFromStringArr(String[] stringArr)
  4. createSubList(Collection source, Class type)
  5. createSublist(final T[] elements, final Class listImplementation)
  6. createTable(List datas, String[] headers, int numColumns, int cellPadding, int border)
  7. createTagList(List tags, String separator)
  8. createTarget(List labels)
  9. createTargetSorted(List labels, Comparator comp)