ENH: remove some "heavy" data when copying dictionary content

This commit is contained in:
Mark Olesen
2021-04-20 14:09:26 +02:00
parent 399c21d76c
commit dedb1c0c90
7 changed files with 77 additions and 13 deletions

View File

@ -31,6 +31,7 @@ License
#include "pointPatchFieldMapper.H"
#include "pointFields.H"
#include "dynamicCode.H"
#include "dictionaryContent.H"
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
@ -157,7 +158,20 @@ Foam::codedFixedValuePointPatchField<Type>::codedFixedValuePointPatchField
:
fixedValuePointPatchField<Type>(p, iF, dict, valueRequired),
codedBase(),
dict_(dict),
dict_
(
// Copy dictionary, but without "heavy" data chunks
dictionaryContent::copyDict
(
dict,
wordRes(), // allow
wordRes // deny
({
"type", // redundant
"value"
})
)
),
name_(dict.getCompat<word>("name", {{"redirectType", 1706}})),
redirectPatchFieldPtr_(nullptr)
{