예제 #1
0
        /// <summary>
        /// Create deep copy of current instance.
        /// </summary>
        /// <returns>Deep copy.</returns>
        public KeywordsSettings Copy()
        {
            var result = new KeywordsSettings(_parent);

            result.Copy(this);
            return(result);
        }
예제 #2
0
        /// <summary>
        /// Create deep from source into current instance.
        /// </summary>
        /// <param name="source">Source.</param>
        /// <exception cref="ArgumentNullException"><paramref name="source"/>must be not null.</exception>
        public void Copy(KeywordsSettings source)
        {
            if (source == null)
            {
                throw new ArgumentNullException("source");
            }

            var selectedKeywords = new List <string>(source.SelectedKeywords.Count());

            selectedKeywords.AddRange(source.SelectedKeywords.Select(s => s));
            SelectedKeywords = selectedKeywords;

            _ontologyDesc = source._ontologyDesc;
            RaiseKeywordsChanged();
        }
예제 #3
0
 /// <summary>
 /// Create deep copy of current instance.
 /// </summary>
 /// <returns>Deep copy.</returns>
 public KeywordsSettings Copy()
 {
     var result = new KeywordsSettings(_parent);
     result.Copy(this);
     return result;
 }
예제 #4
0
        /// <summary>
        /// Create deep from source into current instance.
        /// </summary>
        /// <param name="source">Source.</param>
        /// <exception cref="ArgumentNullException"><paramref name="source"/>must be not null.</exception>
        public void Copy(KeywordsSettings source)
        {
            if (source == null) throw new ArgumentNullException("source");

            var selectedKeywords = new List<string>(source.SelectedKeywords.Count());
            selectedKeywords.AddRange(source.SelectedKeywords.Select(s => s));
            SelectedKeywords = selectedKeywords;

            _ontologyDesc = source._ontologyDesc;
            RaiseKeywordsChanged();
        }