Added a factory for variables.