* Remove unused method of IModelMetadataProvider

* Fix warning in CollectionModelBinder
This commit is contained in:
Pranav K 2014-02-24 17:59:29 -08:00
parent b6c78de4ea
commit f1183f57af
3 changed files with 1 additions and 15 deletions

View File

@ -165,7 +165,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
return new[] { rawValue };
}
internal static void CreateOrReplaceCollection<TElement>(ModelBindingContext bindingContext,
internal static void CreateOrReplaceCollection(ModelBindingContext bindingContext,
IEnumerable<TElement> incomingElements,
Func<ICollection<TElement>> creator)
{

View File

@ -56,17 +56,6 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
return CreateMetadataFromPrototype(prototype, modelAccessor);
}
public ModelMetadata GetMetadataForParameter(ParameterInfo parameter)
{
if (parameter == null)
{
throw Error.ArgumentNull("parameter");
}
TModelMetadata prototype = GetTypeInformation(parameter.ParameterType, parameter.GetCustomAttributes()).Prototype;
return CreateMetadataFromPrototype(prototype, modelAccessor: null);
}
// Override for creating the prototype metadata (without the accessor)
protected abstract TModelMetadata CreateMetadataPrototype(IEnumerable<Attribute> attributes,
Type containerType,

View File

@ -1,6 +1,5 @@
using System;
using System.Collections.Generic;
using System.Reflection;
namespace Microsoft.AspNet.Mvc.ModelBinding
{
@ -11,7 +10,5 @@ namespace Microsoft.AspNet.Mvc.ModelBinding
ModelMetadata GetMetadataForProperty(Func<object> modelAccessor, Type containerType, string propertyName);
ModelMetadata GetMetadataForType(Func<object> modelAccessor, Type modelType);
ModelMetadata GetMetadataForParameter(ParameterInfo parameterInfo);
}
}