/
NikolayIvkin
/
TheAlgorithms
Обзор
Документация
Войти
/
NikolayIvkin
/
TheAlgorithms
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
src/main/java/com/thealgorithms/devutils/nodes/Node.java
42 строки
804 B
acbin
style: format code (#4212)
09 июн 2023, 13:52
Не верифицирован
09 июн 2023, 13:52
00282ef
Код
Авторство
О чём код?
package com.thealgorithms.devutils.nodes; /** * Base class for any node implementation which contains a generic type * variable. * * All known subclasses: {@link TreeNode}, {@link SimpleNode}. * * @param <E> The type of the data held in the Node. * * @author <a href="https://github.com/aitorfi">aitorfi</a> */ public abstract class Node<E> { /** * Generic type data stored in the Node. */ private E data; /** * Empty constructor. */ public Node() { } /** * Initializes the Nodes' data. * * @param data Value to which data will be initialized. */ public Node(E data) { this.data = data; } public E getData() { return data; } public void setData(E data) { this.data = data; } }