#352 closed defect (fixed)
MgDuplicateObjectException is not thrown when inserting duplicated object using MgStringCollection:: Add() .
Reported by: | jessicacao | Owned by: | Tom Fukushima |
---|---|---|---|
Priority: | medium | Milestone: | 2.0 |
Component: | General | Version: | 2.0.0 |
Severity: | major | Keywords: | MgStringCollection::Add |
Cc: | Trevor Wekel | External ID: | 985046 |
Description
MgDuplicateObjectException is not thrown when inserting duplicated object using MgStringCollection:: Add() .
Step to recur:
- Construct a MgStringCollection and add a string object into it.
- Add the same string object using Add();
Sample code:
MgStringCollection strColl = new MgStringCollection();
string str1 = "string1";
strColl.Add(str1);
MgDuplicateObjectException expected
strColl.Add(str1);
Expect result: MgDuplicateObjectException
Actual result: No exception thrown
Change History (2)
comment:1 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:2 by , 17 years ago
Version: | → 2.0.0 |
---|
Note:
See TracTickets
for help on using tickets.
Actually the documentation is incorrect. MgStringCollection allows duplicates and so the MgDuplicateObjectException should not be thrown.
I have updated the comments in the header file: r2550.