ContentFieldDefinition Build(ContentFieldDefinitionRecord source) { return new ContentFieldDefinition(source.Name); }
private ContentFieldDefinitionRecord Acquire(ContentFieldDefinition contentFieldDefinition) { var result = _contentStorageManager .Query<ContentFieldDefinitionRecord>(x => x.Name == contentFieldDefinition.Name) .SingleOrDefault(); if (result == null) { result = new ContentFieldDefinitionRecord { Name = contentFieldDefinition.Name }; _contentStorageManager.Store(result); } return result; }