# Instance accessors

## Public

### `Wrap.prototype.closing`

The [`get`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get) accessor gets the [closing](/text/wrapper/basic-concepts.md#closing) of the wrap by returning the [`#closing`](/text/wrapper/wrapped/instance-properties.md#closing) property of the specified object.

{% code title="wrap.class.ts" %}

```typescript
public get closing(): Closing {
  return this.#closing;
}
```

{% endcode %}

#### Returns

The **return value** is the wrap [closing](/text/wrapper/basic-concepts.md#closing) of a generic type variable [`Closing`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than...-closing-greater-than).

### `Wrap.prototype.opening`

The [`get`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get) accessor gets the [opening](/text/wrapper/basic-concepts.md#opening) of the wrap by returning the [`#opening`](/text/wrapper/wrapped/instance-properties.md#opening) property of the specified object.

{% code title="wrap.class.ts" %}

```typescript
public get opening(): Opening {
  return this.#opening;
}
```

{% endcode %}

#### Returns

The **return value** is the wrap [opening](/text/wrapper/basic-concepts.md#opening) of a generic type variable [`Opening`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than-opening-...greater-than).

### `Wrap.prototype.wrap`

The [`get`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get) accessor gets the wrap consisting of the opening and closing.

{% code title="wrap.class.ts" %}

```typescript
public get wrap(): `${Opening}${Closing}` {
  return this.value;
}
```

{% endcode %}

#### Returns

The **return value** is the wrap of a generic type variable in order [`Opening`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than-opening-...greater-than) and [`Closing`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than...-closing-greater-than) on the template.

### `Wrap.prototype.value`

The [`get`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get) accessor gets the wrap consisting of the opening and closing.

{% code title="wrap.class.ts" %}

```typescript
public get value(): `${Opening}${Closing}` {
  return this.valueOf();
}
```

{% endcode %}

#### Returns

The **return value** is the wrap of a generic type variable in order [`Opening`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than-opening-...greater-than) and [`Closing`](https://docs.angular-package.dev/text/wrapper/wrap/pages/SYPkCWCkQnshiX32nwLt#wrap-less-than...-closing-greater-than) on the template.

### `[Symbol.toStringTag]`

The [`get`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get) accessor, with the help of [`toStringTag`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/toStringTag) of Symbol, changes the default object tag to `wrap` for an instance of the [`Wrap`](/text/wrapper/wrap.md).

{% hint style="info" %}
**Good to know:** The property can be read by the `typeOf()` function of the type package.
{% endhint %}

{% code title="wrap.class.ts" %}

```typescript
public get [Symbol.toStringTag](): string {
  return 'wrap';
}
```

{% endcode %}

#### Example usage

```typescript
// Example usage.
import { Wrap } from '@angular-package/text';
import { typeOf } from '@angular-package/type';

// Define the wrap.
const tagWrap = new Wrap('[', ']');

// Returns wrap.
typeOf(tagWrap);
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.angular-package.dev/text/wrapper/wrap/instance-accessors.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
