# MarkAsUsed

> Bumps the timestamp of a cached file to be the current time.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.0/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

## MarkAsUsed(string, int)

Bumps the timestamp of a cached file to be the current time.

> **Warning:**
>
> **Deprecated.** Please use MarkAsUsed with Hash128 instead.

```csharp
public static bool MarkAsUsed(string url, int version)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): **** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)):&#x20;

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |

### Remarks

This allows you to keep files in the cache even if you are not explicitly loading them. Returns true if the url is cached.

## MarkAsUsed(string, Hash128)

Bumps the timestamp of a cached file to be the current time.

```csharp
public static bool MarkAsUsed(string url, Hash128 hash)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): **** (\[Hash128]\(/engine/6000.0/script-reference/unityengine/hash128)):&#x20;

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |

### Remarks

This allows you to keep files in the cache even if you are not explicitly loading them. Returns true if the url is cached.

## MarkAsUsed(CachedAssetBundle)

Bumps the timestamp of a cached file to be the current time.

```csharp
public static bool MarkAsUsed(CachedAssetBundle cachedBundle)
```

### Parameters

**** (\[CachedAssetBundle]\(/engine/6000.0/script-reference/unityengine/cachedassetbundle)):&#x20;

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |

### Remarks

This allows you to keep files in the cache even if you are not explicitly loading them. Returns true if the url is cached.
