Java tutorial
//package com.java2s; import android.content.Context; import java.io.File; public class Main { private static final String API_CACHE = "api-cache"; static File createApiCacheDir(Context context) { File cache = new File(context.getApplicationContext().getCacheDir(), API_CACHE); if (!cache.exists()) { cache.mkdirs(); } return cache; } }