public GenericTypeRefResolver(TypeRefResolver baseResolver, TypeRefBuilder[] genericArgs) { _baseResolver = baseResolver; _genericArgs = genericArgs; if (genericArgs.Length == 0) { throw new WeavingException("No generic arguments supplied"); } }
public ArrayTypeRefResolver(TypeRefResolver baseResolver, int rank) : base(baseResolver) { _rank = rank; if (rank < 1) { throw new WeavingException($"Invalid array rank: {rank}, must be at least 1"); } }
public TypeRefBuilder(ModuleDefinition module, GenericParameterType genericParameterType, int genericParameterIndex) { _module = module; _resolver = new GenericParameterTypeRefResolver(genericParameterType, genericParameterIndex); }
public TypeRefBuilder(ModuleDefinition module, TypeReference typeRef) { _module = module; _resolver = new ConstantTypeRefResolver(typeRef); }
public void MakeGenericType(TypeRefBuilder[] genericArgs) => _resolver = new GenericTypeRefResolver(_resolver, genericArgs);
public void MakeArrayType(int rank) => _resolver = new ArrayTypeRefResolver(_resolver, rank);
public void MakeByRefType() => _resolver = new ByRefTypeRefResolver(_resolver);
public void MakePointerType() => _resolver = new PointerTypeRefResolver(_resolver);
public PointerTypeRefResolver(TypeRefResolver baseResolver) : base(baseResolver) { }
public ByRefTypeRefResolver(TypeRefResolver baseResolver) : base(baseResolver) { }
protected TypeSpecTypeRefResolver(TypeRefResolver baseResolver) => _baseResolver = baseResolver;