---
metadata:
  - name: generator
    content: Diplodoc Platform v5.39.1
alternate:
  - https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md
  - https://yandex.com/dev/jsapi-v2-1/doc/ru/v2-1/ref/reference/geometryEditor.model.ChildVertex.md
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.com/dev/jsapi-v2-1/doc/en/llms.txt

# geometryEditor.model.ChildVertex

{% note info %}

The constructor of the geometryEditor.model.ChildVertex class is hidden, as this class is not intended for autonomous initialization.

{% endnote %}

Extends [IGeometryEditorChildModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md).

Model for a child index. The constructor is not available in the package.full (a standard set of modules). This module is loaded on demand.

[Fields](#properties-summary) | [Methods](#methods-summary)

## Fields {#properties-summary}

#|
|| **Name** | **Type** | **Description** ||
|| [editor](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#editor) | [IGeometryEditor](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditor.md)| Geometry editor.

Inherited from [IGeometryEditorChildModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#editor). ||
|| [events](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IEventEmitter.md#events) | [IEventManager](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IEventManager.md)| Event manager.

Inherited from [IEventEmitter](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IEventEmitter.md#events). ||
|| [geometry](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#geometry) | [IBaseGeometry](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IBaseGeometry.md)| Geometry of the model.

Inherited from [IGeometryEditorChildModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#geometry). ||
|#

## Methods {#methods-summary}

#|
|| **Name** | **Returns** | **Description** ||
|| [destroy](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorModel.md#destroy)() | | Destructor.

Inherited from [IGeometryEditorModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorModel.md#destroy). ||
|| [getAllVerticesNumber](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#getAllVerticesNumber)() | Integer
| Returns the total number of vertexes in the geometry being edited. ||
|| [getIndex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#getIndex)() | Integer
| Returns the index of the child vertex in the parent model. ||
|| [getNextVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#getNextVertex)() | [geometryEditor.model.ChildVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md)\|null
| Returns a reference to the model for the next vertex. ||
|| [getParent](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#getParent)() | [IGeometryEditorModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorModel.md)
| Returns the parent data model.

Inherited from [IGeometryEditorChildModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#getParent). ||
|| [getPixels](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorModel.md#getPixels)() | Number[]
| Returns the model's pixel data.

Inherited from [IGeometryEditorModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorModel.md#getPixels). ||
|| [getPrevVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#getPrevVertex)() | [geometryEditor.model.ChildVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md)\|null
| Returns a reference to the model for the previous vertex. ||
|| [setGlobalPixels](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setGlobalPixels)([pixels](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setGlobalPixels-param-pixels)) | | Sets global pixel coordinates of the vertex. ||
|| [setIndex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setIndex)([index](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setIndex-param-index))  | | Sets the index of the child vertex in the parent model. ||
|| [setNextVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setNextVertex)([nextVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setNextVertex-param-nextVertex)) | | Sets the reference to the model for the next vertex. ||
|| [setPixels](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#setPixels)([pixels](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#setPixels-param-pixels)) | | Sets the model's pixel data.

Inherited from [IGeometryEditorChildModel](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/IGeometryEditorChildModel.md#setPixels). ||
|| [setPrevVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setPrevVertex)([prevVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md#setPrevVertex-param-prevVertex)) | | Sets the reference to the model for the previous vertex. ||
|#

## Methods details {#method_detail}

### getAllVerticesNumber {#getAllVerticesNumber}

```javascript
{Integer} getAllVerticesNumber()
```

**Returns** the total number of vertexes in the geometry being edited.

### getIndex {#getIndex}

```javascript
{Integer} getIndex()
```

**Returns** the index of the child vertex in the parent model.

### getNextVertex {#getNextVertex}

```javascript
{geometryEditor.model.ChildVertex|null} getNextVertex()
```

**Returns** a reference to the model for the next vertex.

### getPrevVertex {#getPrevVertex}

```javascript
{geometryEditor.model.ChildVertex|null} getPrevVertex()
```

**Returns** a reference to the model for the previous vertex.

### setGlobalPixels  {#setGlobalPixels}

```javascript
{} setGlobalPixels(pixels)
```

Sets global pixel coordinates of the vertex.

**Parameters:**

#|
|| **Parameter** | **Default value** | **Description**  ||
|| [`pixels`](#setGlobalPixels-param-pixels)[*](*star) | — | Type: Number[]

Global pixel coordinates of the vertex. ||
|#

\* Mandatory parameter/option.

### setIndex {#setIndex}

```javascript
{} setIndex(index)
```

Sets the index of the child vertex in the parent model.

**Parameters:**

#|
|| **Parameter** | **Default value** | **Description**  ||
|| [`index`](#setIndex-param-index)[*](*star) | — | Type: Integer

Index of a child vertex. ||
|#

\* Mandatory parameter/option.

### setNextVertex {#setNextVertex}

```javascript
{} setNextVertex(nextVertex)
```

Sets the reference to the model for the next vertex.

**Parameters:**

#|
|| **Parameter** | **Default value** | **Description**  ||
|| [`nextVertex`](#setNextVertex-param-nextVertex)[*](*star) | — | Type: [geometryEditor.model.ChildVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md)\|null

Model for the next vertex. ||
|#

\* Mandatory parameter/option.

### setPrevVertex {#setPrevVertex}

```javascript
{} setPrevVertex(prevVertex)
```

Sets the reference to the model for the previous vertex.

**Parameters:**

#|
|| **Parameter** | **Default value** | **Description**  ||
|| [`prevVertex`](#setPrevVertex-param-prevVertex)[*](*star) | — | Type: [geometryEditor.model.ChildVertex](https://yandex.com/dev/jsapi-v2-1/doc/en/v2-1/ref/reference/geometryEditor.model.ChildVertex.md)\|null

Model for the previous vertex. ||
|#

\* Mandatory parameter/option.

[*star]: Mandatory parameter/option.