Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import java.io.File;
import java.util.ArrayList;
import java.util.List;

public class Main {

    public static List<String> getAllSkinZipFiles(String path) {
        List<String> zipFiles = new ArrayList<String>();
        File file = new File(path);
        if (file.exists()) {
            File[] files = file.listFiles();
            if (files.length > 0) {
                for (File f : files) {
                    if (f.getName().startsWith("skin") && f.getName().endsWith("zip")) {
                        zipFiles.add(f.getAbsolutePath());
                    }
                }
            }
        }
        return zipFiles;
    }
}