X-Git-Url: http://git.nikiroo.be/?p=jvcard.git;a=blobdiff_plain;f=src%2Fbe%2Fnikiroo%2Fjvcard%2FBaseClass.java;h=026c5b43c0951a02ceb69e3bbda049be4303945c;hp=26863902e59c8ec1447bbc44b9e1006b60843b5e;hb=aecb3399b756d2ba04223bc6f553999fce73f9fb;hpb=0b6140e4a200c4952c9dc003d8389f375191564e diff --git a/src/be/nikiroo/jvcard/BaseClass.java b/src/be/nikiroo/jvcard/BaseClass.java index 2686390..026c5b4 100644 --- a/src/be/nikiroo/jvcard/BaseClass.java +++ b/src/be/nikiroo/jvcard/BaseClass.java @@ -1,5 +1,6 @@ package be.nikiroo.jvcard; +import java.security.InvalidParameterException; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; @@ -9,19 +10,24 @@ import java.util.LinkedList; import java.util.List; import java.util.ListIterator; -import be.nikiroo.jvcard.tui.StringUtils; +import be.nikiroo.jvcard.resources.StringUtils; /** * This class is basically a List with a parent and a "dirty" state check. It * sends all commands down to the initial list, but will mark itself and its * children as dirty or not when needed. * - * All child elements can identify their parent. + *

+ * All child elements can identify their parent, and must not be added to 2 + * different objects without without first being removed from the previous one. + *

* + *

* The dirty state is bubbling up (when dirty = true) or down (when dirty = * false) -- so, making changes to a child element will also mark its parent as * "dirty", and marking an element as pristine will also affect all its child * elements. + *

* * @author niki * @@ -119,8 +125,8 @@ public abstract class BaseClass> implements List { * If not equals, the differences will be represented by the given * {@link List}s if they are not NULL. *