Added switch generator, last part for reader code generation.