# Equals

> Checks if the StringView is equal to the object.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.Search](/engine/6000.6/script-reference/unityeditor/search.md)
* **Assembly:** UnityEditor

## Equals(StringView)

Checks if the [StringView](/engine/6000.6/script-reference/unityeditor/search/stringview.md) is equal to the object.

```csharp
public bool Equals(StringView other)
```

### Parameters

**** (\[StringView]\(/engine/6000.6/script-reference/unityeditor/search/stringview)): An object.

### Returns

| Type                                                          | Description                              |
| ------------------------------------------------------------- | ---------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if they are equal, otherwise false. |

## Equals(Object)

Checks if the [StringView](/engine/6000.6/script-reference/unityeditor/search/stringview.md) is equal to the object.

```csharp
public override bool Equals(object other)
```

### Parameters

**** (\[Object]\(https\://learn.microsoft.com/dotnet/api/system.object)): An object.

### Returns

| Type                                                          | Description                              |
| ------------------------------------------------------------- | ---------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if they are equal, otherwise false. |

## Equals(string, StringComparison)

Checks if the [StringView](/engine/6000.6/script-reference/unityeditor/search/stringview.md) is equal to the object.

```csharp
public bool Equals(string other, StringComparison comparisonOptions = StringComparison.OrdinalIgnoreCase)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): An object.**** (\[StringComparison]\(https\://learn.microsoft.com/dotnet/api/system.stringcomparison)):&#x20;

### Returns

| Type                                                          | Description                              |
| ------------------------------------------------------------- | ---------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if they are equal, otherwise false. |

## Equals(StringView, StringComparison)

Checks if the [StringView](/engine/6000.6/script-reference/unityeditor/search/stringview.md) is equal to the object.

```csharp
public bool Equals(StringView other, StringComparison comparisonOptions)
```

### Parameters

**** (\[StringView]\(/engine/6000.6/script-reference/unityeditor/search/stringview)): An object.**** (\[StringComparison]\(https\://learn.microsoft.com/dotnet/api/system.stringcomparison)):&#x20;

### Returns

| Type                                                          | Description                              |
| ------------------------------------------------------------- | ---------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if they are equal, otherwise false. |
