# Coveo HierarchicalFacet Component (CoveoHierarchicalFacet)

## Index

### Methods

- close
- collapse
- debugInfo
- deselectMultipleValues
- deselectValue
- disable
- enable
- excludeMultipleValues
- excludeValue
- expand
- getBindings
- getCaptionForStringValue
- getDisplayedFacetValues
- getDisplayedValues
- getEndpoint
- getExcludedValues
- getSelectedValues
- getValueCaption
- hasSelectedValue
- hideWaitingAnimation
- open
- reset
- selectMultipleValues
- selectValue
- showLess
- showMore
- showWaitingAnimation
- switchToAnd
- switchToOr
- toggleExcludeValue
- toggleSelectValue
- unexcludeMultipleValues
- unexcludeValue
- updateSort
- get

### Properties

- bind
- componentOptionsModel
- componentStateModel
- disabled
- facetSearch
- facetSettings
- logger
- queryController
- queryStateModel
- root
- searchInterface
- ID

### Accessors

- usageAnalytics

### Component Options

- delimitingCharacter
- levelEnd
- levelStart
- marginByLevel

### Constructors

- constructor

## Methods

### close

- close(value: FacetValue | IValueHierarchy | string): void

- - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :430

  #### Parameters

  - ##### value: FacetValue | IValueHierarchy | string

  #### Returns void

### collapse

- collapse(): void

- Inherited from Facet.collapse

  - Defined in ui/Facet/Facet.ts :1248

  #### Returns void

### debugInfo

- debugInfo(): any

- Inherited from BaseComponent.debugInfo

  - Defined in ui/Base/BaseComponent.ts :41

  #### Returns any

### deselectMultipleValues

- deselectMultipleValues(values: FacetValue[] | string[], deselectChildren?: boolean): void

- Overwrites Facet.deselectMultipleValues

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :310

  #### Parameters

  - ##### values: FacetValue[] | string[]

  - ##### Default value deselectChildren: boolean = !this.options.useAnd

  #### Returns void

### deselectValue

- deselectValue(value: FacetValue | string, deselectChildren?: boolean): void

- Overwrites Facet.deselectValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :245

  #### Parameters

  - ##### value: FacetValue | string

  - ##### Default value deselectChildren: boolean = true

  #### Returns void

### disable

- disable(): void

- Inherited from BaseComponent.disable

  - Defined in ui/Base/BaseComponent.ts :52

  #### Returns void

### enable

- enable(): void

- Inherited from BaseComponent.enable

  - Defined in ui/Base/BaseComponent.ts :61

  #### Returns void

### excludeMultipleValues

- excludeMultipleValues(values: FacetValue[] | string[]): void

- Inherited from Facet.excludeMultipleValues

  - Defined in ui/Facet/Facet.ts :932

  #### Parameters

  - ##### values: FacetValue[] | string[]

  #### Returns void

### excludeValue

- excludeValue(value: FacetValue | string, excludeChildren?: boolean): void

- Overwrites Facet.excludeValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :273

  #### Parameters

  - ##### value: FacetValue | string

  - ##### Default value excludeChildren: boolean = !this.options.useAnd

  #### Returns void

### expand

- expand(): void

- Inherited from Facet.expand

  - Defined in ui/Facet/Facet.ts :1258

  #### Returns void

### getBindings

- getBindings(): IComponentBindings

- Inherited from Component.getBindings

  - Defined in ui/Base/Component.ts :328

  #### Returns IComponentBindings

### getCaptionForStringValue

- getCaptionForStringValue(value: string): string

- Inherited from Facet.getCaptionForStringValue

  - Defined in ui/Facet/Facet.ts :1206

  #### Parameters

  - ##### value: string

  #### Returns string

### getDisplayedFacetValues

- getDisplayedFacetValues(): FacetValue[]

