Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » Report serialization
Re: Report serialization [message #18990 is a reply to message #18987] Mon, 03 November 2008 10:46 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 14267
Registered: November 2005
Ultimate Member
BioBytes wrote on Mon, 03 November 2008 03:46

Hi all of you,

I tried to save report on disque via serialization and I face an issue with reading the file from the disk. I succeeded to write via fileout but when my application tries to read it using FileIn I get an Assertion failure in Core.h.

I join the code used in my application

I would be grateful if somebody could advice me on what is wrong.

Thanking in advance for your help

Kind regards

Biobytes


Well, for starters, const Array<Drawing>& is returned. You should not be writing to it.

There is unfortnunately on "impedance mismatch" with C++ standard which in this case bites you - that const Array gets destroyed by "pick".

http://www.ultimatepp.org/srcdoc$Core$PickTypes$en-us.html
http://www.ultimatepp.org/srcdoc$Core$pick_$en-us.html

Second problem is that there is more state info involved than mere page Drawings.

What should work is to cycle through Array<Drawing>, read individual Drawing into separate variable and store one by one.

Then on loading, load Drawing and draw it to pages.

That is completely trasparent. And no need to derive from Report.

Mirek
 
Read Message
Read Message
Read Message
Previous Topic: Format Issues - Dynamic width and alignment
Next Topic: Core/Ol_Set.cpp should to change!
Goto Forum:
  


Current Time: Thu Aug 21 20:36:52 CEST 2025

Total time taken to generate the page: 0.06498 seconds