Code example for ArrayBlockingQueue

0
		setupResource(); 
	} 
	 
	private void setupResource() { 
		mCacher = new Cache(getApplicationContext());
		mThreadPoolExecutor = new ThreadPoolExecutor(10, 20, 10, TimeUnit.SECONDS, new ArrayBlockingQueue <Runnable>(100) );
		mAPIClient = new RCAPIClient(getApplicationContext(), new JSONParser(), mThreadPoolExecutor, mCacher);
		mImgLoader = new BitmapAsyncLoader(new AsyncLoaderEngine(getApplicationContext(), mThreadPoolExecutor, mCacher));
	} 
	 
	public RCAPIClient getAPIClient() { 
		return this.mAPIClient;
	} 
	 
	public BitmapAsyncLoader getImgLoader() { 
		return this.mImgLoader;
	} 
	 
	private SharedPreferences getPreference() {
		if(mPrefs == null) {
			mPrefs = getSharedPreferences(Preferences.PREFERENCE_APP, MODE_PRIVATE);