/** * add the all value data which is indicate by target collection. * @param index the index * @param collection the collection * @return this \ */ public ListPropertyEditor<D, T> addAll(int index , Collection<? extends T> collection){ Throwables.checkNull(collection); if(!collection.isEmpty() && mList.addAll(index, collection)) { //dispatch if need. if (mMediator != null) { mMediator.dispatchAddValuesWithIndex(mProperty, mList, collection, index); } } return this; } /**
/** * add the all value data which is indicate by target collection. * @param index the index * @param collection the collection * @return this \ */ public ListPropertyEditor<D, T> addAll(int index , Collection<? extends T> collection){ Throwables.checkNull(collection); if(!collection.isEmpty() && mList.addAll(index, collection)) { //dispatch if need. if (mMediator != null) { mMediator.dispatchAddValuesWithIndex(mProperty, mList, collection, index); } } return this; } /**
/** * add a value to the target index. * @param index the index * @param t the value data. * @return this */ public ListPropertyEditor<D, T> add(int index ,T t){ Throwables.checkNull(t); mList.add(index, t); //dispatch if need. if(mMediator != null){ ensureTempNotNull(); mTemp.add(t); mMediator.dispatchAddValuesWithIndex(mProperty, mList, mTemp, index); mTemp.clear(); } return this; }
/** * add a value to the target index. * @param index the index * @param t the value data. * @return this */ public ListPropertyEditor<D, T> add(int index ,T t){ Throwables.checkNull(t); mList.add(index, t); //dispatch if need. if(mMediator != null){ ensureTempNotNull(); mTemp.add(t); mMediator.dispatchAddValuesWithIndex(mProperty, mList, mTemp, index); mTemp.clear(); } return this; }