本文整理汇总了C#中SolutionItem.SetItemHandler方法的典型用法代码示例。如果您正苦于以下问题:C# SolutionItem.SetItemHandler方法的具体用法?C# SolutionItem.SetItemHandler怎么用?C# SolutionItem.SetItemHandler使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SolutionItem
的用法示例。
在下文中一共展示了SolutionItem.SetItemHandler方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: InstallHandler
public static void InstallHandler (ISolutionItemHandler handler, SolutionItem item)
{
item.SetItemHandler (handler);
}
示例2: InitializeItemHandler
internal static void InitializeItemHandler (SolutionItem item)
{
SolutionEntityItem eitem = item as SolutionEntityItem;
if (eitem != null) {
foreach (ItemTypeNode node in GetItemTypeNodes ()) {
if (node.CanHandleItem (eitem)) {
node.InitializeHandler (eitem);
foreach (DotNetProjectSubtypeNode snode in GetItemSubtypeNodes ()) {
if (snode.CanHandleItem (eitem))
snode.InitializeHandler (eitem);
}
return;
}
}
}
else if (item is SolutionFolder) {
MSBuildHandler h = new MSBuildHandler (FolderTypeGuid, null);
h.Item = item;
item.SetItemHandler (h);
}
}
示例3: InitializeHandler
public static void InitializeHandler (SolutionItem item)
{
if (item is DotNetProject) {
DotNetProject p = (DotNetProject) item;
item.SetItemHandler (new MD1DotNetProjectHandler (p));
p.FileName = FileFormat.GetValidFileName (p, p.FileName);
}
else if (item is SolutionEntityItem) {
SolutionEntityItem it = (SolutionEntityItem) item;
item.SetItemHandler (new MD1SolutionEntityItemHandler (it));
it.FileName = FileFormat.GetValidFileName (it, it.FileName);
}
else {
item.SetItemHandler (new MD1SolutionItemHandler (item));
}
}