Esempio n. 1
0
        private static void AppendMethod(IRouteDefinition route, ActionCallBase call, IEnumerable <PropertyInfo> properties, IEnumerable <Regex> ignore)
        {
            var part = RemovePattern(call.Method.Name, ignore);

            Append(route, properties, part);
            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());
            }
        }
Esempio n. 2
0
        public RoutedChain(IRouteDefinition route, Type inputType, Type resourceType) : this(route)
        {
            if (inputType != null)
            {
                route.ApplyInputType(inputType);
            }

            if (resourceType != null)
            {
                ResourceType(resourceType);
            }
        }
Esempio n. 3
0
        public static void Alter(IRouteDefinition route, ActionCall call, IConfigurationObserver observer)
        {
            var properties = call.HasInput
                                 ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                                 : new string[0];

            Alter(route, call.Method.Name, properties, text => observer.RecordCallStatus(call, text));

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());
            }
        }
Esempio n. 4
0
        public static void Alter(IRouteDefinition route, ActionCall call)
        {
            var properties = call.HasInput
                                 ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                                 : new string[0];

            Alter(route, call.Method.Name, properties, text => call.Trace(text));

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());
            }
        }
Esempio n. 5
0
        public static void Alter(IRouteDefinition route, ActionCall call, IConfigurationObserver observer)
        {
            var properties = call.HasInput
                                 ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                                 : new string[0];

            Alter(route, call.Method.Name, properties, text => observer.RecordCallStatus(call, text));

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());
            }
        }
Esempio n. 6
0
        public static void Alter(IRouteDefinition route, ActionCall call)
        {
            var properties = call.HasInput
                                 ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                                 : new string[0];

            Alter(route, call.Method.Name, properties, text => call.Trace(text));

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());
            }
        }
Esempio n. 7
0
        public static void Alter(IRouteDefinition route, ActionCall call)
        {
            var properties = call.HasInput
                ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                : new string[0];

            Alter(route, call.Method.Name, properties);

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());

                if (call.InputType().CanBeCastTo <ResourcePath>())
                {
                    ResourcePath.AddResourcePathInputs(route);
                }
            }
        }
Esempio n. 8
0
        public static void Alter(IRouteDefinition route, ActionCall call)
        {
            var properties = call.HasInput
                ? new TypeDescriptorCache().GetPropertiesFor(call.InputType()).Keys
                : new string[0];

            Alter(route, call.Method.Name, properties);

            if (call.HasInput)
            {
                route.ApplyInputType(call.InputType());

                if (call.InputType().CanBeCastTo<ResourcePath>())
                {

                     ResourcePath.AddResourcePathInputs(route);
                }
            }
        }
 private static void AppendMethod(IRouteDefinition route, ActionCallBase call, IEnumerable<PropertyInfo> properties, IEnumerable<Regex> ignore)
 {
     var part = RemovePattern(call.Method.Name, ignore);
     Append(route, properties, part);
     if (call.HasInput) route.ApplyInputType(call.InputType());
 }
Esempio n. 10
0
 public RoutedChain(IRouteDefinition route, Type inputType)
     : this(route)
 {
     if (inputType != null) route.ApplyInputType(inputType);
 }