Example #1
0
        internal MeaningImpl(VocabularyImpl vocabulary)
            : base(vocabulary)
        {
            this.guid = Guid.NewGuid();
            this.categories = new UniqueStringCollectionImpl();
            this.categories.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Categories").CollectionChanged);
            this.translations = new UniqueStringCollectionImpl();
            this.translations.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Translations").CollectionChanged);
            this.synonyms = new WordCollectionImpl(this);
            this.synonyms.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Synonyms").CollectionChanged);
            this.antonyms = new WordCollectionImpl(this);
            this.antonyms.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Antonyms").CollectionChanged);

            INotifyPropertyChanged npc = (INotifyPropertyChanged)vocabulary;
            npc.PropertyChanged += new PropertyChangedEventHandler(OnUserProfileChanged);
        }
Example #2
0
 internal VocabularyImpl()
 {
     this.nativeLanguage = new LanguageImpl(this);
     this.targetLangauge = new LanguageImpl(this);
     this.wordTypes = new UniqueStringCollectionImpl();
     this.wordTypes.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "WordTypes").CollectionChanged);
     this.categories = new UniqueStringCollectionImpl();
     this.categories.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Categories").CollectionChanged);
     this.words = new VocabularyWordCollectionImpl(this);
     this.words.CollectionChanged += new NotifyCollectionChangedEventHandler(new NotifyCollectionPropertyChangedWrapper(this, "Words").CollectionChanged);
     this.Modify(false);
 }