Esempio n. 1
0
        public ServiceExport(WebServiceVerbs verbs)
        {
            if (verbs.HasFlag(WebServiceVerbs.Get))
            {
                throw new ArgumentException("Exports to the index path are not allowed for verb GET.");
            }

            mRoute = string.Empty;
            mVerbs = verbs;
        }
Esempio n. 2
0
        public ServiceExport([NotNull] string route, WebServiceVerbs verbs = WebServiceVerbs.All)
        {
            if (route.NormalizeNull() == null)
            {
                throw new ArgumentNullException(nameof(route));
            }

            mRoute = route;
            mVerbs = verbs;
        }
Esempio n. 3
0
        internal RouteInfo([NotNull] Type targetType, [NotNull] MethodBase targetMethod, WebServiceVerbs verbs, string route)
        {
            if (targetType == null)
            {
                throw new ArgumentNullException(nameof(targetType));
            }
            if (targetMethod == null)
            {
                throw new ArgumentNullException(nameof(targetMethod));
            }

            mTargetType   = targetType;
            mTargetMethod = targetMethod;

            AllowedVerbs = verbs;
            Route        = route;
        }