/*
 * Copyright (c) Microsoft Corporation. All rights reserved.
 * Licensed under the MIT License. See License.txt in the project root for
 * license information.
 *
 * Code generated by Microsoft (R) AutoRest Code Generator.
 * Changes may cause incorrect behavior and will be lost if the code is
 * regenerated.
 */

import { CloudErrorMapper, BaseResourceMapper } from "@azure/ms-rest-azure-js";
import * as msRest from "@azure/ms-rest-js";

export const CloudError = CloudErrorMapper;
export const BaseResource = BaseResourceMapper;

export const SkuCapacity: msRest.CompositeMapper = {
  serializedName: "SkuCapacity",
  type: {
    name: "Composite",
    className: "SkuCapacity",
    modelProperties: {
      minimum: {
        readOnly: true,
        serializedName: "minimum",
        type: {
          name: "Number"
        }
      },
      maximum: {
        readOnly: true,
        serializedName: "maximum",
        type: {
          name: "Number"
        }
      },
      default: {
        readOnly: true,
        serializedName: "default",
        type: {
          name: "Number"
        }
      },
      scaleType: {
        readOnly: true,
        serializedName: "scaleType",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const SkuCapability: msRest.CompositeMapper = {
  serializedName: "SkuCapability",
  type: {
    name: "Composite",
    className: "SkuCapability",
    modelProperties: {
      name: {
        readOnly: true,
        serializedName: "name",
        type: {
          name: "String"
        }
      },
      value: {
        readOnly: true,
        serializedName: "value",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const SkuCost: msRest.CompositeMapper = {
  serializedName: "SkuCost",
  type: {
    name: "Composite",
    className: "SkuCost",
    modelProperties: {
      meterID: {
        readOnly: true,
        serializedName: "meterID",
        type: {
          name: "String"
        }
      },
      quantity: {
        readOnly: true,
        serializedName: "quantity",
        type: {
          name: "Number"
        }
      },
      extendedUnit: {
        readOnly: true,
        serializedName: "extendedUnit",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const SkuRestrictions: msRest.CompositeMapper = {
  serializedName: "SkuRestrictions",
  type: {
    name: "Composite",
    className: "SkuRestrictions",
    modelProperties: {
      type: {
        readOnly: true,
        serializedName: "type",
        type: {
          name: "String"
        }
      },
      values: {
        readOnly: true,
        serializedName: "values",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "String"
            }
          }
        }
      },
      reasonCode: {
        readOnly: true,
        serializedName: "reasonCode",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const CatalogSku: msRest.CompositeMapper = {
  serializedName: "CatalogSku",
  type: {
    name: "Composite",
    className: "CatalogSku",
    modelProperties: {
      resourceType: {
        readOnly: true,
        serializedName: "resourceType",
        type: {
          name: "String"
        }
      },
      name: {
        readOnly: true,
        serializedName: "name",
        type: {
          name: "String"
        }
      },
      tier: {
        readOnly: true,
        serializedName: "tier",
        type: {
          name: "String"
        }
      },
      locations: {
        readOnly: true,
        serializedName: "locations",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "String"
            }
          }
        }
      },
      capacity: {
        readOnly: true,
        serializedName: "capacity",
        type: {
          name: "Composite",
          className: "SkuCapacity"
        }
      },
      capabilities: {
        readOnly: true,
        serializedName: "capabilities",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "SkuCapability"
            }
          }
        }
      },
      costs: {
        readOnly: true,
        serializedName: "costs",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "SkuCost"
            }
          }
        }
      },
      restrictions: {
        readOnly: true,
        serializedName: "restrictions",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "SkuRestrictions"
            }
          }
        }
      }
    }
  }
};

export const Resource: msRest.CompositeMapper = {
  serializedName: "Resource",
  type: {
    name: "Composite",
    className: "Resource",
    modelProperties: {
      id: {
        readOnly: true,
        serializedName: "id",
        type: {
          name: "String"
        }
      },
      name: {
        readOnly: true,
        serializedName: "name",
        type: {
          name: "String"
        }
      },
      location: {
        required: true,
        serializedName: "location",
        type: {
          name: "String"
        }
      },
      type: {
        readOnly: true,
        serializedName: "type",
        type: {
          name: "String"
        }
      },
      tags: {
        serializedName: "tags",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "String"
            }
          }
        }
      }
    }
  }
};

