package yi.or.db;

public class Util
{
    //return String[2], String[0]:dirname,ending"/", String[1]:filename
    public static String[] fileNameSep(String fullname)
    {
        int index= fullname.lastIndexOf('/');
        String dirName, fileName;
        if (index>=0) {
            dirName=fullname.substring(0, index+1);
            fileName= fullname.substring(index+1, fullname.length());
        }
        else {
            fileName=fullname;
            dirName="";
        }
        String[] rst= {dirName,fileName};
        return rst;
    }

}