added state and node classes