var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
import CaptureSpan from "../../../Utils/Telemetry/CaptureSpan";
import ActiveMonitoringMeteredPlanType from "./ActiveMonitoringMeteredPlan";
import ServerMeteredPlan from "./ServerMeteredPlan";
import TelemetryMeteredPlanType from "./TelemetryMeteredPlan";
import BadDataException from "../../../../Types/Exception/BadDataException";
import ProductType from "../../../../Types/MeteredPlan/ProductType";
export const ActiveMonitoringMeteredPlan = new ActiveMonitoringMeteredPlanType();
export const LogDataIngestMeteredPlan = new TelemetryMeteredPlanType({
    productType: ProductType.Logs,
    unitCostInUSD: 0.1 / 15, // 0.10 per 15 days per GB
});
export const MetricsDataIngestMeteredPlan = new TelemetryMeteredPlanType({
    productType: ProductType.Metrics,
    unitCostInUSD: 0.1 / 15, // 0.10 per 15 days per GB
});
export const TracesDataIngestMetredPlan = new TelemetryMeteredPlanType({
    productType: ProductType.Traces,
    unitCostInUSD: 0.1 / 15, // 0.10 per 15 days per GB
});
export const ProfilesDataIngestMeteredPlan = new TelemetryMeteredPlanType({
    productType: ProductType.Profiles,
    unitCostInUSD: 0.1 / 15, // 0.10 per 15 days per GB
});
const AllMeteredPlans = [
    ActiveMonitoringMeteredPlan,
    LogDataIngestMeteredPlan,
    MetricsDataIngestMeteredPlan,
    TracesDataIngestMetredPlan,
    ProfilesDataIngestMeteredPlan,
];
export class MeteredPlanUtil {
    static getMeteredPlanByProductType(productType) {
        if (productType === ProductType.Logs) {
            return LogDataIngestMeteredPlan;
        }
        else if (productType === ProductType.Metrics) {
            return MetricsDataIngestMeteredPlan;
        }
        else if (productType === ProductType.Traces) {
            return TracesDataIngestMetredPlan;
        }
        else if (productType === ProductType.Profiles) {
            return ProfilesDataIngestMeteredPlan;
        }
        else if (productType === ProductType.ActiveMonitoring) {
            return ActiveMonitoringMeteredPlan;
        }
        throw new BadDataException(`Unknown product type ${productType}`);
    }
}
__decorate([
    CaptureSpan(),
    __metadata("design:type", Function),
    __metadata("design:paramtypes", [String]),
    __metadata("design:returntype", ServerMeteredPlan)
], MeteredPlanUtil, "getMeteredPlanByProductType", null);
export default AllMeteredPlans;
//# sourceMappingURL=AllMeteredPlans.js.map