- Inherited from Facet.getDisplayedFacetValues

  - Defined in ui/Facet/Facet.ts :1014

  #### Returns FacetValue[]

  The currently displayed values.

### getDisplayedValues

- getDisplayedValues(): string[]

- Overwrites Facet.getDisplayedValues

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :379

  #### Returns string[]

  An array containing all the values that the `HierarchicalFacet` is currently displaying.

### getEndpoint

- getEndpoint(): ISearchEndpoint

- Inherited from Facet.getEndpoint

  - Defined in ui/Facet/Facet.ts :1088

  #### Returns ISearchEndpoint

  The endpoint for the facet.

### getExcludedValues

- getExcludedValues(): string[]

- Inherited from Facet.getExcludedValues

  - Defined in ui/Facet/Facet.ts :1044

  #### Returns string[]

  The currently excluded values.

### getSelectedValues

- getSelectedValues(): string[]

- Inherited from Facet.getSelectedValues

  - Defined in ui/Facet/Facet.ts :1026

  #### Returns string[]

  The currently selected values.

### getValueCaption

- getValueCaption(facetValue: IIndexFieldValue | FacetValue): string

- Overwrites Facet.getValueCaption

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :361

  #### Parameters

  - ##### facetValue: IIndexFieldValue | FacetValue

  #### Returns string

  The caption of the value.

### hasSelectedValue

- hasSelectedValue(value: string): boolean

- Inherited from Facet.hasSelectedValue

  - Defined in ui/Facet/Facet.ts :1035

  #### Parameters

  - ##### value: string

  #### Returns boolean

### hideWaitingAnimation

- hideWaitingAnimation(): void

- Inherited from Facet.hideWaitingAnimation

  - Defined in ui/Facet/Facet.ts :1141

  #### Returns void

### open

- open(value: FacetValue | IValueHierarchy | string): void

- - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :407

  #### Parameters

  - ##### value: FacetValue | IValueHierarchy | string

  #### Returns void

### reset

- reset(): void

- Overwrites Facet.reset

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :452

  #### Returns void

### selectMultipleValues

- selectMultipleValues(values: FacetValue[] | string[], selectChildren?: boolean): void

- Overwrites Facet.selectMultipleValues

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :225

  #### Parameters

  - ##### values: FacetValue[] | string[]

  - ##### Default value selectChildren: boolean = !this.options.useAnd

  #### Returns void

### selectValue

- selectValue(value: FacetValue | string, selectChildren?: boolean): void

- Overwrites Facet.selectValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :208

  #### Parameters

  - ##### value: FacetValue | string

  - ##### Default value selectChildren: boolean = !this.options.useAnd

  #### Returns void

### showLess

- showLess(): void

- Inherited from Facet.showLess

  - Defined in ui/Facet/Facet.ts :1235

  #### Returns void

### showMore

- showMore(): void

- Inherited from Facet.showMore

  - Defined in ui/Facet/Facet.ts :1219

  #### Returns void

### showWaitingAnimation

- showWaitingAnimation(): void

- Inherited from Facet.showWaitingAnimation

  - Defined in ui/Facet/Facet.ts :1130

  #### Returns void

### switchToAnd

- switchToAnd(): void

- Inherited from Facet.switchToAnd

  - Defined in ui/Facet/Facet.ts :1066

  #### Returns void

### switchToOr

- switchToOr(): void

- Inherited from Facet.switchToOr

  - Defined in ui/Facet/Facet.ts :1078

  #### Returns void

### toggleExcludeValue

- toggleExcludeValue(value: FacetValue | string): void

- Overwrites Facet.toggleExcludeValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :346

  #### Parameters

  - ##### value: FacetValue | string

  #### Returns void

### toggleSelectValue

- toggleSelectValue(value: FacetValue | string): void

- Overwrites Facet.toggleSelectValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :332

  #### Parameters

  - ##### value: FacetValue | string

  #### Returns void

### unexcludeMultipleValues

