예제 #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ExperimentFactoryReader"/> class.
        /// </summary>
        /// <param name="library">The library.</param>
        /// <param name="experimentLocationRoot">The experiment location root - it can be null in case the experiment belongs to composite component.</param>
        public ExperimentFactoryReader(Components.IComponentsLibrary library, IEnumerable<IPackageReference> references, string experimentLocationRoot)
        {
            if (library == null)
                throw new ArgumentNullException("library");

            m_library = library.GetPackageAwareLibrary(references);
            m_experimentLocationRoot = experimentLocationRoot;

            //Create our own namespaces for the output
            var ns = new System.Xml.Serialization.XmlSerializerNamespaces();

            //Add an empty namespace and empty value
            ns.Add("", "");

            m_nodeSerializer = TraceLab.Core.Serialization.XmlSerializerFactory.GetSerializer(typeof(SerializedVertexData), null);
            m_nodeSerializerWithSize = TraceLab.Core.Serialization.XmlSerializerFactory.GetSerializer(typeof(SerializedVertexDataWithSize), null);

        }