protected void insert(Path.Item item) throws IOException {
		if (item.id().parent() != id) {
			throw new IllegalArgumentException(
					"Cannot insert with incorrect Path.Item (" + item.id() + ") into AbstractFolder (" + id + ")");
		}
		updateContents();
		//
		Path.ID id = item.id();
		int index = binarySearch(contents, nentries, id);

		if (index < 0) {
			index = -index - 1; // calculate insertion point
		} else {
			// indicates already an entry with a different content type
		}
		// Insert item at given index
		insert(index,item);
	}
protected void insert(Path.Item item) throws IOException {
		if (item.id().parent() != id) {
			throw new IllegalArgumentException(
					"Cannot insert with incorrect Path.Item (" + item.id() + ") into AbstractFolder (" + id + ")");
		}
		updateContents();
		
		Path.ID id = item.id();
		int index = binarySearch(contents, nentries, id);

		if (index < 0) {
			index = -index - 1; 
		} else {
			
		}
		
		insert(index,item);
	}
protected void insert ( Path . Item item ) throws IOException { if ( item . id ( ) . parent ( ) != id ) { throw new IllegalArgumentException ( "Cannot insert with incorrect Path.Item (" + item . id ( ) + ") into AbstractFolder (" + id + ")" ) ; } updateContents ( ) ; // Path . ID id = item . id ( ) ; int index = binarySearch ( contents , nentries , id ) ; if ( index < 0 ) { index = - index - 1 ; // calculate insertion point } else { // indicates already an entry with a different content type } // Insert item at given index insert ( index , item ) ; }
Insert a newly created item into this folder. Observe we assume
<code>entry.id().parent() == id</code>.

@param item
Insert a newly created item into this folder . Observe we assume <code > entry . id () . parent () == id< / code > .