Skip to content

Way to store all snapshots with link between them  #1

Description

@EBMBA

Problem

To present all snapshots and to interact with all snapshots we should have a good data structure.

Possible solution

I've choosed a heap to store them.

With two structures :

typedef struct 
{
    char *name;
    char *description;
    int indexFirstChild;  // Index of the first child because we have only two way to go to a snapshot to another ( Current Snapshot ==> Parent Snapshot or Roots Snapshot to Children Snapshots sort by index) 
    int numChild; // number of children snapshots 
} Snapshot;

typedef struct 
{
    Snapshot data[DEFAULT_SNAPSHOT_HEAP_SIZE];
    int index; 
}SnapshotHeap; 

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions