k8s-openapi-ext 0.26.1

Collection of fluent builder traits for Kubernetes objects
Documentation
1
2
3
4
5
6
7
8
9
10
11
use super::*;

pub trait TimeExt {
    fn now() -> Self;
}

impl TimeExt for metav1::Time {
    fn now() -> Self {
        Self(openapi::chrono::Utc::now())
    }
}