当前位置: 首页>>代码示例>>C#>>正文


C# IItemData.GetDisplayIdentifier方法代码示例

本文整理汇总了C#中IItemData.GetDisplayIdentifier方法的典型用法代码示例。如果您正苦于以下问题:C# IItemData.GetDisplayIdentifier方法的具体用法?C# IItemData.GetDisplayIdentifier怎么用?C# IItemData.GetDisplayIdentifier使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IItemData的用法示例。


在下文中一共展示了IItemData.GetDisplayIdentifier方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: DumpTree

        /// <returns>True if the tree was dumped, false if the root item was not included</returns>
        public virtual bool DumpTree(IItemData item, IConfiguration configuration = null)
        {
            using (new TransparentSyncDisabler())
            {
                if(configuration == null) configuration = GetConfigurationForItem(item);

                if (configuration == null) return false;

                var logger = configuration.Resolve<ILogger>();

                var predicate = configuration.Resolve<IPredicate>();
                var serializationStore = configuration.Resolve<ITargetDataStore>();
                var sourceStore = configuration.Resolve<ISourceDataStore>();

                var rootReference = serializationStore.GetByPathAndId(item.Path, item.Id, item.DatabaseName);
                if (rootReference != null)
                {
                    logger.Warn("[D] existing serialized items under {0}".FormatWith(rootReference.GetDisplayIdentifier()));
                    serializationStore.Remove(rootReference);
                }

                logger.Info("[U] Serializing included items under root {0}".FormatWith(item.GetDisplayIdentifier()));

                if (!predicate.Includes(item).IsIncluded) return false;

                DumpTreeInternal(item, predicate, serializationStore, sourceStore, logger);
            }
            return true;
        }
开发者ID:PetersonDave,项目名称:Unicorn,代码行数:30,代码来源:SerializationHelper.cs

示例2: DeserializedNewItem

        public virtual void DeserializedNewItem(IItemData targetItem)
        {
            Assert.ArgumentNotNull(targetItem, "targetItem");

            _logger.Info("[A] {0}".FormatWith(targetItem.GetDisplayIdentifier()));
            _pipelineDataCollector.PushChangedItem(targetItem, ChangeType.Created);
            _pipelineDataCollector.AddProcessedItem();
        }
开发者ID:bllue78,项目名称:Unicorn,代码行数:8,代码来源:DefaultSerializedAsMasterEvaluatorLogger.cs

示例3: DuplicateFound

		public virtual void DuplicateFound(DuplicateIdConsistencyChecker.DuplicateIdEntry existingItemData, IItemData duplicateItemData)
		{
			_logger.Error("Duplicate serialized item IDs were detected ({0}) - this usually indicates corruption in the serialization provider data.<br>Item 1: {1}<br> Item 1 ProviderId: {2}<br>Item 2: {3}<br>Item 2 ProviderId: {4}".FormatWith(duplicateItemData.Id, existingItemData.DisplayName, existingItemData.SerializedItemId, duplicateItemData.GetDisplayIdentifier(), duplicateItemData.SerializedItemId));
		}
开发者ID:GlennHaworth,项目名称:Unicorn,代码行数:4,代码来源:DefaultDuplicateIdConsistencyCheckerLogger.cs

示例4: DuplicateIdEntry

 public DuplicateIdEntry(IItemData item)
 {
     DisplayName = item.GetDisplayIdentifier();
     SerializedItemId = item.SerializedItemId;
 }
开发者ID:bllue78,项目名称:Unicorn,代码行数:5,代码来源:DuplicateIdConsistencyChecker.cs

示例5: DeletedItem

 public virtual void DeletedItem(IItemData deletedItem)
 {
     _logger.Warn("[D] {0} because it did not exist in the serialization provider.".FormatWith(deletedItem.GetDisplayIdentifier()));
     _pipelineDataCollector.PushChangedItem(deletedItem, ChangeType.Deleted);
     _pipelineDataCollector.AddProcessedItem();
 }
开发者ID:bllue78,项目名称:Unicorn,代码行数:6,代码来源:DefaultSerializedAsMasterEvaluatorLogger.cs

示例6: DeletedItem

		public virtual void DeletedItem(string providerName, IItemData existingItemData)
		{
			_logger.Info(string.Format("{0}: Serialized item {1} was deleted due to the source item being deleted.", providerName, existingItemData.GetDisplayIdentifier()));
		}
开发者ID:GlennHaworth,项目名称:Unicorn,代码行数:4,代码来源:DefaultUnicornDataProviderLogger.cs

示例7: SkippedItem

		public override void SkippedItem(IItemData skippedItemData, string predicateName, string justification)
		{
			_logger.Debug("[S] {0} (and children) by {1}: {2}".FormatWith(skippedItemData.GetDisplayIdentifier(), predicateName, justification));
		}
开发者ID:GlennHaworth,项目名称:Unicorn,代码行数:4,代码来源:DebugSerializationLoaderLogger.cs

示例8: EndLoadingTree

		public override void EndLoadingTree(IItemData rootSerializedItemData, int itemsProcessed, long elapsedMilliseconds)
		{
			_logger.Info("Unicorn completed loading {0}".FormatWith(rootSerializedItemData.GetDisplayIdentifier()));
			_logger.Debug("Items processed: {0}, Elapsed time: {1}ms ({2:N2}ms/item)".FormatWith(itemsProcessed, elapsedMilliseconds, (double)elapsedMilliseconds / (double)itemsProcessed));
		}
开发者ID:GlennHaworth,项目名称:Unicorn,代码行数:5,代码来源:DebugSerializationLoaderLogger.cs

示例9: BeginLoadingTree

		public override void BeginLoadingTree(IItemData rootSerializedItemData)
		{
			_logger.Info("Unicorn loading {0}".FormatWith(rootSerializedItemData.GetDisplayIdentifier()));
		}
开发者ID:GlennHaworth,项目名称:Unicorn,代码行数:4,代码来源:DebugSerializationLoaderLogger.cs

示例10: SkippedItemPresentInSerializationProvider

 public virtual void SkippedItemPresentInSerializationProvider(IItemData root, string predicateName, string serializationProviderName, string justification)
 {
     _logger.Warn("[S] {0} by {1} but it was in {2}. {3}<br />This usually indicates an extraneous excluded serialized item is present in the {3}, which should be removed.".FormatWith(root.GetDisplayIdentifier(), predicateName, serializationProviderName, justification));
 }
开发者ID:bllue78,项目名称:Unicorn,代码行数:4,代码来源:DefaultSerializationLoaderLogger.cs


注:本文中的IItemData.GetDisplayIdentifier方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。