View Issue Details

IDProjectCategoryView StatusLast Update
0025681CommunityOCCT:Application Frameworkpublic2020-10-16 16:31
ReporterVico Liang Assigned Tobugmaster  
PrioritylowSeverityfeature 
Status closedResolutionfixed 
Target Version7.5.0 
Summary0025681: Application Framework - Unicode data storage in XML or binary format
DescriptionIt's impossible to save and then restore Unicode data into XML or Binary format document before OCCT6.8.0. The Unicode presentation is TCollection_ExtendedString, so the changes might be updating TCollection_ExtendedString storage and retrieve drivers.
Steps To ReproduceNot applicable
TagsNo tags attached.
Test case number

Relationships

related to 0030773 closedabv Open CASCADE Application Framework - To allow to inherit existing attributes to reuse persistence mechanisms 
related to 0025683 assignedvro Community Application Framework - No entrance to construct a LDOMBasicString from TCollection_ExtendedString 
child of 0022484 closedbugmaster Open CASCADE UNICODE characters support. 

Activities

vro

2016-02-09 11:58

developer   ~0050516

Hello Vico. A unicode string may be saved in XML or binaries file formats of OCAF document. See please XmlMDataStd_NameDriver and BinMDataStd_NameDriver, for example. These drivers exist since a very early version of Open CASCADE (much earlier than 6.8.0).

Vico Liang

2016-04-12 11:40

developer   ~0052597

Dear vro,

I'm using class TCollection_ExtendedString in my applicaton, and i don't want to use class TDataStd_Name since TDataStd_Name is just for naming purpose in my application. I see there is driver for TDataStd_Name.

Now my problem is that i want to store TCollection_ExtendedString in xml or binary. TCollection_ExtendedString is a basis data type of OCCT, i think it should provide an attribute and for it (like TDataStd_ExtendedString) and then provide drivers.

vro

2016-04-14 09:17

developer   ~0052699

I understand your desire and might propose the following:
1. You might use TDataStd_Comment - it keeps a unicode string too and it is very similar to TDataStd_Name.
2. Open CASCADE is an open source library. You might develop a TDataStd_ExtendedString attribute yourself with persistent-transient drivers for XML and Binary file formats. What do you think?
Any questions are welcome!

Vico Liang

2016-04-14 11:00

developer   ~0052701

Dear vro,

Though TDataStd_Comment can store unicode string, it have its own application semantics, and it should just be used for comment rather than as a common string.

Yes, Open CASCADE is an open source library. OCCT is becoming better and better. So the reason i report this is just to want to make occt better. I just reminder that OCCT need an attribute TDataStd_ExtendedString.

Vico Liang

2016-04-14 11:05

developer   ~0052702

I'm curious, why there is TDataStd_AsciiString, but without TDataStd_ExtendedString? It's so nature to provice attributes for these two kinds of string.

vro

2016-04-14 12:02

developer   ~0052709

I think it is a good idea to make a new attribute and extend OCAF. So, you are welcome with your contribution to Open CASCADE!

Vico Liang

2016-04-14 13:43

developer   ~0052712

Dear vro, You made a right desision to make a new attribute to extend OCAF. The implementation should be better done from OCCT team.

vro

2016-04-14 14:10

developer   ~0052714

You are welcome to contact our sales or consulting departments please at http://www.opencascade.com.

kgv

2020-10-14 11:59

developer   ~0095956

Mikhail, could you please comment if new attribute TDataStd_GenericExtString (0030773) can be bound to this issue, or there is still no general driver for Extended Strings?

Vico, while OCAF relies intensively on TCollection_ExtendedString, this is rather for historical reasons. TCollection_AsciiString is now expected to store UTF-8, so that there is no need using TCollection_ExtendedString for storing UNICODE symbols.

mpv

2020-10-14 13:51

developer   ~0095971

Yes, since coming OCCT version 7.5.0 it is possible to create your own attribute, similar (by fields) to existing ones. You may just inherit TDataStd_GenericExtString attribute in your application, for an example, in a same way as in it done in TDataStd_Name, with new unique GUID. In this case you don't need to create new drivers for this attribute, or change the schema, or change OCCT: for XML and binary formats it will be stored/restored automatically.

Vico Liang

2020-10-14 14:14

developer   ~0095972

Last edited: 2020-10-14 14:15

Thanks for the effort occt made. The two options TCollection_AsciiString and TDataStd_GenericExtString both satisfy my need. Please close this. Thanks again.

mpv

2020-10-14 14:19

developer   ~0095973

Dear bugmaster,

Please, close this issue since no fix is needed.

Issue History

Date Modified Username Field Change
2014-12-31 17:59 Vico Liang New Issue
2014-12-31 17:59 Vico Liang Assigned To => szy
2015-03-05 11:25 szy Priority normal => low
2015-03-05 11:25 szy Target Version 6.9.0 => 6.7.1
2015-03-05 11:40 szy Target Version 6.7.1 => 7.1.0
2015-12-30 16:05 szy Assigned To szy => vro
2015-12-30 16:05 szy Status new => assigned
2016-02-09 11:58 vro Note Added: 0050516
2016-02-09 11:59 vro Assigned To vro => Vico Liang
2016-02-25 14:19 vro Status assigned => feedback
2016-04-12 11:40 Vico Liang Note Added: 0052597
2016-04-12 11:40 Vico Liang Assigned To Vico Liang => vro
2016-04-13 05:04 Vico Liang Status feedback => assigned
2016-04-14 09:17 vro Note Added: 0052699
2016-04-14 11:00 Vico Liang Note Added: 0052701
2016-04-14 11:05 Vico Liang Note Added: 0052702
2016-04-14 12:02 vro Note Added: 0052709
2016-04-14 13:43 Vico Liang Note Added: 0052712
2016-04-14 14:10 vro Note Added: 0052714
2016-11-03 17:21 abv Target Version 7.1.0 => 7.2.0
2017-07-27 09:43 abv Target Version 7.2.0 => 7.4.0
2019-07-10 09:01 abv Target Version 7.4.0 => 7.5.0
2020-09-11 15:32 utverdov Target Version 7.5.0 => 7.6.0
2020-10-14 11:43 kgv Relationship added related to 0025683
2020-10-14 11:47 kgv Summary Unicode data storage in XML or binary format. => Application Framework - Unicode data storage in XML or binary format
2020-10-14 11:47 kgv Relationship added child of 0022484
2020-10-14 11:55 kgv Relationship added related to 0030773
2020-10-14 11:59 kgv Note Added: 0095956
2020-10-14 11:59 kgv Assigned To vro => mpv
2020-10-14 11:59 kgv Status assigned => feedback
2020-10-14 12:00 kgv Target Version 7.6.0 => 7.5.0
2020-10-14 13:46 mpv Assigned To mpv => Vico Liang
2020-10-14 13:51 mpv Note Added: 0095971
2020-10-14 14:14 Vico Liang Note Added: 0095972
2020-10-14 14:15 Vico Liang Note Edited: 0095972
2020-10-14 14:18 mpv Assigned To Vico Liang => mpv
2020-10-14 14:18 mpv Status feedback => resolved
2020-10-14 14:18 mpv Steps to Reproduce Updated
2020-10-14 14:18 mpv Assigned To mpv => bugmaster
2020-10-14 14:19 mpv Note Added: 0095973
2020-10-14 14:22 kgv Status resolved => feedback
2020-10-14 14:22 kgv Resolution open => fixed
2020-10-16 16:31 bugmaster Status feedback => closed