Mapa mental
List ADT
Conteúdo do mapa
List ADT
Index-based methods
- size()
- isEmpty()
- get(i)
- set(i,e)
- add(i,e)
- remove(i)
ArrayList: unbounded list
- dynamic array: abstraction to allow user to add elements to the list with the ArrayList class
Positional Lists
- getElement(): Returns the element stored at this position
- accessor methods
- first()
- last()
- before(p)
- after(p)
- isEmpty()
- size()
- update methods
- addFirst(e)
- addLast()
- addBefore(p,e)
- addAfter(p,e)
- set(p,e)
- remove(p)
Iterators
- software design pattern that abstracts the process of scanning through a sequence of elements, one element at a time.
- java.util.Iterador
- hasNext()
- next()
- remove()
- java.util.ListIterator
- add(e)
- hasNext()
- hasPrevious()
- previous()
- next()
- nextIndex()
- previousIndex()
- remove()
- set(e)
- java.util.Iterador
- software design pattern that abstracts the process of scanning through a sequence of elements, one element at a time.
Convert List into Array
- toArray()
- toArray(A)
Convert Array into List
- asList(A)
Informações
- Descrição
- Mapa Mental sobre List ADT, criado por Angelica Cordero em 16-05-2022.
- Criado por
- Angelica Cordero
- Visualizações
- 1
- Avaliação