Exemplo n.º 1
0
        /// <summary>
        /// Parse Library and convert parsed data into structure.
        /// </summary>
        /// <param name="library">Name of Library.</param>
        private void Parse(string library)
        {
            string[] libraryInformation         = library.Split(new char[] { ' ' }, 3);
            CloneLibraryInformation information = new CloneLibraryInformation()
            {
                LibraryName               = libraryInformation[0],
                MeanLengthOfInsert        = float.Parse(libraryInformation[1], CultureInfo.InvariantCulture),
                StandardDeviationOfInsert = float.Parse(libraryInformation[2], CultureInfo.InvariantCulture)
            };

            this.libraries.Add(information.LibraryName, information);
        }
Exemplo n.º 2
0
 /// <summary>
 /// Add Library to existing list of libraries.
 /// </summary>
 /// <param name="library">Libarary information.</param>
 public void AddLibrary(CloneLibraryInformation library)
 {
     if (null != library && !String.IsNullOrEmpty(library.LibraryName) &&
         library.MeanLengthOfInsert >= 0 && library.StandardDeviationOfInsert >= 0)
     {
         this.libraries[library.LibraryName] = library;
     }
     else
     {
         throw new ArgumentException(Properties.Resource.LibraryInvalidParameters);
     }
 }
Exemplo n.º 3
0
        /// <summary>
        /// Add Library to existing list of libraries.
        /// </summary>
        /// <param name="libraryName">Name of Library.</param>
        /// <param name="mean">Mean Length Of Insert.</param>
        /// <param name="standardDeviation">Standard Deviation Of Insert.</param>
        public void AddLibrary(string libraryName, float mean, float standardDeviation)
        {
            if (String.IsNullOrEmpty(libraryName) || mean < 0 || standardDeviation < 0)
            {
                throw new ArgumentException(Properties.Resource.LibraryInvalidParameters);
            }

            CloneLibraryInformation library = new CloneLibraryInformation()
            {
                LibraryName               = libraryName,
                MeanLengthOfInsert        = mean,
                StandardDeviationOfInsert = standardDeviation
            };

            this.libraries[libraryName] = library;
        }
Exemplo n.º 4
0
        /// <summary>
        /// Parse Library and convert parsed data into structure.
        /// </summary>
        /// <param name="library">Name of Library.</param>
        private void Parse(string library)
        {
            string[] libraryInformation = library.Split(new char[] { ' ' }, 3);
            CloneLibraryInformation information = new CloneLibraryInformation()
            {
                LibraryName = libraryInformation[0],
                MeanLengthOfInsert = float.Parse(libraryInformation[1], CultureInfo.InvariantCulture),
                StandardDeviationOfInsert = float.Parse(libraryInformation[2], CultureInfo.InvariantCulture)
            };

            this.libraries.Add(information.LibraryName, information);
        }
Exemplo n.º 5
0
        /// <summary>
        /// Add Library to existing list of libraries.
        /// </summary>
        /// <param name="libraryName">Name of Library.</param>
        /// <param name="mean">Mean Length Of Insert.</param>
        /// <param name="standardDeviation">Standard Deviation Of Insert.</param>
        public void AddLibrary(string libraryName, float mean, float standardDeviation)
        {
            if (String.IsNullOrEmpty(libraryName) || mean < 0 || standardDeviation < 0)
            {
                throw new ArgumentException(Properties.Resource.LibraryInvalidParameters);
            }

            CloneLibraryInformation library = new CloneLibraryInformation()
            {
                LibraryName = libraryName,
                MeanLengthOfInsert = mean,
                StandardDeviationOfInsert = standardDeviation
            };
            
            this.libraries[libraryName] = library;
        }
Exemplo n.º 6
0
 /// <summary>
 /// Add Library to existing list of libraries.
 /// </summary>
 /// <param name="library">Library information.</param>
 public void AddLibrary(CloneLibraryInformation library)
 {
     if (null != library && !String.IsNullOrEmpty(library.LibraryName) &&
        library.MeanLengthOfInsert >= 0 && library.StandardDeviationOfInsert >= 0)
     {
         this.libraries[library.LibraryName] = library;
     }
     else
     {
         throw new ArgumentException(Properties.Resource.LibraryInvalidParameters);
     }           
 }