示例#1
0
 protected override ImageReference GetIcon(IDotNetImageManager dnImgMgr)
 {
     return(dnImgMgr.GetNamespaceImageReference());
 }
示例#2
0
        ImageReference?TryGetImageReference(object @ref)
        {
            var td = @ref as TypeDef;

            if (td != null)
            {
                return(dotNetImageManager.GetImageReference(td));
            }

            var md = @ref as MethodDef;

            if (md != null)
            {
                return(dotNetImageManager.GetImageReference(md));
            }

            var pd = @ref as PropertyDef;

            if (pd != null)
            {
                return(dotNetImageManager.GetImageReference(pd));
            }

            var ed = @ref as EventDef;

            if (ed != null)
            {
                return(dotNetImageManager.GetImageReference(ed));
            }

            var fd = @ref as FieldDef;

            if (fd != null)
            {
                return(dotNetImageManager.GetImageReference(fd));
            }

            if (@ref is NamespaceReference)
            {
                return(dotNetImageManager.GetNamespaceImageReference());
            }

            if (@ref is GenericParam)
            {
                return(dotNetImageManager.GetImageReferenceGenericParameter());
            }
            if (@ref is Local)
            {
                return(dotNetImageManager.GetImageReferenceLocal());
            }
            if (@ref is Parameter)
            {
                return(dotNetImageManager.GetImageReferenceParameter());
            }
            if (@ref is IType)
            {
                return(dotNetImageManager.GetImageReferenceType());
            }
            if (@ref is IMethod && ((IMethod)@ref).IsMethod)
            {
                return(dotNetImageManager.GetImageReferenceMethod());
            }
            if (@ref is IField && ((IField)@ref).IsField)
            {
                return(dotNetImageManager.GetImageReferenceField());
            }

            return(null);
        }
示例#3
0
 protected override ImageReference GetIcon(IDotNetImageManager dnImgMgr)
 {
     return dnImgMgr.GetNamespaceImageReference();
 }