public static bool Set(this CompiledParticle compiled, OpenXmlCompositeElement parent, OpenXmlElement value, Type type) { if (type is null) { return(false); } if (compiled is null) { return(false); } var collection = new ParticleCollection(type, compiled, parent); collection.Clear(); return(collection.Add(value)); }