Interface Node<V>
- Type Parameters:
V- the vertex value type | 顶点值类型
public interface Node<V>
Node Interface
节点接口
Interface for graph nodes with value accessor.
带值访问器的图节点接口。
Features | 主要功能:
- Simple value-holding node abstraction - 简单的值持有节点抽象
- Factory method for easy creation - 便捷创建的工厂方法
Usage Examples | 使用示例:
Node<String> node = new SimpleNode<>("A");
String value = node.getValue();
Security | 安全性:
- Thread-safe: Yes (immutable implementations) - 线程安全: 是(不可变实现)
- Null-safe: No (accepts null values) - 空值安全: 否(接受null值)
- Since:
- JDK 25, opencode-base-graph V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
- See Also:
-
Method Summary
-
Method Details
-
getValue
-
of
Create a simple node with the given value 使用给定值创建简单节点- Type Parameters:
V- the value type | 值类型- Parameters:
value- the value | 值- Returns:
- the node | 节点
-