Go Down

Topic: [Published on GitHub] LinkedList Class (Fully implemented) (Read 360 times) previous topic - next topic

Hi folks,

I have published my LinkedList Class on GitHub. It's REALLY usefull for all kinds of libraries and projects.

Features that are implemented:

  • LinkedList<T>::LinkedList() - Constructor.

  • LinkedList<T>::~LinkedList() - Destructor. Clear Nodes to minimize memory.

  • int LinkedList<T>::size() - Returns the current size of the list.

  • bool LinkedList<T>::add(T) - Add element T at the END of the list.

  • bool LinkedList<T>::add(int index, T) - Add element T at index of the list.

  • bool LinkedList<T>::unshift(T) - Add element T at the BEGINNING of the list.

  • bool LinkedList<T>::set(int index, T) - Set the element at index to T.

  • T LinkedList<T>::remove(int index) - Remove element at index. Return the removed element.

  • T LinkedList<T>::pop() - Remove the LAST element. Return the removed element.

  • T LinkedList<T>::shift() - Remove the FIRST element. Return the removed element.

  • T LinkedList<T>::get(int index) - Return the element at index.

  • void LinkedList<T>::clear() - Removes all elements.



For more information, and Latest releases go to https://github.com/ivanseidel/LinkedList

Fell free to commit new changes and use it.

Ivan
Arduino DueTimer | https://github.com/ivanseidel/DueTimer
Arduino Thread | https://github.com/ivanseidel/ArduinoThread

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy