Class RoleBinding

  • All Implemented Interfaces:
    com.marcnuri.yakc.model.Model

    public class RoleBinding
    extends java.lang.Object
    implements com.marcnuri.yakc.model.Model
    RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given namespace only have effect in that namespace. Deprecated in v1.17 in favor of rbac.authorization.k8s.io/v1 RoleBinding, and will no longer be served in v1.22.
    • Constructor Detail

      • RoleBinding

        public RoleBinding​(java.lang.String apiVersion,
                           java.lang.String kind,
                           ObjectMeta metadata,
                           @NonNull
                           @NonNull RoleRef roleRef,
                           java.util.List<Subject> subjects)
      • RoleBinding

        public RoleBinding()
    • Method Detail

      • getApiVersion

        public java.lang.String getApiVersion()
        APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
      • getKind

        public java.lang.String getKind()
        Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
      • getRoleRef

        @NonNull
        public @NonNull RoleRef getRoleRef()
      • getSubjects

        public java.util.List<Subject> getSubjects()
        Subjects holds references to the objects the role applies to.
      • setApiVersion

        public void setApiVersion​(java.lang.String apiVersion)
        APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
      • setKind

        public void setKind​(java.lang.String kind)
        Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
      • setMetadata

        public void setMetadata​(ObjectMeta metadata)
      • setRoleRef

        public void setRoleRef​(@NonNull
                               @NonNull RoleRef roleRef)
      • setSubjects

        public void setSubjects​(java.util.List<Subject> subjects)
        Subjects holds references to the objects the role applies to.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • canEqual

        protected boolean canEqual​(java.lang.Object other)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

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