Class: CRDStore#
Hierarchy#
KubeObjectStore<CustomResourceDefinition,CustomResourceDefinitionApi>
↳ CRDStore
Table of contents#
Constructors#
Properties#
- api
- bufferSize
- defaultSorting
- dependencies
- eventsBuffer
- failedLoading
- isLoaded
- isLoading
- items
- limit
- selectedItemsIds
Accessors#
Methods#
- [iterator]
- bindWatchEventsUpdater
- create
- createItem
- filterItemsOnLoad
- getAllByNs
- getByGroup
- getById
- getByLabel
- getByName
- getByObject
- getByPath
- getIndexById
- getItems
- getTotalCount
- isSelected
- isSelectedAll
- load
- loadAll
- loadFromPath
- loadItem
- loadItems
- mergeItems
- patch
- pickOnlySelected
- reloadAll
- remove
- removeItem
- removeItems
- removeSelectedItems
- reset
- resetOnError
- resetSelection
- select
- sortItems
- subscribe
- toggleSelection
- toggleSelectionAll
- unselect
- update
- updateFromEventsBuffer
- updateItem
Constructors#
constructor#
• new CRDStore(dependencies, api, opts?)
Parameters#
| Name | Type |
|---|---|
dependencies |
CustomResourceDefinitionStoreDependencies |
api |
CustomResourceDefinitionApi |
opts? |
KubeObjectStoreOptions |
Overrides#
KubeObjectStore<CustomResourceDefinition, CustomResourceDefinitionApi\>.constructor
Properties#
api#
• Readonly api: CustomResourceDefinitionApi
Inherited from#
KubeObjectStore.api
bufferSize#
• Readonly bufferSize: number
Inherited from#
KubeObjectStore.bufferSize
defaultSorting#
• Protected defaultSorting: (item: CustomResourceDefinition) => string
Type declaration#
▸ (item): string
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
string
Inherited from#
KubeObjectStore.defaultSorting
dependencies#
• Protected Readonly dependencies: CustomResourceDefinitionStoreDependencies
Overrides#
KubeObjectStore.dependencies
eventsBuffer#
• Protected Readonly eventsBuffer: IObservableArray<IKubeWatchEvent<KubeJsonApiData<ClusterScopedMetadata, CustomResourceDefinitionStatus, CustomResourceDefinitionSpec>>>
Inherited from#
KubeObjectStore.eventsBuffer
failedLoading#
• failedLoading: boolean
Inherited from#
KubeObjectStore.failedLoading
isLoaded#
• isLoaded: boolean
Inherited from#
KubeObjectStore.isLoaded
isLoading#
• isLoading: boolean
Inherited from#
KubeObjectStore.isLoading
items#
• items: IObservableArray<CustomResourceDefinition>
Inherited from#
KubeObjectStore.items
limit#
• Readonly limit: undefined | number
Inherited from#
KubeObjectStore.limit
selectedItemsIds#
• selectedItemsIds: ObservableSet<string>
Inherited from#
KubeObjectStore.selectedItemsIds
Accessors#
contextItems#
• get contextItems(): K[]
Returns#
K[]
Inherited from#
KubeObjectStore.contextItems
groups#
• get groups(): Record<string, CustomResourceDefinition[]>
Returns#
Record<string, CustomResourceDefinition[]>
query#
• get query(): KubeApiQueryParams
Returns#
KubeApiQueryParams
Inherited from#
KubeObjectStore.query
selectedItems#
• get selectedItems(): Item[]
Returns#
Item[]
Inherited from#
KubeObjectStore.selectedItems
Methods#
[iterator]#
▸ [iterator](): Generator<CustomResourceDefinition, void, undefined>
Returns#
Generator<CustomResourceDefinition, void, undefined>
Inherited from#
KubeObjectStore.__@iterator@187
bindWatchEventsUpdater#
▸ Protected bindWatchEventsUpdater(delay?): void
Parameters#
| Name | Type |
|---|---|
delay? |
number |
Returns#
void
Inherited from#
KubeObjectStore.bindWatchEventsUpdater
create#
▸ create(params, data?): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace? |
string |
data? |
PartialObjectDeep<CustomResourceDefinition, {}> |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.create
createItem#
▸ Protected createItem(params, data?): Promise<null | CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace? |
string |
data? |
PartialObjectDeep<CustomResourceDefinition, {}> |
Returns#
Promise<null | CustomResourceDefinition>
Inherited from#
KubeObjectStore.createItem
filterItemsOnLoad#
▸ Protected filterItemsOnLoad(items): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
items |
CustomResourceDefinition[] |
Returns#
Inherited from#
KubeObjectStore.filterItemsOnLoad
getAllByNs#
▸ getAllByNs(namespace, strict?): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
namespace |
string | string[] |
strict? |
boolean |
Returns#
Inherited from#
KubeObjectStore.getAllByNs
getByGroup#
▸ getByGroup(group, pluralName): undefined | CustomResourceDefinition
Parameters#
| Name | Type |
|---|---|
group |
string |
pluralName |
string |
Returns#
undefined | CustomResourceDefinition
getById#
▸ getById(id): undefined | CustomResourceDefinition
Parameters#
| Name | Type |
|---|---|
id |
string |
Returns#
undefined | CustomResourceDefinition
Inherited from#
KubeObjectStore.getById
getByLabel#
▸ getByLabel(labels): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
labels |
string[] | Partial<Record<string, string>> |
Returns#
Inherited from#
KubeObjectStore.getByLabel
getByName#
▸ getByName(name, namespace?): undefined | CustomResourceDefinition
Parameters#
| Name | Type |
|---|---|
name |
string |
namespace? |
string |
Returns#
undefined | CustomResourceDefinition
Inherited from#
KubeObjectStore.getByName
getByObject#
▸ getByObject(obj): undefined | CustomResourceDefinition
Parameters#
| Name | Type |
|---|---|
obj |
KubeObject<KubeObjectMetadata<KubeObjectScope>, unknown, unknown> |
Returns#
undefined | CustomResourceDefinition
getByPath#
▸ getByPath(path): undefined | CustomResourceDefinition
Parameters#
| Name | Type |
|---|---|
path |
string |
Returns#
undefined | CustomResourceDefinition
Inherited from#
KubeObjectStore.getByPath
getIndexById#
▸ getIndexById(id): number
Parameters#
| Name | Type |
|---|---|
id |
string |
Returns#
number
Inherited from#
KubeObjectStore.getIndexById
getItems#
▸ getItems(): CustomResourceDefinition[]
Returns#
Inherited from#
KubeObjectStore.getItems
getTotalCount#
▸ getTotalCount(): number
Returns#
number
Inherited from#
KubeObjectStore.getTotalCount
isSelected#
▸ isSelected(item): boolean
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
boolean
Inherited from#
KubeObjectStore.isSelected
isSelectedAll#
▸ isSelectedAll(visibleItems?): boolean
Parameters#
| Name | Type |
|---|---|
visibleItems? |
CustomResourceDefinition[] |
Returns#
boolean
Inherited from#
KubeObjectStore.isSelectedAll
load#
▸ load(params): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace? |
string |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.load
loadAll#
▸ loadAll(«destructured»?): Promise<undefined | CustomResourceDefinition[]>
Parameters#
| Name | Type |
|---|---|
«destructured» |
KubeObjectStoreLoadAllParams |
Returns#
Promise<undefined | CustomResourceDefinition[]>
Inherited from#
KubeObjectStore.loadAll
loadFromPath#
▸ loadFromPath(resourcePath): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
resourcePath |
string |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.loadFromPath
loadItem#
▸ Protected loadItem(params): Promise<null | CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
params |
Object |
params.name |
string |
params.namespace? |
string |
Returns#
Promise<null | CustomResourceDefinition>
Inherited from#
KubeObjectStore.loadItem
loadItems#
▸ Protected loadItems(«destructured»): Promise<CustomResourceDefinition[]>
Parameters#
| Name | Type |
|---|---|
«destructured» |
KubeObjectStoreLoadingParams |
Returns#
Promise<CustomResourceDefinition[]>
Inherited from#
KubeObjectStore.loadItems
mergeItems#
▸ Protected mergeItems(partialItems, «destructured»): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
partialItems |
CustomResourceDefinition[] |
«destructured» |
MergeItemsOptions |
Returns#
Inherited from#
KubeObjectStore.mergeItems
patch#
▸ patch(item, patch): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
patch |
Patch |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.patch
pickOnlySelected#
▸ pickOnlySelected(items): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
items |
CustomResourceDefinition[] |
Returns#
Inherited from#
KubeObjectStore.pickOnlySelected
reloadAll#
▸ reloadAll(opts?): Promise<undefined | CustomResourceDefinition[]>
Parameters#
| Name | Type |
|---|---|
opts? |
Object |
opts.force? |
boolean |
opts.merge? |
boolean |
opts.namespaces? |
string[] |
Returns#
Promise<undefined | CustomResourceDefinition[]>
Inherited from#
KubeObjectStore.reloadAll
remove#
▸ remove(item): Promise<void>
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
Promise<void>
Inherited from#
KubeObjectStore.remove
removeItem#
▸ Protected removeItem(item, request): Promise<void>
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
request |
() => Promise<any> |
Returns#
Promise<void>
Inherited from#
KubeObjectStore.removeItem
removeItems#
▸ removeItems(items): Promise<void>
Parameters#
| Name | Type |
|---|---|
items |
CustomResourceDefinition[] |
Returns#
Promise<void>
Inherited from#
KubeObjectStore.removeItems
removeSelectedItems#
▸ removeSelectedItems(): Promise<void>
Returns#
Promise<void>
Inherited from#
KubeObjectStore.removeSelectedItems
reset#
▸ reset(): void
Returns#
void
Inherited from#
KubeObjectStore.reset
resetOnError#
▸ Protected resetOnError(error): void
Parameters#
| Name | Type |
|---|---|
error |
any |
Returns#
void
Inherited from#
KubeObjectStore.resetOnError
resetSelection#
▸ resetSelection(): void
Returns#
void
Inherited from#
KubeObjectStore.resetSelection
select#
▸ select(item): void
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
void
Inherited from#
KubeObjectStore.select
sortItems#
▸ Protected sortItems(items): CustomResourceDefinition[]
Parameters#
| Name | Type |
|---|---|
items |
CustomResourceDefinition[] |
Returns#
Overrides#
KubeObjectStore.sortItems
subscribe#
▸ subscribe(«destructured»?): Disposer
Parameters#
| Name | Type |
|---|---|
«destructured» |
KubeObjectStoreSubscribeParams |
Returns#
Inherited from#
KubeObjectStore.subscribe
toggleSelection#
▸ toggleSelection(item): void
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
void
Inherited from#
KubeObjectStore.toggleSelection
toggleSelectionAll#
▸ toggleSelectionAll(visibleItems?): void
Parameters#
| Name | Type |
|---|---|
visibleItems? |
CustomResourceDefinition[] |
Returns#
void
Inherited from#
KubeObjectStore.toggleSelectionAll
unselect#
▸ unselect(item): void
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
Returns#
void
Inherited from#
KubeObjectStore.unselect
update#
▸ update(item, data): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
data |
PartialObjectDeep<CustomResourceDefinition, {}> |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.update
updateFromEventsBuffer#
▸ Protected updateFromEventsBuffer(): void
Returns#
void
Inherited from#
KubeObjectStore.updateFromEventsBuffer
updateItem#
▸ Protected updateItem(item, request): Promise<CustomResourceDefinition>
Parameters#
| Name | Type |
|---|---|
item |
CustomResourceDefinition |
request |
() => Promise<CustomResourceDefinition> |
Returns#
Promise<CustomResourceDefinition>
Inherited from#
KubeObjectStore.updateItem