keyvaluepair Questions
3
Solved
I'm very new with JSON, please help!
I am trying to serialise a List<KeyValuePair<string, string>> as JSON
Currently:
[{"Key":"MyKey 1","Value":"MyValue 1"},{"Key":"MyKey 2","Value":...
Boccie asked 6/1, 2017 at 9:51
2
Solved
I have an IEnumerable<Entityclass> for an entity that has a string and an int member. i need to convert it to an array of KeyValuePair<string, double> and vice versa.
It fails with a c...
Calcariferous asked 17/8, 2013 at 3:26
4
Solved
I'm trying to load a list of KeyValuePairs from an EF / Linq query like this:
return (from o in context.myTable
select new KeyValuePair<int, string>(o.columnA, o.columnB)).ToList();
My p...
Seduction asked 25/6, 2013 at 15:53
9
Solved
I am trying to create an unordered_map to map pairs with integers:
#include <unordered_map>
using namespace std;
using Vote = pair<string, string>;
using Unordered_map = unordered_map...
Ivie asked 20/9, 2015 at 23:56
5
Solved
I have a ComboBox filled with mixed items of two different types. The types are either
KeyValuePair<Int32, FontFamily>
or
KeyValuePair<Int32, String>
Now there are occasions where...
Bunting asked 25/9, 2015 at 12:6
3
Solved
What is the necessity to introduce Pair class when Hashmap can do the same job?
I see Pair being introduced to Java version 8
Seedling asked 30/7, 2017 at 4:21
4
Solved
I am having
Dictionary<String, List<String>> filters = new Dictionary<String, List<String>>();
which is having values like country = us. till now I am able to add it whe...
Omsk asked 7/9, 2015 at 13:41
3
This is my requirement to have parameters in Jenkins:
1. User selects 3 Values from Dropdown: DEV, QA, PROD
2. Upon selection I need to return single value as parameter as like this:
If DEV selec...
Mezzo asked 18/4, 2016 at 2:23
1
I am trying to change the value of Keys in my dictionary as follows:
//This part loads the data in the iterator
List<Recommendations> iterator = LoadBooks().ToList();
//This part adds the da...
Burnsed asked 19/1, 2019 at 3:57
3
Solved
I have this following list:
var myList = new List<KeyValuePair<string, object>>();
And this function:
public void Test(params KeyValuePair<string, object>[] list)
How can I ...
Shuck asked 21/3, 2017 at 9:50
3
Solved
I have some pairs cw (Integer i, String word) with i number of occurences of word in a text file.
I would like to simply have for each pair a new pair c1 (Integer i, 1) with 1 fixed number.
It s...
Aribold asked 9/12, 2016 at 11:5
5
Solved
My requirement is to store key-value pairs in a data structure and fetch or delete the pairs when necessary using keys in JavaScript.
How can I do it in JavaScript as one does it in Java?
I have ...
Sudduth asked 16/12, 2014 at 18:11
5
In JavaScript functions are first-class objects, that means you can treat them just like any object, in this case, you are only adding a property to the function object.
Ok, let's add some propert...
Surmount asked 24/3, 2018 at 9:30
1
Solved
I'm trying to explore the Algorithmia image taggers in python.
client.algo("deeplearning/IllustrationTagger/0.2.5")
client.algo("deeplearning/InceptionNet/1.0.3")
But that's not quite rele...
Contemplation asked 18/12, 2017 at 16:40
7
Solved
Given a list:
private List<KeyValuePair<string, string>> KV_List = new List<KeyValuePair<string, string>>();
void initList()
{
KV_List.Add(new KeyValuePair<string, ...
Clinkerbuilt asked 14/7, 2015 at 18:24
7
Solved
I'm using a Dictionary<int, KeyValuePair<bool, int>> to hold data.
From time to time I need to increment the int in the KeyValuePair, but it won't let me, because it has no setter. Is...
Institute asked 14/5, 2012 at 8:44
1
Solved
I am developing an ASP.Net Web API project. In my project, I am trying to return JSON from action in this format.
{
"Apple": null,
"Microsoft": null,
"Google": 'htt...
Estrella asked 11/12, 2016 at 15:27
3
Solved
I was going to use KeyValuePair in a comparison-intensive code and was perplexed checking how it is implemented in .NET (s. below)
Why does it not override Equals and GetHashCode for efficiency (a...
Haroldson asked 7/7, 2016 at 16:19
2
Solved
If I had an array as such:
var myarray = [];
myarray.push({
"Name": 'Adam',
"Age": 33
});
myarray.push({
"Name": 'Emily',
"Age": 32
});
This gives me an array where I can pull out values l...
Tnt asked 20/5, 2014 at 19:25
3
I am a bit confused with the term, a byte offset value, which is treated as map key in Hadoop Map reduce program.
First, what is the byte offset value?
Second, how is it generated, and how does ...
Tamper asked 3/4, 2014 at 12:51
2
Solved
I'm trying to figure out the best way to combine two lists of the same size into a map of key value pairs.
I've been using the same function to handle this case for a while for CSVs and raw SQL qu...
Pinero asked 31/12, 2015 at 15:31
2
Solved
I have been learning Spark for several weeks, currently I am trying to group several items or people based on their connection using Spark and Hadoop in Scala. For example, I want to see how footba...
Lenny asked 18/10, 2015 at 15:59
3
Solved
I am new to Ruby. I'm going through a tutorial on Rubymonk and am just learning how to create hashes. Can you tell me why I can't create a hash without the key_value_pairs variable. It seems logica...
Aesthetics asked 18/7, 2015 at 12:37
1
Solved
I'm in the process of converting my chart application from preset data to using a database.
Previously I was using this:
var data = new Dictionary<string, double>();
switch (graphselected...
Dysart asked 28/8, 2014 at 16:31
2
Solved
I have the following list and I need to run a Contains() or similar method on it to retrieve the value associated with a specific key. How would I do this? I've searched everywhere and tried many t...
Exultation asked 14/8, 2014 at 1:13
1 Next >
© 2022 - 2025 — McMap. All rights reserved.