routetable_routesets.go 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. // Copyright 2019 Yunion
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. package compute
  15. import (
  16. "yunion.io/x/cloudmux/pkg/apis/compute"
  17. "yunion.io/x/onecloud/pkg/apis"
  18. )
  19. const (
  20. NEXT_HOP_TYPE_INSTANCE = compute.NEXT_HOP_TYPE_INSTANCE // ECS实例。
  21. NEXT_HOP_TYPE_VPCPEERING = compute.NEXT_HOP_TYPE_VPCPEERING // vpc对等连接
  22. NEXT_HOP_TYPE_IP = compute.NEXT_HOP_TYPE_IP
  23. )
  24. type RouteTableRouteSetCreateInput struct {
  25. apis.StatusStandaloneResourceCreateInput
  26. RouteTableId string `json:"route_table_id"`
  27. Cidr string `json:"cidr"`
  28. NextHopType string `json:"next_hop_type"`
  29. NextHopId string `json:"next_hop_id"`
  30. ExtNextHopId string `json:"ext_next_hop_id"`
  31. }
  32. type RouteTableRouteSetUpdateInput struct {
  33. apis.StatusStandaloneResourceBaseUpdateInput
  34. Cidr string `json:"cidr"`
  35. NextHopType string `json:"next_hop_type"`
  36. NextHopId string `json:"next_hop_id"`
  37. ExtNextHopId string `json:"ext_next_hop_id"`
  38. }
  39. type RouteTableRouteSetListInput struct {
  40. apis.StatusStandaloneResourceListInput
  41. apis.ExternalizedResourceBaseListInput
  42. RouteTableFilterList
  43. Type string `json:"type"`
  44. NextHopType string `json:"next_hop_type"`
  45. NextHopId string `json:"next_hop_id"`
  46. Cidr string `json:"cidr"`
  47. }