public static void ConfigureProtoServices(HttpConfiguration config, ProtoBufConfig protoBufConfig)
        {
            if (protoBufConfig == null)
                throw new ArgumentNullException("protoBufConfig");

            if (config == null)
                throw new ArgumentNullException("config");

            config.Routes.MapHttpRoute(
                name: "protobuf.services.routes.metadata",
                routeTemplate: GetPath(protoBufConfig.PathPrefix),
                defaults: null,
                constraints: null,
                handler: new MetaDataHttpHandler()
            );

            config.Formatters.Add(new ProtoBufMediaTypeFormatter());

            EncryptionManager.EncryptionKey = protoBufConfig.EncryptionKey;
        }
        public static void ConfigureProtoServices(HttpConfiguration config, ProtoBufConfig protoBufConfig)
        {
            if (protoBufConfig == null)
            {
                throw new ArgumentNullException("protoBufConfig");
            }

            if (config == null)
            {
                throw new ArgumentNullException("config");
            }

            config.Routes.MapHttpRoute(
                name: "protobuf.services.routes.metadata",
                routeTemplate: GetPath(protoBufConfig.PathPrefix),
                defaults: null,
                constraints: null,
                handler: new MetaDataHttpHandler()
                );

            config.Formatters.Add(new ProtoBufMediaTypeFormatter());

            EncryptionManager.EncryptionKey = protoBufConfig.EncryptionKey;
        }