k8s_openapi_ext/get/replicaset/
condition.rs1use super::*;
2
3pub trait ReplicaSetConditionGetExt {
4 fn myself(&self) -> &appsv1::ReplicaSetCondition;
5
6 fn last_transition_time(&self) -> Option<&metav1::Time> {
7 self.myself().last_transition_time.as_ref()
8 }
9
10 fn message(&self) -> Option<&str> {
11 self.myself().message.as_deref()
12 }
13
14 fn reason(&self) -> Option<&str> {
15 self.myself().reason.as_deref()
16 }
17
18 fn status(&self) -> &str {
19 &self.myself().status
20 }
21
22 fn r#type(&self) -> &str {
23 &self.myself().type_
24 }
25}
26
27impl ReplicaSetConditionGetExt for appsv1::ReplicaSetCondition {
28 #[inline(always)]
29 fn myself(&self) -> &appsv1::ReplicaSetCondition {
30 self
31 }
32}