Class: DeploymentApi#
Hierarchy#
↳ DeploymentApi
Table of contents#
Constructors#
Properties#
- apiBase
- apiGroup
- apiPrefix
- apiResource
- apiVersion
- apiVersionPreferred
- isNamespaced
- kind
- objectConstructor
- options
- request
- resourceVersions
- watchDisposer
Accessors#
Methods#
- checkPreferredVersion
- create
- delete
- get
- getReplicas
- getResourceVersion
- getScaleApiUrl
- getUrl
- getWatchUrl
- list
- modifyWatchEvent
- normalizeQuery
- parseResponse
- patch
- refreshResourceVersion
- restart
- scale
- setResourceVersion
- update
- watch
Constructors#
constructor#
• new DeploymentApi(options)
Parameters#
| Name | Type |
|---|---|
options |
IKubeApiOptions<Deployment> |
Inherited from#
Properties#
apiBase#
• apiBase: string
Inherited from#
apiGroup#
• apiGroup: string
Inherited from#
apiPrefix#
• apiPrefix: string
Inherited from#
apiResource#
• Readonly apiResource: string
Inherited from#
apiVersion#
• Readonly apiVersion: string
Inherited from#
apiVersionPreferred#
• Optional apiVersionPreferred: string
Inherited from#
isNamespaced#
• Readonly isNamespaced: boolean
Inherited from#
kind#
• Readonly kind: string
Inherited from#
objectConstructor#
• objectConstructor: KubeObjectConstructor<Deployment>
Inherited from#
options#
• Protected options: IKubeApiOptions<Deployment>
Inherited from#
request#
• Protected request: KubeJsonApi
Inherited from#
resourceVersions#
• Protected resourceVersions: Map<string, string>
Inherited from#
watchDisposer#
• Protected watchDisposer: () => void
Type declaration#
▸ (): void
Returns#
void
Inherited from#
Accessors#
apiVersionWithGroup#
• get apiVersionWithGroup(): string
Returns#
string
Inherited from#
KubeApi.apiVersionWithGroup
Methods#
checkPreferredVersion#
▸ Protected checkPreferredVersion(): Promise<void>
Returns#
Promise<void>
Inherited from#
create#
▸ create(__namedParameters, data?): Promise<Deployment>
Parameters#
| Name | Type |
|---|---|
__namedParameters |
Partial<ResourceDescriptor> |
data? |
PartialKubeObject<Deployment> |
Returns#
Promise<Deployment>
Inherited from#
delete#
▸ delete(__namedParameters): Promise<KubeJsonApiData>
Parameters#
| Name | Type |
|---|---|
__namedParameters |
DeleteResourceDescriptor |
Returns#
Promise<KubeJsonApiData>
Inherited from#
get#
▸ get(desc, query?): Promise<Deployment>
Parameters#
| Name | Type |
|---|---|
desc |
ResourceDescriptor |
query? |
IKubeApiQueryParams |
Returns#
Promise<Deployment>
Inherited from#
getReplicas#
▸ getReplicas(params): Promise<number>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace |
string |
Returns#
Promise<number>
getResourceVersion#
▸ getResourceVersion(namespace?): string
Parameters#
| Name | Type | Default value |
|---|---|---|
namespace |
string |
"" |
Returns#
string
Inherited from#
getScaleApiUrl#
▸ Protected getScaleApiUrl(params): string
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace |
string |
Returns#
string
getUrl#
▸ getUrl(__namedParameters?, query?): string
Parameters#
| Name | Type |
|---|---|
__namedParameters |
Partial<ResourceDescriptor> |
query? |
Partial<IKubeApiQueryParams> |
Returns#
string
Inherited from#
getWatchUrl#
▸ getWatchUrl(namespace?, query?): string
Parameters#
| Name | Type | Default value |
|---|---|---|
namespace |
string |
"" |
query |
IKubeApiQueryParams |
{} |
Returns#
string
Inherited from#
list#
▸ list(__namedParameters?, query?): Promise<Deployment[]>
Parameters#
| Name | Type |
|---|---|
__namedParameters |
KubeApiListOptions |
query? |
IKubeApiQueryParams |
Returns#
Promise<Deployment[]>
Inherited from#
modifyWatchEvent#
▸ Protected modifyWatchEvent(event): void
Parameters#
| Name | Type |
|---|---|
event |
IKubeWatchEvent<KubeJsonApiData> |
Returns#
void
Inherited from#
normalizeQuery#
▸ Protected normalizeQuery(query?): Partial<IKubeApiQueryParams>
Parameters#
| Name | Type |
|---|---|
query |
Partial<IKubeApiQueryParams> |
Returns#
Partial<IKubeApiQueryParams>
Inherited from#
parseResponse#
▸ Protected parseResponse(data, namespace?): Deployment | Deployment[]
Parameters#
| Name | Type |
|---|---|
data |
unknown |
namespace? |
string |
Returns#
Deployment | Deployment[]
Inherited from#
patch#
▸ patch(desc, data?, strategy?): Promise<Deployment>
Parameters#
| Name | Type | Default value |
|---|---|---|
desc |
ResourceDescriptor |
undefined |
data? |
Patch | PartialKubeObject<Deployment> |
undefined |
strategy |
KubeApiPatchType |
"strategic" |
Returns#
Promise<Deployment>
Inherited from#
refreshResourceVersion#
▸ refreshResourceVersion(params?): Promise<Deployment[]>
Parameters#
| Name | Type |
|---|---|
params? |
KubeApiListOptions |
Returns#
Promise<Deployment[]>
Inherited from#
KubeApi.refreshResourceVersion
restart#
▸ restart(params): Promise<KubeJsonApiData>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace |
string |
Returns#
Promise<KubeJsonApiData>
scale#
▸ scale(params, replicas): Promise<KubeJsonApiData>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace |
string |
replicas |
number |
Returns#
Promise<KubeJsonApiData>
setResourceVersion#
▸ setResourceVersion(namespace?, newVersion): void
Parameters#
| Name | Type | Default value |
|---|---|---|
namespace |
string |
"" |
newVersion |
string |
undefined |
Returns#
void
Inherited from#
update#
▸ update(__namedParameters, data): Promise<Deployment>
Parameters#
| Name | Type |
|---|---|
__namedParameters |
ResourceDescriptor |
data |
PartialKubeObject<Deployment> |
Returns#
Promise<Deployment>
Inherited from#
watch#
▸ watch(opts?): () => void
Parameters#
| Name | Type |
|---|---|
opts |
KubeApiWatchOptions |
Returns#
fn
▸ (): void
Returns#
void