Andreas,
I'm sure glad you wrote that code.  It would have taken me a whole lot
longer to figure it out :)  I tried this function in my app today and
it seems to work fine.  I used some really big, nasty models too. 
Can't wait to see it show up in the daily builds.  Thanks for all the
help with this.  I owe you a beer.
- Terry

On 1/20/06, Andreas Zieringer <[EMAIL PROTECTED]> wrote:
> Hi Terry,
>
> I attached a working example which creates a changelist from the current
> state. To skip the prototypes I added the start parameter this should be
> the first FieldContainerPtr you created in your app. I will add this
> method to the RemoteAspect class. This works fine for apps which use
> only one aspect I'm not sure what happens with more than one aspect.
>
> Andreas
>
> static void createCurrentStateChangeList(const FieldContainerPtr &start,
> ChangeList *cl)
> {
>       cl->clearAll();
>       const std::vector<FieldContainerPtr> &fcs =
> *FieldContainerFactory::the()->getFieldContainerStore();
>
>       bool found_start = false;
>       for(unsigned int i=0;i<fcs.size();++i)
>       {
>           FieldContainerPtr fc = fcs[i];
>           if(fc != NullFC)
>           {
>               if(fc == start)
>                   found_start = true;
>
>               if(found_start)
>               {
>                   cl->addCreated(fc.getFieldContainerId());
>                   for(UInt32 j=0;j<fc.getRefCount();++j)
>                       cl->addAddRefd(fc);
>                   cl->addChanged(fc, FieldBits::AllFields);
>               }
>           }
>       }
> }
>
>
>
>
> >>>What I was looking for originally was a way to artificially create a
> >>>complete change list from an existing model.  I would think that would
> >>>be a simpler way to reestablish a broken connection because you
> >>>wouldn't have to keep a record of all changes since the start of the
> >>>client.  Has this method been considered?
> >>


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to