/** * Creates a new Property Group object, sets its name, and fires the add group method that takes a * group object as a first argument. This method makes other methods easier to read and * understand. * * @param ofName The name of the group to be created * @param to The parent group the new group will be added to */ private void _addGroup(String ofName, PropertyGroup to) { PropertyGroup group = new PropertyGroup(); group.setName(ofName); recent = group; _addGroup(group, to); }
/** * Creates a new Property Pool object and performs the initial set up. * * <p>The initial set up consists of instantiating the history stack, creating a new Property * Group object to be used as the parent group, and then pushing this new group to the top of the * currently empty history stack. * * <p>This ensures that any added base-level Property Groups will not be met with an empty history * stack and no parent to attach themselves to. */ public PropertyPool() { history = new Stack<PropertyGroup>(); parent = new PropertyGroup(); parent.setName("parent"); history.push(parent); }