I have 3 structs which are nested into each other i.e. struct A <- struct B <-- struct C
All 3 structs belong to their own contracts (contract A, contract B, contract C) and each contract has a function to create an object based on their struct.
What is the best way to create the structs, and add them to the other struct? should I be using the composite behavioral design pattern in combination with the factory creational design pattern, or what is the best way?