[SERVER-7020] How to Clear BSONObj class object without destroying it Created: 12/Sep/12 Updated: 15/Feb/13 Resolved: 18/Sep/12 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Internal Client |
| Affects Version/s: | 2.2.0 |
| Fix Version/s: | None |
| Type: | Question | Priority: | Major - P3 |
| Reporter: | Shripad Bhargave | Assignee: | Randolph Tan |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Linux |
||
| Participants: |
| Description |
|
Hi Team WE are using MONGODB as our data base. we need to resume the BSONObje class object without destroing it. like we are looking for api to clear all containts of BSONObj class object to make it empty. Can you please provide more information on how it can be do that !! Your response is appriceated. Thanks Shripad |
| Comments |
| Comment by Randolph Tan [ 13/Sep/12 ] |
|
I am not quite sure I understand what you are trying to do, but you can use the BSONObjBuilder class (http://www.mongodb.org/pages/viewpage.action?pageId=133415#C++Tutorial-BSON) to create BSON objects dynamically. If that's not what you need, can you give more details on what you are planning to do, for example a pseudo code? |