示例#1
0
            /// <summary>
            /// This API supports infrastructure and is not intended to be used
            /// directly from your code. This API may change or be removed in future releases.
            /// </summary>
            public void Append(string key, string value)
            {
                if (_accumulator is null)
                {
                    _accumulator = new AdaptiveCapacityDictionary <string, StringValues>(StringComparer.OrdinalIgnoreCase);
                }

                if (!_accumulator.TryGetValue(key, out var values))
                {
                    // First value for this key
                    _accumulator[key] = new StringValues(value);
                }
                else
                {
                    AppendToExpandingAccumulator(key, value, values);
                }

                ValueCount++;
            }
示例#2
0
 public void OneValue_SmallDict_Get()
 {
     _smallCapDict.TryGetValue("test", out var val);
 }