Ejemplo n.º 1
0
        public XElement WriteObject(IEnumerable <IOutputFilterModuleInstance> value)
        {
            XmlOutputFilterSerializer serializer = new XmlOutputFilterSerializer();
            IEnumerable <XElement>    elements   = value.Select(serializer.WriteObject);

            return(new XElement(ELEMENT_FILTERS, elements));
        }
Ejemplo n.º 2
0
        public IEnumerable <IOutputFilterModuleInstance> ReadUnwrappedCollection(XElement element)
        {
            List <IOutputFilterModuleInstance> filters = new List <IOutputFilterModuleInstance>();

            XmlOutputFilterSerializer serializer = new XmlOutputFilterSerializer();

            filters.AddRange(element.Elements().Select(serializer.ReadObject).NotNull());

            return(filters);
        }