export const CommitmentAssociationProperties: msRest.CompositeMapper = {
  serializedName: "CommitmentAssociationProperties",
  type: {
    name: "Composite",
    className: "CommitmentAssociationProperties",
    modelProperties: {
      associatedResourceId: {
        readOnly: true,
        serializedName: "associatedResourceId",
        type: {
          name: "String"
        }
      },
      commitmentPlanId: {
        readOnly: true,
        serializedName: "commitmentPlanId",
        type: {
          name: "String"
        }
      },
      creationDate: {
        readOnly: true,
        serializedName: "creationDate",
        type: {
          name: "DateTime"
        }
      }
    }
  }
};

export const CommitmentAssociation: msRest.CompositeMapper = {
  serializedName: "CommitmentAssociation",
  type: {
    name: "Composite",
    className: "CommitmentAssociation",
    modelProperties: {
      ...Resource.type.modelProperties,
      etag: {
        serializedName: "etag",
        type: {
          name: "String"
        }
      },
      properties: {
        serializedName: "properties",
        type: {
          name: "Composite",
          className: "CommitmentAssociationProperties"
        }
      }
    }
  }
};

export const ResourceSku: msRest.CompositeMapper = {
  serializedName: "ResourceSku",
  type: {
    name: "Composite",
    className: "ResourceSku",
    modelProperties: {
      capacity: {
        serializedName: "capacity",
        type: {
          name: "Number"
        }
      },
      name: {
        serializedName: "name",
        type: {
          name: "String"
        }
      },
      tier: {
        serializedName: "tier",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const MoveCommitmentAssociationRequest: msRest.CompositeMapper = {
  serializedName: "MoveCommitmentAssociationRequest",
  type: {
    name: "Composite",
    className: "MoveCommitmentAssociationRequest",
    modelProperties: {
      destinationPlanId: {
        serializedName: "destinationPlanId",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const CommitmentPlanPatchPayload: msRest.CompositeMapper = {
  serializedName: "CommitmentPlanPatchPayload",
  type: {
    name: "Composite",
    className: "CommitmentPlanPatchPayload",
    modelProperties: {
      tags: {
        serializedName: "tags",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "String"
            }
          }
        }
      },
      sku: {
        serializedName: "sku",
        type: {
          name: "Composite",
          className: "ResourceSku"
        }
      }
    }
  }
};

export const PlanQuantity: msRest.CompositeMapper = {
  serializedName: "PlanQuantity",
  type: {
    name: "Composite",
    className: "PlanQuantity",
    modelProperties: {
      allowance: {
        readOnly: true,
        serializedName: "allowance",
        type: {
          name: "Number"
        }
      },
      amount: {
        readOnly: true,
        serializedName: "amount",
        type: {
          name: "Number"
        }
      },
      includedQuantityMeter: {
        readOnly: true,
        serializedName: "includedQuantityMeter",
        type: {
          name: "String"
        }
      },
      overageMeter: {
        readOnly: true,
        serializedName: "overageMeter",
        type: {
          name: "String"
        }
      }
    }
  }
};

export const CommitmentPlanProperties: msRest.CompositeMapper = {
  serializedName: "CommitmentPlanProperties",
  type: {
    name: "Composite",
    className: "CommitmentPlanProperties",
    modelProperties: {
      chargeForOverage: {
        readOnly: true,
        serializedName: "chargeForOverage",
        type: {
          name: "Boolean"
        }
      },
      chargeForPlan: {
        readOnly: true,
        serializedName: "chargeForPlan",
        type: {
          name: "Boolean"
        }
      },
      creationDate: {
        readOnly: true,
        serializedName: "creationDate",
        type: {
          name: "DateTime"
        }
      },
      includedQuantities: {
        readOnly: true,
        serializedName: "includedQuantities",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Composite",
              className: "PlanQuantity"
            }
          }
        }
      },
      maxAssociationLimit: {
        readOnly: true,
        serializedName: "maxAssociationLimit",
        type: {
          name: "Number"
        }
      },
      maxCapacityLimit: {
        readOnly: true,
        serializedName: "maxCapacityLimit",
        type: {
          name: "Number"
        }
      },
      minCapacityLimit: {
        readOnly: true,
        serializedName: "minCapacityLimit",
        type: {
          name: "Number"
        }
      },
      planMeter: {
        readOnly: true,
        serializedName: "planMeter",
        type: {
          name: "String"
        }
      },
      refillFrequencyInDays: {
        readOnly: true,
        serializedName: "refillFrequencyInDays",
        type: {
          name: "Number"
        }
      },
      suspendPlanOnOverage: {
        readOnly: true,
        serializedName: "suspendPlanOnOverage",
        type: {
          name: "Boolean"
        }
      }
    }
  }
};

export const CommitmentPlan: msRest.CompositeMapper = {
  serializedName: "CommitmentPlan",
  type: {
    name: "Composite",
    className: "CommitmentPlan",
    modelProperties: {
      ...Resource.type.modelProperties,
      etag: {
        serializedName: "etag",
        type: {
          name: "String"
        }
      },
      properties: {
        readOnly: true,
        serializedName: "properties",
        type: {
          name: "Composite",
          className: "CommitmentPlanProperties"
        }
      },
      sku: {
        serializedName: "sku",
        type: {
          name: "Composite",
          className: "ResourceSku"
        }
      }
    }
  }
};

export const PlanUsageHistory: msRest.CompositeMapper = {
  serializedName: "PlanUsageHistory",
  type: {
    name: "Composite",
    className: "PlanUsageHistory",
    modelProperties: {
      planDeletionOverage: {
        serializedName: "planDeletionOverage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      planMigrationOverage: {
        serializedName: "planMigrationOverage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      planQuantitiesAfterUsage: {
        serializedName: "planQuantitiesAfterUsage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      planQuantitiesBeforeUsage: {
        serializedName: "planQuantitiesBeforeUsage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      planUsageOverage: {
        serializedName: "planUsageOverage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      usage: {
        serializedName: "usage",
        type: {
          name: "Dictionary",
          value: {
            type: {
              name: "Number"
            }
          }
        }
      },
      usageDate: {
        serializedName: "usageDate",
        type: {
          name: "DateTime"
        }
      }
    }
  }
};

export const SkuListResult: msRest.CompositeMapper = {
  serializedName: "SkuListResult",
  type: {
    name: "Composite",
    className: "SkuListResult",
    modelProperties: {
      value: {
        readOnly: true,
        serializedName: "",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "CatalogSku"
            }
          }
        }
      }
    }
  }
};

