Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
3rd
lib3mf
Commits
f02e7f8e
Commit
f02e7f8e
authored
6 years ago
by
Martin Weismann
Browse files
Options
Download
Email Patches
Plain Diff
Use unordered map to increase performance
parent
0c7de975
master
JavaBindings
archersim/master
develop
draftBinaryToolpath
draftGeometryCompression
fastfloat
fuzzitdev-fuzzit_integration
implicit
issue_273_enable_cek_setup
lib3mf-v2-develop
maintenance
release/2.0.0
release/2.0.1
release/2.1.0
release/2.1.0-alpha
release/2.1.0-beta
release/2.1.1
release/2.2.0
secureContentAPIvo
toolpath_new
trianglesets
updateLibZip
v2AutoFormat
volumetric
v2.2.0
v2.1.1
v2.1.0
v2.1.0-beta
v2.1.0-alpha
v2.0.1
v2.0.0
v2.0.0-beta
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Include/Model/Classes/NMR_Model.h
+3
-4
Include/Model/Classes/NMR_Model.h
Include/Model/Classes/NMR_PackageResourceID.h
+2
-1
Include/Model/Classes/NMR_PackageResourceID.h
with
5 additions
and
5 deletions
+5
-5
Include/Model/Classes/NMR_Model.h
View file @
f02e7f8e
...
...
@@ -94,8 +94,7 @@ namespace NMR {
std
::
string
m_sCurPath
;
std
::
string
m_sRootPath
;
std
::
map
<
std
::
string
,
PUUID
>
usedUUIDs
;
// datastructure used to ensure that UUIDs within one model (package) are unique
std
::
unordered_map
<
std
::
string
,
PUUID
>
usedUUIDs
;
// datastructure used to ensure that UUIDs within one model (package) are unique
// Object Resources of the model
std
::
map
<
PackageResourceID
,
PModelResource
>
m_ResourceMap
;
...
...
@@ -121,14 +120,14 @@ namespace NMR {
// Model Attachments
std
::
vector
<
PModelAttachment
>
m_Attachments
;
std
::
map
<
std
::
string
,
PModelAttachment
>
m_AttachmentURIMap
;
std
::
unordered_
map
<
std
::
string
,
PModelAttachment
>
m_AttachmentURIMap
;
// Custom Attachment Content Types
std
::
map
<
std
::
string
,
std
::
string
>
m_CustomContentTypes
;
// Production Model Attachments
std
::
vector
<
PModelAttachment
>
m_ProductionAttachments
;
std
::
map
<
std
::
string
,
PModelAttachment
>
m_ProductionAttachmentURIMap
;
std
::
unordered_
map
<
std
::
string
,
PModelAttachment
>
m_ProductionAttachmentURIMap
;
// Indexed lookup lists for standard resource types
std
::
vector
<
PModelResource
>
m_ObjectLookup
;
...
...
This diff is collapsed.
Click to expand it.
Include/Model/Classes/NMR_PackageResourceID.h
View file @
f02e7f8e
...
...
@@ -38,6 +38,7 @@ NMR_PackageResourceID.h defines the PackageResourceID Class.
#include <memory>
#include <map>
#include <unordered_map>
#include <vector>
namespace
NMR
{
...
...
@@ -63,7 +64,7 @@ namespace NMR {
class
CResourceHandler
{
private:
// unique IDs to CPackageResourceID
std
::
map
<
PackageResourceID
,
PPackageResourceID
>
m_resourceIDs
;
std
::
unordered_
map
<
PackageResourceID
,
PPackageResourceID
>
m_resourceIDs
;
std
::
map
<
std
::
pair
<
ModelResourceID
,
std
::
string
>
,
PPackageResourceID
>
m_IdAndPathToResourceIDs
;
public:
PPackageResourceID
getNewResourceID
(
std
::
string
path
,
ModelResourceID
id
);
// this is supposed to be the only way to generate a CPackageResourceID
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help