Advtools.AdvInterceptor.Configuration.Load C# (CSharp) Method

Load() public static method

public static Load ( string path ) : Configuration
path string
return Configuration
        public static Configuration Load(string path)
        {
            if(!File.Exists(path))
                throw new ApplicationException(string.Format("Configuration file '{0}' not found.", path));

            XmlSerializer serializer = new XmlSerializer(typeof(Configuration));
            StreamReader reader = new StreamReader(path);
            return serializer.Deserialize(reader) as Configuration;
        }