private static DictionaryQueryModelDetails GetActionParameterDictionaryDetails(ActionParameter actionParam) { var key = nameof(DictionaryQueryModelDetails); var details = actionParam.GetAdditionalDataOrDefault <DictionaryQueryModelDetails>(key); if (details == null) { details = new DictionaryQueryModelDetails(actionParam.Type); actionParam.SetAdditionalData(key, details); } return(details); }
private CollectionsQueryModelParameterDetails GetDetailsForActionParameter(ActionParameter actionParam) { string key = nameof(CollectionsQueryModelParameterDetails); var value = actionParam.GetAdditionalDataOrDefault <CollectionsQueryModelParameterDetails>(key); if (value == null) { value = new CollectionsQueryModelParameterDetails(actionParam.Type); actionParam.SetAdditionalData(key, value); } return(value); }