Added a type parameter to State