GeometryGym.Ifc.IfcObjective.setJSON C# (CSharp) Méthode

setJSON() protected méthode

protected setJSON ( Newtonsoft.Json.Linq.JObject obj, BaseClassIfc host, HashSet processed ) : void
obj Newtonsoft.Json.Linq.JObject
host BaseClassIfc
processed HashSet
Résultat void
        protected override void setJSON(JObject obj, BaseClassIfc host, HashSet<int> processed)
        {
            base.setJSON(obj, host, processed);
            if(mBenchmarkValues.Count > 0)
            {
                JArray array = new JArray();
                foreach(IfcConstraint c in BenchmarkValues)
                {
                    if (c.mIndex != host.mIndex)
                        array.Add(c.getJson(this, processed));
                }
                if (array.Count > 0)
                    obj["BenchmarkValues"] = array;
            }
            if (mLogicalAggregator != IfcLogicalOperatorEnum.NONE)
                obj["LogicalAggregator"] = mLogicalAggregator.ToString();
            if (mObjectiveQualifier != IfcObjectiveEnum.NOTDEFINED)
                obj["ObjectiveQualifier"] = mObjectiveQualifier.ToString();
            setAttribute(obj, "UserDefinedQualifier", UserDefinedQualifier);
        }