void (Object parent, Object key, Object component, int index) { Object target = get(parent, key); if (index == -1) { while (target != null) { target = get(parent = target, key = ":next"); } } else { for (int i = 0; i < index; i++) { target = get(parent = target, key = ":next"); } set(component, ":next", get(parent, key)); } set(parent, key, component); }