예제 #1
0
 /// <summary>See TypeModel.GetSchema</summary>
 public override string GetSchema(Type type, ProtoSyntax syntax)
 => ForAssembly(type).GetSchema(type, syntax);
예제 #2
0
 /// <summary>
 /// Suggest a .proto definition for the given type
 /// </summary>
 /// <typeparam name="T">The type to generate a .proto definition for</typeparam>
 /// <returns>The .proto definition as a string</returns>
 public static string GetProto <T>(ProtoSyntax syntax)
 {
     return(RuntimeTypeModel.Default.GetSchema(typeof(T), syntax));
 }
예제 #3
0
 public string GetDataModel(ProtoSyntax syntax = ProtoSyntax.Proto3)
 {
     return(RuntimeTypeModel.Default.GetSchema(GetType(), syntax));
 }