Translation for Listiterator.Add ()

xiaoxiao2021-03-06  74

Add

Public Void Add (Object O)

Inserts the specified element into the list (optional operation). The element is inserted immediately before the next element that would be returned by next, if any, and after the next element that would be returned by previous, if any. (If the list contains no elements, the new element becomes the sole element on the list) The new element is inserted before the implicit cursor:. a subsequent call to next would be unaffected, and a subsequent call to previous would return the new element (This call. Increases by One The Value That Would Be Returned by a call to nextindex or prepviousIndex.)

Parameters:

O - the element to insert.

(Under the guidance of the best old wolf) I understand this: Insert the specified element into the list (this is a could have an unable action). This element is inserted between the elements returned by the prepiot and previous (if this List is empty, this is the only element.) This new element is inserted before the default location: Next () will not be affected, previous () Will return a new element. (This sentence is not good!!!)

转载请注明原文地址:https://www.9cbs.com/read-87051.html

New Post(0)