/** * Inserts the specified element at the specified position in this list. Shifts the element currently at that * position (if any) and any subsequent elements to the right (adds one to their indices). * * @param index index of element to add * @param element element to be stored at the specified position */ public void add(int index, ElementType element) { super.add(index, element); indexElement(element); }
/** * Inserts the specified element at the specified position in this list. Shifts the element currently at that * position (if any) and any subsequent elements to the right (adds one to their indices). * * @param index index of element to add * @param element element to be stored at the specified position */ public void add(int index, ElementType element) { super.add(index, element); indexElement(element); }
/** * Indexes the given SAMLObject by type and element name. * * @param element the SAMLObject to index */ protected void indexElement(ElementType element) { if (element == null) { return; } QName type = element.getSchemaType(); if (type != null) { indexElement(type, element); } indexElement(element.getElementQName(), element); }
/** * Indexes the given SAMLObject by type and element name. * * @param element the SAMLObject to index */ protected void indexElement(ElementType element) { if (element == null) { return; } QName type = element.getSchemaType(); if (type != null) { indexElement(type, element); } indexElement(element.getElementQName(), element); }
/** * Replaces the element at the specified position in this list with the specified element. * * @param index index of element to replace * @param element element to be stored at the specified position * * @return the element previously at the specified position */ public ElementType set(int index, ElementType element) { ElementType returnValue = super.set(index, element); removeElementFromIndex(returnValue); indexElement(element); return returnValue; }
/** * Replaces the element at the specified position in this list with the specified element. * * @param index index of element to replace * @param element element to be stored at the specified position * * @return the element previously at the specified position */ public ElementType set(int index, ElementType element) { ElementType returnValue = super.set(index, element); removeElementFromIndex(returnValue); indexElement(element); return returnValue; }