Optimized '_SerializeConfig' method.