State-Based Programming in PQL - Bernardino, Ricardo Jorge Rocha (2014)