5 implementations of IBoundMarshallingGenerator
Microsoft.Interop.JavaScript.JSImportGenerator (1)
Marshaling\BaseJSGenerator.cs (1)
8internal abstract class BaseJSGenerator(TypePositionInfo info, StubCodeContext codeContext) : IBoundMarshallingGenerator
Microsoft.Interop.SourceGeneration (4)
Marshalling\CustomTypeMarshallingGenerator.cs (1)
10: IBoundMarshallingGenerator
Marshalling\MarshallingGenerator.cs (1)
150internal sealed class BoundMarshallingGenerator(TypePositionInfo info, StubCodeContext context, IUnboundMarshallingGenerator unbound) : IBoundMarshallingGenerator
Marshalling\StaticPinnableManagedValueMarshaller.cs (1)
6public sealed class StaticPinnableManagedValueMarshaller(IBoundMarshallingGenerator innerMarshallingGenerator, string getPinnableReferenceType) : IBoundMarshallingGenerator
Marshalling\UnmanagedToManagedOwnershipTrackingStrategy.cs (1)
94internal sealed class FreeAlwaysOwnedOriginalValueGenerator(IBoundMarshallingGenerator inner) : IBoundMarshallingGenerator
54 references to IBoundMarshallingGenerator
Microsoft.Interop.JavaScript.JSImportGenerator (1)
JSGeneratorFactory.cs (1)
336ResolvedGeneratorAndType resolved(IBoundMarshallingGenerator generator, MarshalerType baseType, IEnumerable<MarshalerType>? subTypes = null)
Microsoft.Interop.SourceGeneration (53)
BoundGenerators.cs (22)
20IBoundMarshallingGenerator defaultBoundGenerator = fallbackGenerator.Bind(new TypePositionInfo(SpecialTypeInfo.Void, NoMarshallingInfo.Instance), context); 23ImmutableArray<IBoundMarshallingGenerator>.Builder signatureMarshallers = ImmutableArray.CreateBuilder<IBoundMarshallingGenerator>(); 24ImmutableArray<IBoundMarshallingGenerator>.Builder nativeParamMarshallers = ImmutableArray.CreateBuilder<IBoundMarshallingGenerator>(); 25ImmutableArray<IBoundMarshallingGenerator>.Builder managedParamMarshallers = ImmutableArray.CreateBuilder<IBoundMarshallingGenerator>(); 27IBoundMarshallingGenerator managedReturnMarshaller = defaultBoundGenerator; 28IBoundMarshallingGenerator nativeReturnMarshaller = defaultBoundGenerator; 29IBoundMarshallingGenerator managedExceptionMarshaller = defaultBoundGenerator; 42IBoundMarshallingGenerator generator = CreateGenerator(argType, generatorResolver); 70IBoundMarshallingGenerator? overlappedMarshaller = FindOverlappedMarshaller(errorHandlingInfo); 77IBoundMarshallingGenerator errorHandlingMarshaller = CreateGenerator(errorHandlingInfo, errorHandlerFactory); 96IBoundMarshallingGenerator? overlappedMarshaller = null; 209IBoundMarshallingGenerator? FindOverlappedMarshaller(TypePositionInfo info) 224IBoundMarshallingGenerator CreateGenerator(TypePositionInfo p, IMarshallingGeneratorResolver factory) 232public IBoundMarshallingGenerator ManagedReturnMarshaller { get; private init; } 234public IBoundMarshallingGenerator NativeReturnMarshaller { get; private init; } 236public IBoundMarshallingGenerator ManagedExceptionMarshaller { get; private init; } 238public ImmutableArray<IBoundMarshallingGenerator> SignatureMarshallers { get; private init; } 240public ImmutableArray<IBoundMarshallingGenerator> ManagedParameterMarshallers { get; private init; } 242public ImmutableArray<IBoundMarshallingGenerator> NativeParameterMarshallers { get; private init; }
GeneratedStatements.cs (3)
53foreach (IBoundMarshallingGenerator marshaller in marshallers.SignatureMarshallers) 96IBoundMarshallingGenerator valueMarshaller = marshallers.ManagedParameterMarshallers.Last(); 143IBoundMarshallingGenerator marshaller = marshallers.ManagedExceptionMarshaller;
ManagedToNativeStubGenerator.cs (1)
74foreach (IBoundMarshallingGenerator generator in _marshallers.SignatureMarshallers)
Marshalling\AttributedMarshallingModelGeneratorResolver.cs (4)
180IBoundMarshallingGenerator marshallingGenerator = new CustomTypeMarshallingGenerator(marshallingStrategy, ByValueMarshalKindSupportDescriptor.Default, marshallerData.Shape.HasFlag(MarshallerShape.StatelessPinnableReference)); 211IBoundMarshallingGenerator elementMarshaller = resolvedElementMarshaller.Generator; 309IBoundMarshallingGenerator marshallingGenerator = new CustomTypeMarshallingGenerator(marshallingStrategy, byValueMarshalKindSupport, isPinned); 359private static ElementsMarshalling CreateElementsMarshalling(CustomTypeMarshallerData marshallerData, IBoundMarshallingGenerator elementMarshaller, string unmanagedElementType, IElementsMarshallingCollectionSource collectionSource)
Marshalling\ElementsMarshalling.cs (3)
149IBoundMarshallingGenerator elementMarshaller, 263IBoundMarshallingGenerator elementMarshaller, 323IBoundMarshallingGenerator elementMarshaller,
Marshalling\MarshallingGenerator.cs (1)
183public static IBoundMarshallingGenerator Bind(this IUnboundMarshallingGenerator unbound, TypePositionInfo info, StubCodeContext context) => new BoundMarshallingGenerator(info, context, unbound);
Marshalling\MarshallingGeneratorExtensions.cs (8)
16public static string AsReturnType(this IBoundMarshallingGenerator generator) 30public static string? GenerateAttributesForReturnType(this IBoundMarshallingGenerator generator) 45public static GeneratedParameter AsParameter(this IBoundMarshallingGenerator generator, StubIdentifierContext context) 119public static string AsArgument(this IBoundMarshallingGenerator generator, StubIdentifierContext context) 134public static string AsManagedArgument(this IBoundMarshallingGenerator generator, StubIdentifierContext context) 143public static string GenerateNativeByRefInitialization(this IBoundMarshallingGenerator generator, StubIdentifierContext context) 149public static bool IsForwarder(this IBoundMarshallingGenerator generator) => generator is BoundMarshallingGenerator { IsForwarder: true }; 151public static bool IsBlittable(this IBoundMarshallingGenerator generator) => generator is BoundMarshallingGenerator { IsBlittable: true };
Marshalling\ResolvedGenerator.cs (3)
10public record struct ResolvedGenerator([property: MemberNotNullWhen(true, nameof(ResolvedGenerator.IsResolved), nameof(ResolvedGenerator.IsResolvedWithoutErrors))] IBoundMarshallingGenerator? Generator, ImmutableArray<GeneratorDiagnostic> Diagnostics) 20public static ResolvedGenerator Resolved(IBoundMarshallingGenerator generator) 30public static ResolvedGenerator ResolvedWithDiagnostics(IBoundMarshallingGenerator generator, ImmutableArray<GeneratorDiagnostic> diagnostics)
Marshalling\StaticPinnableManagedValueMarshaller.cs (1)
6public sealed class StaticPinnableManagedValueMarshaller(IBoundMarshallingGenerator innerMarshallingGenerator, string getPinnableReferenceType) : IBoundMarshallingGenerator
Marshalling\UnmanagedToManagedOwnershipTrackingStrategy.cs (1)
94internal sealed class FreeAlwaysOwnedOriginalValueGenerator(IBoundMarshallingGenerator inner) : IBoundMarshallingGenerator
UnmanagedToManagedStubGenerator.cs (1)
64ImmutableArray<IBoundMarshallingGenerator> parameters = _marshallers.ManagedParameterMarshallers;
VariableDeclarations.cs (5)
14foreach (IBoundMarshallingGenerator marshaller in marshallers.NativeParameterMarshallers) 37foreach (IBoundMarshallingGenerator errorMarshaller in marshallers.SignatureMarshallers) 48void AppendVariableDeclarations(IBoundMarshallingGenerator marshaller) 65foreach (IBoundMarshallingGenerator marshaller in marshallers.NativeParameterMarshallers) 84void AppendVariableDeclarations(IBoundMarshallingGenerator marshaller)