Annotation driven Java state machine