- /**
- * Return the number of {@link Data} present in this {@link Contact}.
- *
- * @return the number of {@link Data}s
- */
- public int size() {
- return datas.size();
- }
-
- /**
- * Return the {@link Data} at index <i>index</i>.
- *
- * @param index
- * the index of the {@link Data} to find
- *
- * @return the {@link Data}
- *
- * @throws IndexOutOfBoundsException
- * if the index is < 0 or >= {@link Contact#size()}
- */
- public Data get(int index) {
- return datas.get(index);
- }
-
- /**
- * Add a new {@link Data} in this {@link Contact}.
- *
- * @param data
- * the new data
- */
- public void add(Data data) {
- data.setParent(this);
- data.setDirty();
- datas.add(data);
- }
-
- /**
- * Remove the given {@link Data} from its this {@link Contact} if it is in.
- *
- * @return TRUE in case of success
- */
- public boolean remove(Data data) {
- if (datas.remove(data)) {
- setDirty();
- return true;
- }
-
- return false;
- }
-