I have discussed with my colleague that how to delete an entry in the map, the map index and index indicator are integers For one object
I said, release the first object, and then delete the entry. My colleague said that first remove the entry and then leave the object.
So what's the best way? Any tricks for this question?
Unless you have a multi-threaded environment, the rule of thumb is that, After getting the return, any hanging indicator should not be left, that is, no signal to be removed from the object. Only one problem is that if you delete the first entry, you will need to make sure that there is a temporary copy of the indicator, since it is not recovered from the map after the entry is removed Will be able to do
Comments
Post a Comment