Package system.reflection.emit
Class ModuleBuilder
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.reflection.Module
-
- system.reflection.emit.ModuleBuilder
-
- All Implemented Interfaces:
IJCOBridgeReflected
public class ModuleBuilder extends Module
The base .NET class managing System.Reflection.Emit.ModuleBuilder, System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.Reflection.Emit.ModuleBuilder
Powered by JCOBridge: more info at https://www.jcobridge.com
- Author:
- MASES s.r.l https://masesgroup.com
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
assemblyFullName
Fully assembly qualified name: System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798estatic java.lang.String
assemblyShortName
Assembly name: System.Private.CoreLibstatic java.lang.String
className
Qualified class name: System.Reflection.Emit.ModuleBuilderstatic JCType
classType
The type managed from JCOBridge.
-
Constructor Summary
Constructors Constructor Description ModuleBuilder()
ModuleBuilder(java.lang.Object instance)
Internal constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ModuleBuilder
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoModuleBuilder
, a cast assert is made to check if types are compatible.void
CreateGlobalFunctions()
ISymbolDocumentWriter
DefineDocument(java.lang.String url, Guid language)
ISymbolDocumentWriter
DefineDocument(java.lang.String url, Guid language, Guid languageVendor, Guid documentType)
EnumBuilder
DefineEnum(java.lang.String name, TypeAttributes visibility, NetType underlyingType)
MethodBuilder
DefineGlobalMethod(java.lang.String name, MethodAttributes attributes, NetType returnType, NetType[] parameterTypes)
MethodBuilder
DefineGlobalMethod(java.lang.String name, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes)
FieldBuilder
DefineInitializedData(java.lang.String name, byte[] data, FieldAttributes attributes)
FieldBuilder
DefineInitializedData(java.lang.String dupParam0, JCORefOut dupParam1, FieldAttributes dupParam2)
MethodBuilder
DefinePInvokeMethod(java.lang.String name, java.lang.String dllName, java.lang.String entryName, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes, CallingConvention nativeCallConv, CharSet nativeCharSet)
MethodBuilder
DefinePInvokeMethod(java.lang.String name, java.lang.String dllName, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes, CallingConvention nativeCallConv, CharSet nativeCharSet)
TypeBuilder
DefineType(java.lang.String name)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr, NetType parent)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr, NetType parent, int typesize)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr, NetType parent, NetType[] interfaces)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr, NetType parent, PackingSize packsize)
TypeBuilder
DefineType(java.lang.String name, TypeAttributes attr, NetType parent, PackingSize packingSize, int typesize)
FieldBuilder
DefineUninitializedData(java.lang.String name, int size, FieldAttributes attributes)
MethodInfo
GetArrayMethod(NetType arrayClass, java.lang.String methodName, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes)
int
GetFieldMetadataToken(FieldInfo field)
java.lang.String
getJCOAssemblyName()
Returns the reflected Assembly namejava.lang.String
getJCOClassName()
Returns the reflected Class namejava.lang.Object
getJCOInstance()
Returns the instantiated classjava.lang.String
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class Typeint
GetMethodMetadataToken(ConstructorInfo constructor)
int
GetMethodMetadataToken(MethodInfo method)
int
GetSignatureMetadataToken(SignatureHelper signature)
int
GetStringMetadataToken(java.lang.String stringConstant)
int
GetTypeMetadataToken(NetType type)
void
SetCustomAttribute(ConstructorInfo con, byte[] binaryAttribute)
void
SetCustomAttribute(ConstructorInfo dupParam0, JCORefOut dupParam1)
void
SetCustomAttribute(CustomAttributeBuilder customBuilder)
void
setJCOInstance(JCObject instance)
-
Methods inherited from class system.reflection.Module
FindTypes, getAssembly, GetCustomAttributes, GetCustomAttributes, GetField, GetField, GetFields, GetFields, getFullyQualifiedName, getMDStreamVersion, getMetadataToken, GetMethod, GetMethod, GetMethod, GetMethods, GetMethods, getModuleHandle, getModuleVersionId, getName, GetObjectData, GetPEKind, getScopeName, GetType, GetType, GetType, GetTypes, IsDefined, IsResource, ResolveField, ResolveField, ResolveMember, ResolveMember, ResolveMethod, ResolveMethod, ResolveSignature, ResolveString, ResolveType, ResolveType
-
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: System.Private.CoreLib, Version=9.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e- See Also:
- Constant Field Values
-
assemblyShortName
public static final java.lang.String assemblyShortName
Assembly name: System.Private.CoreLib- See Also:
- Constant Field Values
-
className
public static final java.lang.String className
Qualified class name: System.Reflection.Emit.ModuleBuilder- See Also:
- Constant Field Values
-
-
Method Detail
-
getJCOAssemblyName
public java.lang.String getJCOAssemblyName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Assembly name- Specified by:
getJCOAssemblyName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOAssemblyName
in classModule
- Returns:
- A
String
representing the Fullname of reflected Assembly
-
getJCOClassName
public java.lang.String getJCOClassName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name- Specified by:
getJCOClassName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOClassName
in classModule
- Returns:
- A
String
representing the Fullname of reflected Class
-
getJCOObjectName
public java.lang.String getJCOObjectName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name used to build the object- Specified by:
getJCOObjectName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOObjectName
in classModule
- Returns:
- A
String
representing the name used to allocated the object in CLR context
-
getJCOInstance
public java.lang.Object getJCOInstance()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class- Specified by:
getJCOInstance
in interfaceIJCOBridgeReflected
- Overrides:
getJCOInstance
in classModule
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classModule
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Overrides:
getJCOType
in classModule
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static ModuleBuilder cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoModuleBuilder
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
ModuleBuilder
instance- Throws:
java.lang.Throwable
- in case of error during cast operation
-
GetFieldMetadataToken
public int GetFieldMetadataToken(FieldInfo field) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetMethodMetadataToken
public int GetMethodMetadataToken(ConstructorInfo constructor) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetMethodMetadataToken
public int GetMethodMetadataToken(MethodInfo method) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetSignatureMetadataToken
public int GetSignatureMetadataToken(SignatureHelper signature) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetStringMetadataToken
public int GetStringMetadataToken(java.lang.String stringConstant) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetTypeMetadataToken
public int GetTypeMetadataToken(NetType type) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefineDocument
public ISymbolDocumentWriter DefineDocument(java.lang.String url, Guid language, Guid languageVendor, Guid documentType) throws java.lang.Throwable, ArgumentNullException, ArgumentException, InvalidOperationException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
InvalidOperationException
-
DefineDocument
public ISymbolDocumentWriter DefineDocument(java.lang.String url, Guid language) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException, InvalidOperationException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
InvalidOperationException
-
DefineEnum
public EnumBuilder DefineEnum(java.lang.String name, TypeAttributes visibility, NetType underlyingType) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
-
DefineInitializedData
public FieldBuilder DefineInitializedData(java.lang.String name, byte[] data, FieldAttributes attributes) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefineInitializedData
public FieldBuilder DefineInitializedData(java.lang.String dupParam0, JCORefOut dupParam1, FieldAttributes dupParam2) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefineUninitializedData
public FieldBuilder DefineUninitializedData(java.lang.String name, int size, FieldAttributes attributes) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefineGlobalMethod
public MethodBuilder DefineGlobalMethod(java.lang.String name, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefineGlobalMethod
public MethodBuilder DefineGlobalMethod(java.lang.String name, MethodAttributes attributes, NetType returnType, NetType[] parameterTypes) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefinePInvokeMethod
public MethodBuilder DefinePInvokeMethod(java.lang.String name, java.lang.String dllName, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes, CallingConvention nativeCallConv, CharSet nativeCharSet) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefinePInvokeMethod
public MethodBuilder DefinePInvokeMethod(java.lang.String name, java.lang.String dllName, java.lang.String entryName, MethodAttributes attributes, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes, CallingConvention nativeCallConv, CharSet nativeCharSet) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr, NetType parent, int typesize) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr, NetType parent, PackingSize packingSize, int typesize) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr, NetType parent, PackingSize packsize) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr, NetType parent, NetType[] interfaces) throws java.lang.Throwable, NotSupportedException, ArgumentException, ArgumentNullException
- Throws:
java.lang.Throwable
NotSupportedException
ArgumentException
ArgumentNullException
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr, NetType parent) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefineType
public TypeBuilder DefineType(java.lang.String name, TypeAttributes attr) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
DefineType
public TypeBuilder DefineType(java.lang.String name) throws java.lang.Throwable, ArgumentNullException, ArgumentException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
-
GetArrayMethod
public MethodInfo GetArrayMethod(NetType arrayClass, java.lang.String methodName, CallingConventions callingConvention, NetType returnType, NetType[] parameterTypes) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
CreateGlobalFunctions
public void CreateGlobalFunctions() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
SetCustomAttribute
public void SetCustomAttribute(ConstructorInfo con, byte[] binaryAttribute) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
SetCustomAttribute
public void SetCustomAttribute(ConstructorInfo dupParam0, JCORefOut dupParam1) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
SetCustomAttribute
public void SetCustomAttribute(CustomAttributeBuilder customBuilder) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
-