export const CommitmentAssociationListResult: msRest.CompositeMapper = {
  serializedName: "CommitmentAssociationListResult",
  type: {
    name: "Composite",
    className: "CommitmentAssociationListResult",
    modelProperties: {
      nextLink: {
        serializedName: "nextLink",
        type: {
          name: "String"
        }
      },
      value: {
        serializedName: "",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "CommitmentAssociation"
            }
          }
        }
      }
    }
  }
};

export const CommitmentPlanListResult: msRest.CompositeMapper = {
  serializedName: "CommitmentPlanListResult",
  type: {
    name: "Composite",
    className: "CommitmentPlanListResult",
    modelProperties: {
      nextLink: {
        serializedName: "nextLink",
        type: {
          name: "String"
        }
      },
      value: {
        serializedName: "",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "CommitmentPlan"
            }
          }
        }
      }
    }
  }
};

export const PlanUsageHistoryListResult: msRest.CompositeMapper = {
  serializedName: "PlanUsageHistoryListResult",
  type: {
    name: "Composite",
    className: "PlanUsageHistoryListResult",
    modelProperties: {
      nextLink: {
        serializedName: "nextLink",
        type: {
          name: "String"
        }
      },
      value: {
        serializedName: "",
        type: {
          name: "Sequence",
          element: {
            type: {
              name: "Composite",
              className: "PlanUsageHistory"
            }
          }
        }
      }
    }
  }
};
