Let's say I have the following map definition:
std::map<string,Storage>
where the key is a string representation of an instance of the Storage class.
My question is that he stated that map :: find complexity is logarithmic in size, does string size affect performance?
The reason I have this map is because of quick access to an instance of the Storage class. However, if the string representation of the Storage classes is very large? Is there a maximum line size that, if exceeded, makes use of map redundant?
Notes
My intuition tells me that if the string representation of the Storage classes is very long, then comparing the classes themselves using operator== will also be expensive. Therefore, no matter how long the line is, I better use map
source share