• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Save/Restore simple objects that are parts of composite objects

New Here ,
Jul 08, 2019 Jul 08, 2019

Copy link to clipboard

Copied

What values will be in array after Restoring, if before Saving they were [1, 2, 3], after saving changed to [5, 6, 7]?

TOPICS
Programming

Views

258

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jul 08, 2019 Jul 08, 2019

In case that wasn't clear, the simple values in a composite object are not separate items, but are part of the composite object. Bear in mind that [5 6 7] is a new composite object, you'd have to use put or putinterval to update the elements of an existing object.

Votes

Translate

Translate
LEGEND ,
Jul 08, 2019 Jul 08, 2019

Copy link to clipboard

Copied

The restore puts back all non-global composite objects to their contents before the matching save.  The magic by which this happens is implementation dependent, but one way to think of it is that all non-global composite objects are saved in a container on the save, and put back on the restore. (This is not how it works, but what seems to happen).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 08, 2019 Jul 08, 2019

Copy link to clipboard

Copied

In case that wasn't clear, the simple values in a composite object are not separate items, but are part of the composite object. Bear in mind that [5 6 7] is a new composite object, you'd have to use put or putinterval to update the elements of an existing object.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 08, 2019 Jul 08, 2019

Copy link to clipboard

Copied

LATEST

Thank, you very much for quick answer.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines