Ejemplo n.º 1
0
        private LifecycleContext(string apiNamespace, string modelNamespace, SwaggerJsonLoader loader, SwaseyOperationWriter operationWriter, SwaseyEnumWriter enumWriter, SwaseyModelWriter modelWriter)
        {
            ApiNamespace = apiNamespace ?? Defaults.DefaultApiNamespace;
            ModelNamespace = modelNamespace ?? Defaults.DefaultModelNamespace;

            ServiceMetadata = new ServiceMetadata(ApiNamespace, ModelNamespace);

            ServiceDefinition = new ServiceDefinition();

            Loader = loader ?? Defaults.DefaultSwaggerJsonLoader;
            OperationWriter = operationWriter ?? Defaults.DefaultSwaseyOperationWriter;
            EnumWriter = enumWriter ?? Defaults.DefaultSwaseyEnumWriter;
            ModelWriter = modelWriter ?? Defaults.DefaultSwaseyModelWriter;

            ApiPathJsonMapping = new Dictionary<string, dynamic>();

            NormalizationContext = new NormalizationContext();
        }
Ejemplo n.º 2
0
        private LifecycleContext(string apiNamespace, string modelNamespace, SwaggerJsonLoader loader, SwaseyOperationWriter operationWriter, SwaseyEnumWriter enumWriter, SwaseyModelWriter modelWriter)
        {
            ApiNamespace   = apiNamespace ?? Defaults.DefaultApiNamespace;
            ModelNamespace = modelNamespace ?? Defaults.DefaultModelNamespace;

            ServiceMetadata = new ServiceMetadata(ApiNamespace, ModelNamespace);

            ServiceDefinition = new ServiceDefinition();

            Loader          = loader ?? Defaults.DefaultSwaggerJsonLoader;
            OperationWriter = operationWriter ?? Defaults.DefaultSwaseyOperationWriter;
            EnumWriter      = enumWriter ?? Defaults.DefaultSwaseyEnumWriter;
            ModelWriter     = modelWriter ?? Defaults.DefaultSwaseyModelWriter;

            ApiPathJsonMapping = new Dictionary <string, dynamic>();

            NormalizationContext = new NormalizationContext();
        }