- unexcludeMultipleValues(values: FacetValue[] | string[]): void

- Inherited from Facet.unexcludeMultipleValues

  - Defined in ui/Facet/Facet.ts :962

  #### Parameters

  - ##### values: FacetValue[] | string[]

  #### Returns void

### unexcludeValue

- unexcludeValue(value: FacetValue | string, unexludeChildren?: boolean): void

- Overwrites Facet.unexcludeValue

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :293

  #### Parameters

  - ##### value: FacetValue | string

  - ##### Default value unexludeChildren: boolean = !this.options.useAnd

  #### Returns void

### updateSort

- updateSort(criteria: string): void

- Overwrites Facet.updateSort

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :399

  #### Parameters

  - ##### criteria: string

  #### Returns void

### Static get

- get(element: HTMLElement, componentClass?: any, noThrow?: boolean): BaseComponent

- Inherited from Component.get

  - Defined in ui/Base/Component.ts :410

  #### Parameters

  - ##### element: HTMLElement

  - ##### Optional componentClass: any

  - ##### Optional noThrow: boolean

  #### Returns BaseComponent

## Properties

### bind

bind: ComponentEvents

Inherited from Component.bind

- Defined in ui/Base/Component.ts :270

### componentOptionsModel

componentOptionsModel: ComponentOptionsModel

Inherited from Component.componentOptionsModel

- Defined in ui/Base/Component.ts :294

### componentStateModel

componentStateModel: ComponentStateModel

Inherited from Component.componentStateModel

- Defined in ui/Base/Component.ts :282

### disabled

disabled: boolean

Inherited from BaseComponent.disabled

- Defined in ui/Base/BaseComponent.ts :23

### facetSearch

facetSearch: FacetSearch

Inherited from Facet.facetSearch

- Defined in ui/Facet/Facet.ts :726

### facetSettings

facetSettings: FacetSettings

Inherited from Facet.facetSettings

- Defined in ui/Facet/Facet.ts :731

### logger

logger: Logger

Inherited from BaseComponent.logger

- Defined in ui/Base/BaseComponent.ts :18

### queryController

queryController: QueryController

Inherited from Component.queryController

- Defined in ui/Base/Component.ts :286

### queryStateModel

queryStateModel: QueryStateModel

Inherited from Component.queryStateModel

- Defined in ui/Base/Component.ts :278

### root

root: HTMLElement

Inherited from Component.root

- Defined in ui/Base/Component.ts :274

### searchInterface

searchInterface: SearchInterface

Inherited from Component.searchInterface

- Defined in ui/Base/Component.ts :290

### Static ID

ID: string

Inherited from BaseComponent.ID

- Defined in ui/Base/BaseComponent.ts :28

## Accessors

### usageAnalytics

usageAnalytics:

Inherited from Component.usageAnalytics

- Defined in ui/Base/Component.ts :343

## Component Options

### delimitingCharacter

delimitingCharacter: string

- Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :130

Markup configuration example(s) :

    data-delimiting-character='foo'

### levelEnd

levelEnd: number

- Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :160

Markup configuration example(s) :

    data-level-end='10'

### levelStart

levelStart: number

- Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :151

Markup configuration example(s) :

    data-level-start='10'

### marginByLevel

marginByLevel: number

- Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :167

Markup configuration example(s) :

    data-margin-by-level='10'

## Constructors

### constructor

- new HierarchicalFacet(element: HTMLElement, options: IHierarchicalFacetOptions, bindings: IComponentBindings): HierarchicalFacet

- Overwrites Facet.constructor

  - Defined in ui/HierarchicalFacet/HierarchicalFacet.ts :183

  #### Parameters

  - ##### element: HTMLElement

  - ##### options: IHierarchicalFacetOptions

  - ##### bindings: IComponentBindings

  #### Returns HierarchicalFacet

### Implements

- IFieldValueCompatibleFacet
- IComponentBindings