Skip to content

Commit eda8452

Browse files
committed
networking: add constants for statuses
This avoids the need to define these constants in consumer code. Router also has a status field, but there's no documentation for it, so let's not guess what the valid statuses are.
1 parent 1031a87 commit eda8452

File tree

7 files changed

+61
-0
lines changed

7 files changed

+61
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package apiversions
2+
3+
const (
4+
StatusCurrent = "CURRENT"
5+
StatusDeprecated = "DEPRECATED"
6+
StatusStable = "STABLE"
7+
)
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package floatingips
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusDown = "DOWN"
6+
StatusError = "ERROR"
7+
)
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
package trunks
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusBuild = "BUILD"
6+
StatusDegraded = "DEGRADED"
7+
StatusDown = "DOWN"
8+
StatusError = "ERROR"
9+
)
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package services
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusBuild = "BUILD"
6+
StatusDown = "DOWN"
7+
StatusError = "ERROR"
8+
StatusPendingCreate = "PENDING_CREATE"
9+
StatusPendingDelete = "PENDING_DELETE"
10+
StatusPendingUpdate = "PENDING_UPDATE"
11+
)
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package siteconnections
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusBuild = "BUILD"
6+
StatusDown = "DOWN"
7+
StatusError = "ERROR"
8+
StatusPendingCreate = "PENDING_CREATE"
9+
StatusPendingDelete = "PENDING_DELETE"
10+
StatusPendingUpdate = "PENDING_UPDATE"
11+
)
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
package networks
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusBuild = "BUILD"
6+
StatusDown = "DOWN"
7+
StatusError = "ERROR"
8+
)
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
package ports
2+
3+
const (
4+
StatusActive = "ACTIVE"
5+
StatusBuild = "BUILD"
6+
StatusDown = "DOWN"
7+
StatusError = "ERROR"
8+
)

0 commit comments

Comments
 (0)