Node class for handling tree data from databases.