Ejemplo n.º 1
0
        public override void SolidifyInstance(CmlContext context, object representation, CmlSet set)
        {
            CmlValue children = set.GetValue(name);

            CmlValue_Link         children_link;
            CmlValue_SystemValues children_values;

            if (children.Convert <CmlValue_Link>(out children_link))
            {
                EffigyLink effigy_link = effigy_info.CreateLink(context, representation, children_link.GetVariableInstance(), children_link.GetClass());

                selectors.Process(
                    s => set.GetValue(s.GetName()).IfNotNull(
                        v => s.SolidifyInstance(
                            context,
                            representation,
                            effigy_link,
                            v
                            ))
                    );

                context.AddEffigyLink(
                    children_link.GetGroup(),
                    effigy_link
                    );
            }
            else if (children.Convert <CmlValue_SystemValues>(out children_values))
            {
                effigy_info.SetChildren(representation, children_values.GetSystemValues());
            }
        }
Ejemplo n.º 2
0
 static public object ForceSystemValue(this CmlValue item)
 {
     return(item.Convert <CmlValue_SystemValue>().IfNotNull(v => v.GetSystemValue()));
 }