-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generate enums for Gateway condition types and reasons (#37)
Signed-off-by: Sanskar Jaiswal <[email protected]>
- Loading branch information
Showing
7 changed files
with
245 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
// WARNING: generated file - manual changes will be overriden | ||
|
||
#[derive(Debug)] | ||
pub enum GatewayConditionType { | ||
Programmed, | ||
Accepted, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for GatewayConditionType { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum GatewayConditionReason { | ||
Programmed, | ||
Invalid, | ||
NoResources, | ||
AddressNotAssigned, | ||
AddressNotUsable, | ||
Accepted, | ||
ListenersNotValid, | ||
Pending, | ||
UnsupportedAddress, | ||
InvalidParameters, | ||
Ready, | ||
ListenersNotReady, | ||
} | ||
|
||
impl std::fmt::Display for GatewayConditionReason { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum ListenerConditionType { | ||
Conflicted, | ||
Accepted, | ||
ResolvedRefs, | ||
Programmed, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for ListenerConditionType { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum ListenerConditionReason { | ||
HostnameConflict, | ||
ProtocolConflict, | ||
NoConflicts, | ||
Accepted, | ||
PortUnavailable, | ||
UnsupportedProtocol, | ||
ResolvedRefs, | ||
InvalidCertificateRef, | ||
InvalidRouteKinds, | ||
RefNotPermitted, | ||
Programmed, | ||
Invalid, | ||
Pending, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for ListenerConditionReason { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
// WARNING: generated file - manual changes will be overriden | ||
|
||
#[derive(Debug)] | ||
pub enum GatewayConditionType { | ||
Programmed, | ||
Accepted, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for GatewayConditionType { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum GatewayConditionReason { | ||
Programmed, | ||
Invalid, | ||
NoResources, | ||
AddressNotAssigned, | ||
AddressNotUsable, | ||
Accepted, | ||
ListenersNotValid, | ||
Pending, | ||
UnsupportedAddress, | ||
InvalidParameters, | ||
Ready, | ||
ListenersNotReady, | ||
} | ||
|
||
impl std::fmt::Display for GatewayConditionReason { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum ListenerConditionType { | ||
Conflicted, | ||
Accepted, | ||
ResolvedRefs, | ||
Programmed, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for ListenerConditionType { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} | ||
|
||
#[derive(Debug)] | ||
pub enum ListenerConditionReason { | ||
HostnameConflict, | ||
ProtocolConflict, | ||
NoConflicts, | ||
Accepted, | ||
PortUnavailable, | ||
UnsupportedProtocol, | ||
ResolvedRefs, | ||
InvalidCertificateRef, | ||
InvalidRouteKinds, | ||
RefNotPermitted, | ||
Programmed, | ||
Invalid, | ||
Pending, | ||
Ready, | ||
} | ||
|
||
impl std::fmt::Display for ListenerConditionReason { | ||
fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { | ||
write!(f, "{:?}", self) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters