sinpeople Messages: 29 Registered: October 2020 Location: Singapore
Promising Member
Hi folks,
I have a collection of objects in the system. Each object has a name, which is a string. I'd like to have a collection of associations, which maps a string to an object. From the UDP or TCP socket, program will receive a string which contains the object name, I will then use the object name to index the object without long switch/if statement, and pass the rest of the input string as function call arguments?
I am a newbie. In this case, what kind of collections of associations to be used?