| Naming Operations

## Renaming an Object

> You can rename an object in a context by using `Context.rename()`.

> >     // Rename to old_report.txt
> >     ctx.rename("report.txt", "old_report.txt");

> This example renames the object that was bound to `"report.txt"` to `"old_report.txt"`. After verifying that the object got renamed, the program renames it to its original name (`"report.txt"`), as follows.

> >     // Rename back to report.txt
> >     ctx.rename("old_report.txt", "report.txt");

| Naming Operations