public Guid Get(string textWithId) { if (!IsTextAdded(textWithId)) { throw new ArgumentException(string.Format("Text '{0}' not added.", textWithId), "textWithId"); } return identifiedTexts.Single(text => text.Value.Equals(textWithId)).Key; }