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