Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

public class Main {
    public static String[] parseString(String raw, String split) {
        if (null == raw || 0 == raw.length()) {
            return null;
        }
        String[] names = raw.split(",");
        String[] newNames = new String[names.length];
        int i = 0;
        for (String name : names) {
            newNames[i++] = name.trim();
        }
        return newNames;
    }
}