private static ISubstitutionParameter CreateSubstitutionParameterCore(IEnvironment environment, string subValueName, out ConfigurationContext context) { context = (ConfigurationContext)ContainerFactory.Current.Resolve(typeof(ConfigurationContext), Scope.Context); if (context.IsNull()) { throw new CommunicationException("Unable to get database"); } var subValue = context.SubstitutionParameters.Create(); subValue.Name = subValueName; subValue.Environment = environment; subValue.EnvironmentNameId = environment.Id; return(subValue); }
private static ISubstitutionParameter CreateSubstitutionParameterCore(IEnvironment environment, string subValueName, out ConfigurationContext context) { context = (ConfigurationContext)ContainerFactory.Current.Resolve(typeof(ConfigurationContext), Scope.Context); if (context.IsNull()) throw new CommunicationException("Unable to get database"); var subValue = context.SubstitutionParameters.Create(); subValue.Name = subValueName; subValue.Environment = environment; subValue.EnvironmentNameId = environment.Id; return subValue; }