Skip to content

Commit

Permalink
Add Misc types to InteropServices
Browse files Browse the repository at this point in the history
Add the following types to InteropServices:
- AutomationProxyAttribute
- ComAliasNameAttribute
- ComCompatibleVersionAttribute
- ComConversionLossAttribute
- ComRegisterFunctionAttribute
- ComUnregisterFunctionAttribute
- ICustomFactory
- ICustomMarshaler
- ImportedFromTypeLibAttribute
- LCIDConversionAttribute
- ManagedToNativeComInteropStubAttribute
- PrimaryInteropAssemblyAttribute
- ProgIdAttribute
- TypeLibImportClassAttribute
- TypeLibVersionAttribute
  • Loading branch information
shrah committed Oct 26, 2016
1 parent 653639f commit e8c4f54
Show file tree
Hide file tree
Showing 3 changed files with 188 additions and 7 deletions.
85 changes: 79 additions & 6 deletions src/mscorlib/model.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6555,7 +6555,6 @@
<Member MemberType="Property" Name="ErrorCode" />
<Member Name="get_ErrorCode" />
</Type>
<Type Status="ImplRoot" Name="System.Runtime.InteropServices.LCIDConversionAttribute" Condition="FEATURE_COMINTEROP" />
<Type Name="System.Runtime.InteropServices.CallingConvention">
<Member MemberType="Field" Name="value__" />
<Member MemberType="Field" Name="Winapi" />
Expand Down Expand Up @@ -6667,6 +6666,36 @@
<Type Name="System.Runtime.InteropServices.AllowReversePInvokeCallsAttribute">
<Member Name="#ctor" />
</Type>
<Type Name="System.Runtime.InteropServices.AutomationProxyAttribute">
<Member Name="#ctor(System.Boolean)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.ComAliasNameAttribute">
<Member Name="#ctor(System.String)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.ComCompatibleVersionAttribute">
<Member Name="#ctor(System.Int32,System.Int32,System.Int32,System.Int32)" />
<Member Name="get_MajorVersion" />
<Member MemberType="Property" Name="MajorVersion" />
<Member Name="get_MinorVersion" />
<Member MemberType="Property" Name="MinorVersion" />
<Member Name="get_BuildNumber" />
<Member MemberType="Property" Name="BuildNumber" />
<Member Name="get_RevisionNumber" />
<Member MemberType="Property" Name="RevisionNumber" />
</Type>
<Type Name="System.Runtime.InteropServices.ComConversionLossAttribute">
<Member Name="#ctor" />
</Type>
<Type Name="System.Runtime.InteropServices.ComRegisterFunctionAttribute">
<Member Name="#ctor" />
</Type>
<Type Name="System.Runtime.InteropServices.ComUnregisterFunctionAttribute">
<Member Name="#ctor" />
</Type>
<Type Name="System.Runtime.InteropServices.ExternalException">
<Member Name="#ctor" />
<Member Name="#ctor(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)" />
Expand Down Expand Up @@ -6724,6 +6753,14 @@
<Type Name="System.Runtime.InteropServices.ICustomQueryInterface">
<Member Name="GetInterface(System.Guid@,System.IntPtr@)" />
</Type>
<Type Name="System.Runtime.InteropServices.ICustomFactory">
<Member Name="CreateInstance(System.Type)" />
</Type>
<Type Name="System.Runtime.InteropServices.ImportedFromTypeLibAttribute">
<Member Name="#ctor(System.String)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.InAttribute">
<Member Name="#ctor" />
</Type>
Expand Down Expand Up @@ -6757,10 +6794,10 @@
<Member MemberType="Field" Name="Sequential" />
<Member MemberType="Field" Name="value__" />
</Type>
<Type Name="System.Runtime.InteropServices.NativeCallableAttribute">
<Member Name="#ctor" />
<Member MemberType="Field" Name="CallingConvention" /> <!-- EE -->
<Member MemberType="Field" Name="EntryPoint" /> <!-- EE -->
<Type Name="System.Runtime.InteropServices.LCIDConversionAttribute">
<Member Name="#ctor(System.Int32)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.Marshal">
<Member MemberType="Field" Name="SystemDefaultCharSize" />
Expand Down Expand Up @@ -6927,12 +6964,24 @@
<Member MemberType="Field" Name="SafeArraySubType" />
<Member MemberType="Field" Name="SafeArrayUserDefinedSubType" />
</Type>
<Type Name="System.Runtime.InteropServices.ManagedToNativeComInteropStubAttribute">
<Member Name="#ctor(System.Type,System.String)" />
<Member Name="get_ClassType" />
<Member MemberType="Property" Name="ClassType" />
<Member Name="get_MethodName" />
<Member MemberType="Property" Name="MethodName" />
</Type>
<Type Name="System.Runtime.InteropServices.MarshalDirectiveException" >
<Member Name="#ctor" />
<Member Name="#ctor(System.String)" />
<Member Name="#ctor(System.String,System.Exception)" />
<Member Name="#ctor(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)" />
</Type>
<Type Name="System.Runtime.InteropServices.NativeCallableAttribute">
<Member Name="#ctor" />
<Member MemberType="Field" Name="CallingConvention" /> <!-- EE -->
<Member MemberType="Field" Name="EntryPoint" /> <!-- EE -->
</Type>
<Type Name="System.Runtime.InteropServices.OptionalAttribute">
<Member Name="#ctor" />
</Type>
Expand All @@ -6942,6 +6991,18 @@
<Type Name="System.Runtime.InteropServices.PreserveSigAttribute">
<Member Name="#ctor" />
</Type>
<Type Name="System.Runtime.InteropServices.PrimaryInteropAssemblyAttribute">
<Member Name="#ctor(System.Int32,System.Int32)" />
<Member Name="get_MajorVersion" />
<Member MemberType="Property" Name="MajorVersion" />
<Member Name="get_MinorVersion" />
<Member MemberType="Property" Name="MinorVersion" />
</Type>
<Type Name="System.Runtime.InteropServices.ProgIdAttribute">
<Member Name="#ctor(System.String)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.SafeHandle">
<Member MemberType="Field" Name="handle" />
<Member Name="#ctor(System.IntPtr,System.Boolean)" />
Expand All @@ -6961,6 +7022,18 @@
<Member MemberType="Property" Name="IsClosed" />
<Member MemberType="Property" Name="IsInvalid" />
</Type>
<Type Name="System.Runtime.InteropServices.TypeLibImportClassAttribute">
<Member Name="#ctor(System.Type)" />
<Member Name="get_Value" />
<Member MemberType="Property" Name="Value" />
</Type>
<Type Name="System.Runtime.InteropServices.TypeLibVersionAttribute">
<Member Name="#ctor(System.Int32,System.Int32)" />
<Member Name="get_MajorVersion" />
<Member MemberType="Property" Name="MajorVersion" />
<Member Name="get_MinorVersion" />
<Member MemberType="Property" Name="MinorVersion" />
</Type>
<Type Name="System.Runtime.InteropServices.CriticalHandle">
<Member MemberType="Field" Name="handle" />
<Member MemberType="Field" Name="_stackTrace" Flavor="chk,dbg" />
Expand Down Expand Up @@ -9976,7 +10049,7 @@
<Member Name="AddField(System.String)" /> <!-- EE -->
<Member Name="RemoveMember(System.Reflection.MemberInfo)" /> <!-- EE -->
</Type>
<Type Status="ImplRoot" Name="System.Runtime.InteropServices.ICustomMarshaler">
<Type Name="System.Runtime.InteropServices.ICustomMarshaler">
<Member Name="MarshalNativeToManaged(System.IntPtr)" /> <!-- EE -->
<Member Name="MarshalManagedToNative(System.Object)" /> <!-- EE -->
<Member Name="CleanUpNativeData(System.IntPtr)" /> <!-- EE -->
Expand Down
2 changes: 1 addition & 1 deletion src/mscorlib/mscorlib.shared.sources.props
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@
<InteropSources Condition="'$(FeatureCominterop)' != 'true'" Include="$(BclSourcesRoot)\System\Runtime\InteropServices\NonPortable.cs" />
<InteropSources Condition="'$(FeatureCominterop)' == 'true'" Include="$(BclSourcesRoot)\System\Runtime\InteropServices\DispatchWrapper.cs" />
<InteropSources Condition="'$(FeatureCominterop)' == 'true'" Include="$(BclSourcesRoot)\System\Runtime\InteropServices\ExtensibleClassFactory.cs" />
<InteropSources Condition="'$(FeatureCominterop)' == 'true'" Include="$(BclSourcesRoot)\System\Runtime\InteropServices\ICustomFactory.cs" />
<InteropSources Include="$(BclSourcesRoot)\System\Runtime\InteropServices\ICustomFactory.cs" />
<InteropSources Condition="'$(FeatureCominterop)' == 'true'" Include="$(BclSourcesRoot)\System\Runtime\InteropServices\ObjectCreationDelegate.cs" />
</ItemGroup>
<ItemGroup Condition="'$(FeatureClassicCominterop)' == 'true'">
Expand Down
108 changes: 108 additions & 0 deletions src/mscorlib/ref/mscorlib.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10382,6 +10382,13 @@ public sealed partial class AllowReversePInvokeCallsAttribute : System.Attribute
{
public AllowReversePInvokeCallsAttribute() { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1029), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class AutomationProxyAttribute : System.Attribute
{
public AutomationProxyAttribute(bool val) { }
public bool Value { get { throw null; } }
}
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public partial struct ArrayWithOffset
Expand Down Expand Up @@ -10454,6 +10461,29 @@ public sealed partial class CoClassAttribute : System.Attribute
public CoClassAttribute(System.Type coClass) { }
public System.Type CoClass { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(10624), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComAliasNameAttribute : System.Attribute
{
public ComAliasNameAttribute(String val) { }
public String Value { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComCompatibleVersionAttribute : System.Attribute
{
public ComCompatibleVersionAttribute(System.Int32 major, System.Int32 minor, System.Int32 build, System.Int32 revision) { }
public System.Int32 MajorVersion { get { throw null; } }
public System.Int32 MinorVersion { get { throw null; } }
public System.Int32 BuildNumber { get { throw null;} }
public System.Int32 RevisionNumber { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(32767), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComConversionLossAttribute : Attribute
{
public ComConversionLossAttribute() { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(4), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComDefaultInterfaceAttribute : System.Attribute
Expand Down Expand Up @@ -10508,6 +10538,12 @@ public enum ComMemberType
PropGet = 1,
PropSet = 2,
}
[System.AttributeUsageAttribute((System.AttributeTargets)(64), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComRegisterFunctionAttribute : Attribute
{
public ComRegisterFunctionAttribute() { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(4), Inherited=true)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComSourceInterfacesAttribute : System.Attribute
Expand All @@ -10519,6 +10555,12 @@ public ComSourceInterfacesAttribute(System.Type sourceInterface1, System.Type so
public ComSourceInterfacesAttribute(System.Type sourceInterface1, System.Type sourceInterface2, System.Type sourceInterface3, System.Type sourceInterface4) { }
public string Value { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(64), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComUnregisterFunctionAttribute : Attribute
{
public ComUnregisterFunctionAttribute() { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(5597), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ComVisibleAttribute : System.Attribute
Expand Down Expand Up @@ -10690,12 +10732,33 @@ public partial interface ICustomAdapter
{
object GetUnderlyingObject();
}
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public partial interface ICustomFactory
{
MarshalByRefObject CreateInstance(Type serverType);
}
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public partial interface ICustomMarshaler
{
object MarshalNativeToManaged(System.IntPtr pNativeData);
System.IntPtr MarshalManagedToNative(object ManagedObj);
void CleanUpNativeData(System.IntPtr pNativeData);
void CleanUpManagedData(object ManagedObj);
int GetNativeDataSize();
}
[System.Runtime.InteropServices.ComVisibleAttribute(false)]
public partial interface ICustomQueryInterface
{
[System.Security.SecurityCriticalAttribute]
System.Runtime.InteropServices.CustomQueryInterfaceResult GetInterface(ref System.Guid iid, out System.IntPtr ppv);
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ImportedFromTypeLibAttribute : System.Attribute
{
public ImportedFromTypeLibAttribute(String val) { }
public String Value { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(2048), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class InAttribute : System.Attribute
Expand Down Expand Up @@ -10733,6 +10796,13 @@ public enum LayoutKind
Explicit = 2,
Sequential = 0,
}
[System.AttributeUsageAttribute((System.AttributeTargets)(64), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class LCIDConversionAttribute : System.Attribute
{
public LCIDConversionAttribute(System.Int32 val) { }
public System.Int32 Value { get { throw null; } }
}
[System.Security.SecurityCriticalAttribute]
public static partial class Marshal
{
Expand Down Expand Up @@ -11020,6 +11090,14 @@ public static void ZeroFreeGlobalAllocAnsi(System.IntPtr s) { }
[System.Security.SecurityCriticalAttribute]
public static void ZeroFreeGlobalAllocUnicode(System.IntPtr s) { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(64), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ManagedToNativeComInteropStubAttribute : System.Attribute
{
public ManagedToNativeComInteropStubAttribute(System.Type classType, System.String methodName) { }
public System.Type ClassType { get { throw null; } }
public System.String MethodName { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(10496), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class MarshalAsAttribute : System.Attribute
Expand Down Expand Up @@ -11072,6 +11150,21 @@ public sealed partial class PreserveSigAttribute : System.Attribute
{
public PreserveSigAttribute() { }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1), Inherited=false, AllowMultiple = true)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class PrimaryInteropAssemblyAttribute : System.Attribute
{
public PrimaryInteropAssemblyAttribute(System.Int32 major, System.Int32 minor) { }
public System.Int32 MajorVersion { get { throw null; } }
public System.Int32 MinorVersion { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(4), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class ProgIdAttribute : System.Attribute
{
public ProgIdAttribute(String val) { }
public String Value { get { throw null; } }
}
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public partial class SafeArrayRankMismatchException : System.SystemException
{
Expand Down Expand Up @@ -11166,6 +11259,21 @@ public TypeIdentifierAttribute(string scope, string identifier) { }
public string Identifier { get { throw null; } }
public string Scope { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1024), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class TypeLibImportClassAttribute : System.Attribute
{
public TypeLibImportClassAttribute(System.Type val) { }
public String Value { get { throw null; } }
}
[System.AttributeUsageAttribute((System.AttributeTargets)(1), Inherited=false)]
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class TypeLibVersionAttribute : System.Attribute
{
public TypeLibVersionAttribute(System.Int32 major, System.Int32 minor) { }
public System.Int32 MajorVersion { get { throw null; } }
public System.Int32 MinorVersion { get { throw null; } }
}
[System.Runtime.InteropServices.ComVisibleAttribute(true)]
public sealed partial class UnknownWrapper
{
Expand Down

0 comments on commit e8c4f54

Please sign in to comment.