# Setter

A method that validates or changes an object's stored value.

## What is **Setter** in C#?

**Setter** — A method that validates or changes an object's stored value.

```csharp
class Thermostat
{
    public int Temperature
    {
        get;
        set;
    }
}
```

Level: Journeyman · [More C# terms at this level](https://www.ask-codey.com/glossary/subjects/c-sharp/journeyman)

Updated: September 27, 2026

## In other subjects

- [Setter in Java](https://www.ask-codey.com/glossary/setter)
- [Setter in JavaScript](https://www.ask-codey.com/glossary/setter-javascript)
- [Setter in OOP](https://www.ask-codey.com/glossary/setter-oop)

Source: https://www.ask-codey.com/glossary/setter-c-sharp
