Ejemplo n.º 1
0
        /// <summary>
        /// Creates a new instance of AlgsFromFileStored
        /// </summary>
        /// <param name="fileName"></param>
        public AlgsFromFileStored(string fileName)
        {
            _algs = new List <Algorithm>();
            var file = new AlgFile(fileName, AlgFileMode.Open, AlgFileAccess.Read);

            for (int k = 0; k < file.NumAlgs; k++)
            {
                _algs.Add(file.Read(k));
            }
            file.Close();
        }
Ejemplo n.º 2
0
 /// <summary>
 /// creates a new instance of AlgsFromFile
 /// </summary>
 /// <param name="fileName">The .alg file from which to retrieve algorithms</param>
 public AlgsFromFile(string fileName)
 {
     _file = new AlgFile(fileName, AlgFileMode.Open, AlgFileAccess.Read);
 }