- .github
- devel
- doc
-
examples
-
dynamic-client
-
notebooks
-
watch
-
yaml_dir
- README.md
- __init__.py
- annotate_deployment.py
- api_discovery.py
- apply_from_dict.py
- apply_from_directory.py
- apply_from_single_file.py
- cluster_scoped_custom_object.py
- cronjob_crud.py
- deployment_create.py
- deployment_crud.py
- duration-gep2257.py
- in_cluster_config.py
- ingress_create.py
- job_crud.py
- multiple_clusters.py
- namespaced_custom_object.py
- node_labels.py
- out_of_cluster_config.py
- pick_kube_config_context.py
- pod_config_list.py
- pod_exec.py
- pod_portforward.py
- remote_cluster.py
- rollout-daemonset.py
- rollout-statefulset.py
-
dynamic-client
- kubernetes
- scripts
- .gitignore
- CHANGELOG.md
- CONTRIBUTING.md
- LICENSE
- MANIFEST.in
- OWNERS
- README.md
- SECURITY_CONTACTS
- code-of-conduct.md
- codecov.yml
- requirements.txt
- setup.cfg
- setup.py
- test-requirements.txt
- tox.ini
Explanation
This code defines a Python class named V1LimitRangeItem
representing a LimitRangeItem object in the Kubernetes API. It’s generated by OpenAPI Generator and represents a limit on resource usage for containers within a Kubernetes cluster.
Attributes:
default
: A dictionary mapping resource names to their default limits. Used when a container doesn’t specify a limit for a specific resource.default_request
: A dictionary mapping resource names to their default requests. Similar todefault
, but for resource requests.max
: A dictionary mapping resource names to their maximum allowed limits.max_limit_request_ratio
: A dictionary mapping resource names to their maximum allowed ratio of limit to request. This ratio controls the burst capacity for a resource.min
: A dictionary mapping resource names to their minimum allowed limits.type
: A string specifying the type of resource this LimitRangeItem applies to.
Methods:
__init__
: The constructor initializes the attributes.default
: A getter and setter method for thedefault
attribute.default_request
: A getter and setter method for thedefault_request
attribute.max
: A getter and setter method for themax
attribute.max_limit_request_ratio
: A getter and setter method for themax_limit_request_ratio
attribute.min
: A getter and setter method for themin
attribute.type
: A getter and setter method for thetype
attribute.to_dict
: Converts the object into a dictionary representation.to_str
: Converts the object into a string representation.__repr__
: Defines the string representation for print and pprint.__eq__
: Defines equality comparison between instances.__ne__
: Defines inequality comparison between instances.
Overall, this class provides a structured representation of a LimitRangeItem in Kubernetes, enabling developers to work with these limits and control resource usage within their container deployments.
Graph
The graph shows the usage of functions within the codebase.
Select a code symbol to view it's graph