public static ReadOnlyArray <ElementProperty <OpenXmlElement> > GetElements(PackageCache cache, Type type) { SchemaIndex GetSchema(PropertyInfo property) { var index = property.GetCustomAttribute <IndexAttribute>(); var schema = cache.GetElementTypeInfo(property.PropertyType).Schema; return(new SchemaIndex(schema, index)); } return(ElementPropertyCollection <OpenXmlElement> .GetProperties(cache, type, GetSchema)); }
private ReadOnlyArray <ElementProperty <OpenXmlSimpleType> > CreateAttributes(Type type) => ElementPropertyCollection <OpenXmlSimpleType> .GetProperties(this, type);