SIL.FieldWorks.XWorks.InterestingTextList.GetScriptureTexts C# (CSharp) Method

GetScriptureTexts() private method

private GetScriptureTexts ( ) : List
return List
		private List<IStText> GetScriptureTexts()
		{
			var result = new List<IStText>();
			if (m_propertyTable == null)
				return result;
			var idList = m_propertyTable.GetStringProperty(PersistPropertyName, "");
			foreach (string id in idList.Split(','))
			{
				if (id.Length == 0)
					continue; // we get one empty string even from splitting an empty one.
				Guid guid;
				try
				{
					guid = new Guid(Convert.FromBase64String(id));
				}
				catch (FormatException)
				{
					// Just ignore this one. (I'd like to Assert, but a unit test verifies we can handle garbage).
					Debug.WriteLine(PersistPropertyName + "contains invalid guid " + id);
					continue;
				}
				IStText item;
				if (m_stTextRepository.TryGetObject(guid, out item))
					result.Add(m_stTextRepository.GetObject(guid));
				// An invalid item is not an error, it may just have been deleted while the interesting
				// text list was not monitoring things.
			}
			return result;
		}