Code example for SparseArray

Methods: clear

0
    } 
 
    @Override 
    public void notifyDataSetChanged() { 
        super.notifyDataSetChanged(); 
        mPosToFragRef.clear();
    } 
 
    protected String getTitleForPosition(int pos) {
        final YearAndMonth ym = getYearAndMonthForPosition(pos);
 
        mTime.set(1, ym.month, ym.year);
        return mTime.format("%b %Y");
    } 
 
    public void selectJulianDay(int pos, int jd) {
        WeakReference<MonthFragment> fragRes = mPosToFragRef.get(pos);
        MonthFragment frag = fragRes == null ? null : fragRes.get();
 
        if(frag != null) {
Experience pair programming with AI  Get Codota for Java