Example #1
0
 public void Configure(ConventionBasedCodingStyle codingStyle, IKernel kernel)
 {
     codingStyle
     .AddTypes(
         v => v.WebService("Unity", s => s
                           .Methods.Add(o => o.Proxy <IAccountManagerService>("CreateAccount").TargetBySingleton(kernel))
                           )
         );
 }
Example #2
0
 public static ConventionBasedCodingStyle AddCommonSystemTypes(this ConventionBasedCodingStyle source) =>
 source.AddTypes(
     typeof(void),
     typeof(bool),
     typeof(byte),
     typeof(short),
     typeof(ushort),
     typeof(int),
     typeof(uint),
     typeof(long),
     typeof(ulong),
     typeof(float),
     typeof(double),
     typeof(decimal),
     typeof(TimeSpan),
     typeof(DateTime),
     typeof(Guid),
     typeof(string)
     );
Example #3
0
 public static ConventionBasedCodingStyle AddTypes(this ConventionBasedCodingStyle source,
                                                   params Func <VirtualTypeBuilder, VirtualType>[] typeBuilders
                                                   ) => source.AddTypes(typeBuilders.Select(builder => builder(BuildRoutine.VirtualType())));