Class APIResource.Builder

  • Enclosing class:
    APIResource

    public static class APIResource.Builder
    extends java.lang.Object
    • Method Detail

      • addToCategories

        public APIResource.Builder addToCategories​(java.lang.String addToCategories)
      • categories

        public APIResource.Builder categories​(java.util.Collection<? extends java.lang.String> categories)
      • group

        public APIResource.Builder group​(java.lang.String group)
        group is the preferred group of the resource. Empty implies the group of the containing resource list. For subresources, this may have a different value, for example: Scale".
        Returns:
        this.
      • kind

        public APIResource.Builder kind​(@NonNull
                                        @NonNull java.lang.String kind)
        kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')
        Returns:
        this.
      • name

        public APIResource.Builder name​(@NonNull
                                        @NonNull java.lang.String name)
        name is the plural name of the resource.
        Returns:
        this.
      • namespaced

        public APIResource.Builder namespaced​(@NonNull
                                              @NonNull java.lang.Boolean namespaced)
        namespaced indicates if a resource is namespaced or not.
        Returns:
        this.
      • addToShortNames

        public APIResource.Builder addToShortNames​(java.lang.String addToShortNames)
      • shortNames

        public APIResource.Builder shortNames​(java.util.Collection<? extends java.lang.String> shortNames)
      • singularName

        public APIResource.Builder singularName​(@NonNull
                                                @NonNull java.lang.String singularName)
        singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.
        Returns:
        this.
      • storageVersionHash

        public APIResource.Builder storageVersionHash​(java.lang.String storageVersionHash)
        The hash value of the storage version, the version this resource is converted to when written to the data store. Value must be treated as opaque by clients. Only equality comparison on the value is valid. This is an alpha feature and may change or be removed in the future. The field is populated by the apiserver only if the StorageVersionHash feature gate is enabled. This field will remain optional even if it graduates.
        Returns:
        this.
      • verbs

        public APIResource.Builder verbs​(java.util.Collection<? extends java.lang.String> verbs)
      • version

        public APIResource.Builder version​(java.lang.String version)
        version is the preferred version of the resource. Empty implies the version of the containing resource list For subresources, this may have a different value, for example: v1 (while inside a v1beta1 version of the core resource's group)".
        Returns:
        this.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object