public static GetSpecNames ( string xref, string supportedLanguages, SortedList |
||
xref | string | |
supportedLanguages | string | |
specs | SortedList |
|
return | List |
public static List <ApiLanguageValuePair> GetSpec(string key, Dictionary <string, ApiReferenceBuildOutput> references, string[] supportedLanguages) { if (string.IsNullOrEmpty(key)) { return(null); } if (!references.TryGetValue(key, out ApiReferenceBuildOutput reference)) { return(ApiReferenceBuildOutput.GetSpecNames(GetXref(key), supportedLanguages)); } else { return(reference.Spec); } }
public static ApiReferenceBuildOutput GetReferenceViewModel(string key, Dictionary <string, ApiReferenceBuildOutput> references, string[] supportedLanguages) { if (string.IsNullOrEmpty(key)) { return(null); } if (!references.TryGetValue(key, out ApiReferenceBuildOutput arbo)) { arbo = new ApiReferenceBuildOutput { Spec = ApiReferenceBuildOutput.GetSpecNames(GetXref(key), supportedLanguages), }; } else { arbo.Expand(references, supportedLanguages); } return(arbo); }