private void InstantiateAllRedProps() { foreach (var item in this.GetREDMembers(true)) { var o = accessor[this, item.Name]; if (o is CVariable cvar) { } else // is null { var att = item.GetMemberAttribute <REDAttribute>(); // instantiate var vartype = REDReflection.GetREDTypeString(item.Type, att.Flags); var varname = REDReflection.GetREDNameString(item); var newvar = CR2WTypeManager.Create(vartype, varname, this.cr2w, this); // create new variable and parent to this if (newvar != null) { accessor[this, item.Name] = newvar; } } } }
public CArrayCompressed(CR2WFile cr2w, CVariable parent, string name) : base(cr2w, parent, name) { Elementtype = REDReflection.GetREDTypeString(typeof(T)); }