コード例 #1
0
        /// <summary>Adds a value to a HashSet. Creates a new HashSet if the value passed is null</summary>
        /// <param name="bookData"></param>
        /// <param name="key"></param>
        /// <param name="value"></param>
        private static void AddOrNew(Dictionary <CharacterVerseData.StandardCharacter, HashSet <string> > bookData,
                                     CharacterVerseData.StandardCharacter key, string value)
        {
            if (bookData[key] == null)
            {
                bookData[key] = new HashSet <string>();
            }

            bookData[key].Add(value);
        }
コード例 #2
0
ファイル: Block.cs プロジェクト: irahopkinson/Glyssen
 public void SetStandardCharacter(string bookId, CharacterVerseData.StandardCharacter standardCharacterType)
 {
     CharacterId = CharacterVerseData.GetStandardCharacterId(bookId, standardCharacterType);
     Delivery    = null;
 }
コード例 #3
0
ファイル: Block.cs プロジェクト: irahopkinson/Glyssen
 public bool CharacterIs(string bookId, CharacterVerseData.StandardCharacter standardCharacterType)
 {
     return(CharacterId == CharacterVerseData.GetStandardCharacterId(bookId, standardCharacterType));
 }