I'm wondering how to define field types for a class dynamically according to a field from another class ???
I mean how to define and link a field from a class to another class, example:

```
class TemplateRecord(Packet):
    name = "Template Record"
    fields_desc = [ ShortField("Type", 0),
                    ShortField("Length", 0) ]

    def extract_padding(self, s):
            return "", s

class DataRecord(Packet):
    name = "Data Record"
    fields_desc = [ ==> Here i would like something like this :

            "if Type == 0 from Class TemplateRecord:
                IPField("ipsrc", "0.0.0.0"),
            if Type == 1 from Class TemplateRecord
                IPField("ipdst", "0.0.0.0"),
            if Type == 2 from Class TemplateRecord
                                    ByteField("DstMask", 0),

            ....etc..." 

        ]
    def extract_padding(self, s):
            return "", s

```