[amd64/tramp] hide interpreter specific trampoline behind ifdef
[mono.git] / mcs / class / referencesource / System.Activities.Presentation / Microsoft.Tools.Common / Microsoft / Activities / Presentation / Xaml / EditorAttributeInfo.cs
1 // <copyright>
2 //   Copyright (c) Microsoft Corporation.  All rights reserved.
3 // </copyright>
4
5 namespace Microsoft.Activities.Presentation.Xaml
6 {
7     using System;
8     using System.Collections;
9     using System.Collections.Generic;
10     using System.ComponentModel;
11     using System.Reflection;
12
13     class EditorAttributeInfo : AttributeInfo<EditorAttribute>
14     {
15         public override ICollection GetConstructorArguments(EditorAttribute attribute, ref ConstructorInfo constructor)
16         {
17             return new List<object>() { Type.GetType(attribute.EditorTypeName), Type.GetType(attribute.EditorBaseTypeName) };
18         }
19
20         public override ConstructorInfo GetConstructor()
21         {
22             Type editorAttributeType = typeof(EditorAttribute);
23             ConstructorInfo constructor = editorAttributeType.GetConstructor(new Type[] { typeof(Type), typeof(Type) });
24             SharedFx.Assert(constructor != null, "designerAttribute has a constructor that takes two argument of type System.Type and System.Type.");
25             return constructor;
26         }
27     }
28 }