diff --git a/src/protobuf-net.Grpc.Reflection/SchemaGenerator.cs b/src/protobuf-net.Grpc.Reflection/SchemaGenerator.cs
index f566d58..24269f0 100644
--- a/src/protobuf-net.Grpc.Reflection/SchemaGenerator.cs
+++ b/src/protobuf-net.Grpc.Reflection/SchemaGenerator.cs
@@ -17,7 +17,15 @@ public sealed class SchemaGenerator
///
/// Gets or sets the syntax version
///
- public ProtoSyntax ProtoSyntax { get; set; } = ProtoSyntax.Proto3;
+ public ProtoSyntax ProtoSyntax { get => Options.Syntax; set => Options.Syntax = value; }
+
+ ///
+ /// Gets or sets the options for the generation of the schema.
+ ///
+ public SchemaGenerationOptions Options { get; set; } = new SchemaGenerationOptions
+ {
+ Syntax = ProtoSyntax.Proto3
+ };
///
/// Gets or sets the binder configuration (the default configuration is used if omitted)
@@ -118,8 +126,10 @@ public string GetSchema(params Type[] contractTypes)
var options = new SchemaGenerationOptions
{
- Syntax = ProtoSyntax,
+ Syntax = Options.Syntax,
Package = globalPackage,
+ Flags = Options.Flags,
+ Origin = Options.Origin,
};
options.Services.AddRange(services);