View Issue Details

IDProjectCategoryView StatusLast Update
0029385Open CASCADEOCCT:Application Frameworkpublic2018-06-29 21:19
ReporterabvAssigned Toapn  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Target Version7.3.0Fixed in Version7.3.0 
Summary0029385: OCAF - TDataStd_IntPackedMap lacks interface to set map as TColStd_PackedMapOfInteger
DescriptionTDataStd_IntPackedMap provides interface to access stored map as both const TColStd_PackedMapOfInteger& and Handle(TColStd_HPackedMapOfInteger); however, method ChangeMap() accepts only Handle(TColStd_HPackedMapOfInteger). This means that to set map available as TColStd_PackedMapOfInteger I need to create intermediate TColStd_HPackedMapOfInteger which is inefficient. It would be logical to have interface for setting the map accepting const TColStd_PackedMapOfInteger&
Steps To ReproduceN/A
TagsNo tags attached.
Test case numberNot needed

Activities

git

2017-12-28 16:53

administrator   ~0073184

Branch CR29385 has been created by szy.

SHA-1: f78f48c7c2b4a4078998e613fc56870f1711f744


Detailed log of new commits:

Author: szy
Date: Thu Dec 28 16:53:41 2017 +0300

    0029385: OCAF - TDataStd_IntPackedMap lacks interface to set map as TColStd_PackedMapOfInteger.
    
    Added method ChangeMap (const TColStd_PackedMapOfInteger& theMap).

szy

2017-12-29 11:03

manager   ~0073188

The interface is extended. The requested additional method
  Standard_Boolean ChangeMap (const TColStd_PackedMapOfInteger& theMap)
is added.
Tested:
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-OCCT-Windows-64-VC10-opt-tests-compare-windows/1/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-OCCT-Debian70-64-opt-tests-compare-linux/1/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-Products-Windows-64-VC10-opt-tests-compare-windows/1/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-Products-Debian70-64-opt-tests-compare-linux/1/
The last test Products-Debian70 has 1 failure (omf misc license) which has no any connection with the current patch.

mpv

2017-12-29 14:02

developer   ~0073193

In the method TDataStd_IntPackedMap::ChangeMap

it seems the first condition is useless:
if(theMap.IsEmpty()) return Standard_False;

It must be possible to set the empty map and it must change the content of an attribute.

szy

2018-01-10 18:47

manager   ~0073292

In fact this behavior is already implemented in method TDataStd_IntPackedMap::Clear () which cleans current map.
I.e. the map becomes empty exactly as you noticed. I think that adding the second possibility to set empty map looks as extra.

abv

2018-01-10 19:11

manager   ~0073293

I cannot agree: if I call ChangeMap(), I want the attribute to store exactly the map I given as argument. The map can contain any number of items, including zero. It should be stored as well.

mpv

2018-01-11 09:08

developer   ~0073302

I agree with Andrey: it is unexpected behavior if the user calls ChangeMap, but it does nothing.

git

2018-01-12 11:51

administrator   ~0073383

Branch CR29385_1 has been created by szy.

SHA-1: 4068e23315731eca4388f733105450ab472249a7


Detailed log of new commits:

Author: szy
Date: Thu Dec 28 16:53:41 2017 +0300

    0029385: OCAF - TDataStd_IntPackedMap lacks interface to set map as TColStd_PackedMapOfInteger
    
    // ChangeMap with empty map is allowed.
    
    0029385: OCAF - TDataStd_IntPackedMap lacks interface to set map as TColStd_PackedMapOfInteger.
    
    Added method ChangeMap (const TColStd_PackedMapOfInteger& theMap).

szy

2018-01-12 18:06

manager   ~0073395

Fixed and tested. Review, please.
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-OCCT-Windows-64-VC10-opt-tests-compare-windows/3/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-OCCT-Debian70-64-opt-tests-compare-linux/3/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-Products-Windows-64-VC10-opt-tests-compare-windows/3/
- http://jenkins-test-10.nnov.opencascade.com:8080/job/CR29385-master-szy-Products-Debian70-64-opt-tests-compare-linux/3/

