setup view type handling if (config.isolateViewTypes) { mViewTypeStorage = new ViewTypeStorage.IsolatedViewTypeStorage(); } else { mViewTypeStorage = new ViewTypeStorage.SharedIdRangeViewTypeStorage(); } // setup stable id handling mStableIdMode = config.stableIdMode; if (config.stableIdMode == NO_STABLE_IDS) { mStableIdStorage = new StableIdStorage.NoStableIdStorage(); } else if (config.stableIdMode == ISOLATED_STABLE_IDS) { mStableIdStorage = new StableIdStorage.IsolatedStableIdStorage(); } else if (config.stableIdMode == SHARED_STABLE_IDS) { mStableIdStorage = new StableIdStorage.SharedPoolStableIdStorage(); } else { throw new IllegalArgumentException("unknown stable id mode"); } }