public static DocumentType ToType(this Guid guid) { if (guid == type_text) return DocumentType.Text; return DocumentType.Other; }