public DimensionLevel(DimensionConfig dimconfig, int levelIndex) { typeOf = DimensionType.Date; this.Config = dimconfig; _level = levelIndex; LevelDimensions = new List <DimensionLevel <T> >(); }
// private MemberDateTimeCollection<T> _members; public DimensionDateTime(DimensionConfig dimconfig, DateTimeLevels level, int levelIndex) { typeOf = DimensionType.Date; this.Config = dimconfig; DateLevel = level; _level = levelIndex; LevelDimensions = new List <DimensionDateTime <T> >(); }
public Dimension(DimensionConfig dimconfig, IDataSource datasource) : this() { this.Config = dimconfig; this.DataSource = datasource; }
/// <summary> /// Emits the usage event to the configured MARKETPLACEAPI_URI. /// </summary> private static async Task <HttpResponseMessage> EmitUsageEvents(IConfigurationRoot config, HttpClient httpClient, DimensionConfig dimensionConfig, BillingEntry billingEntry) { var usageEvent = new UsageEventDefinition { ResourceId = billingEntry.resourceUsageId, Quantity = dimensionConfig.Quantity, Dimension = dimensionConfig.Dimension, EffectiveStartTime = DateTime.UtcNow, PlanId = billingEntry.planId }; if (CronJob.IsLocalRun(config)) { return(new HttpResponseMessage { Content = new StringContent(JsonConvert.SerializeObject(usageEvent), UnicodeEncoding.UTF8, "application/json"), StatusCode = HttpStatusCode.OK }); } return(await httpClient.PostAsJsonAsync(config["MARKETPLACEAPI_URI"], usageEvent).ConfigureAwait(continueOnCapturedContext: false)); }
private void Awake() { instance = this; }
public DimensionBuilder() { _element = new DimensionConfig(); }