PathPacker-java/src/main/java/com/hashbangbash/trie/NodeContext.java
2012-10-03 21:40:17 -04:00

25 lines
422 B
Java

package com.hashbangbash.trie;
/*
* for nodes like the HuffNode, that need
* an external incrementor to the node id
*/
public class NodeContext {
private long nodeId = 0;
public NodeContext() {
}
public NodeContext(long startId) {
this.nodeId = startId;
}
public long getId() {
return this.nodeId;
}
public long nextId() {
return this.nodeId++;
}
}