apn

2018-01-12 22:48

administrator   ~0073398

Combination -
OCCT branch : CR29385_1 SHA - 4068e23315731eca4388f733105450ab472249a7
Products branch : master SHA - c667ca9e3bc920614b06911e337a09899f80aa2f
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian70-64:
OCCT
Total CPU difference: 18554.749999999753 / 18498.959999999654 [+0.30%]
Products
Total CPU difference: 7488.03999999999 / 7484.560000000007 [+0.05%]
Windows-64-VC10:
OCCT
Total CPU difference: 18025.9155499985 / 17960.90993329856 [+0.36%]
Products
Total CPU difference: 8059.042860199995 / 8020.448212799986 [+0.48%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2018-02-05 11:39

administrator   ~0073769

Branch CR29385 has been deleted by kgv.

SHA-1: f78f48c7c2b4a4078998e613fc56870f1711f744

git

2018-02-05 11:39

administrator   ~0073770

Branch CR29385_1 has been deleted by kgv.

SHA-1: 4068e23315731eca4388f733105450ab472249a7

Related Changesets

occt: master 14abe5dc

2017-12-28 13:53:41

szy


Committer: apn Details Diff
0029385: OCAF - TDataStd_IntPackedMap lacks interface to set map as TColStd_PackedMapOfInteger

Added method ChangeMap (const TColStd_PackedMapOfInteger& theMap).
Affected Issues
0029385
mod - src/TDataStd/TDataStd_IntPackedMap.cxx Diff File
mod - src/TDataStd/TDataStd_IntPackedMap.hxx Diff File

Issue History

Date Modified Username Field Change
2017-12-13 11:54 abv New Issue
2017-12-13 11:54 abv Assigned To => mpv
2017-12-25 11:21 mpv Assigned To mpv => szy
2017-12-28 16:43 szy Status new => assigned
2017-12-28 16:53 git Note Added: 0073184
2017-12-29 11:03 szy Note Added: 0073188
2017-12-29 11:03 szy Assigned To szy => mpv
2017-12-29 11:03 szy Status assigned => resolved
2017-12-29 11:03 szy Steps to Reproduce Updated
2017-12-29 14:01 mpv Assigned To mpv => szy
2017-12-29 14:02 mpv Note Added: 0073193
2017-12-29 14:02 mpv Status resolved => assigned
2018-01-10 18:47 szy Note Added: 0073292
2018-01-10 18:47 szy Assigned To szy => mpv
2018-01-10 18:47 szy Status assigned => feedback
2018-01-10 19:11 abv Note Added: 0073293
2018-01-11 09:08 mpv Note Added: 0073302
2018-01-11 09:08 mpv Assigned To mpv => szy
2018-01-12 11:51 git Note Added: 0073383
2018-01-12 18:06 szy Note Added: 0073395
2018-01-12 18:06 szy Assigned To szy => mpv
2018-01-12 18:06 szy Status feedback => resolved
2018-01-12 18:16 mpv Assigned To mpv => abv
2018-01-12 18:16 mpv Assigned To abv => bugmaster
2018-01-12 18:16 mpv Status resolved => reviewed
2018-01-12 22:48 apn Test case number => Not needed
2018-01-12 22:48 apn Note Added: 0073398
2018-01-12 22:48 apn Status reviewed => tested
2018-01-21 14:17 apn Changeset attached => occt master 14abe5dc
2018-01-21 14:17 apn Assigned To bugmaster => apn
2018-01-21 14:17 apn Status tested => verified
2018-01-21 14:17 apn Resolution open => fixed
2018-02-05 11:39 git Note Added: 0073769
2018-02-05 11:39 git Note Added: 0073770
2018-02-20 12:58 aiv Target Version 7.4.0 => 7.3.0
2018-06-29 21:15 aiv Fixed in Version => 7.3.0
2018-06-29 21:19 aiv Status verified => closed