---
title: "Discussion on \"Code Smell 35 - State as Properties\" | Hashnode"
description: "Discussion on \"Code Smell 35 - State as Properties\". When an object changes its state the best solution is to change the attribute, isn't it? \nProblems\n\nMutability\n\nAttributes polluting\n\nSetters\n\n\nhttps://maximilianocontieri.com/code-smell-28-setters\nSolutions\n1 - Model states as mathematical set inclu..."
url: "https://hashnode.com/posts/code-smell-35-state-as-properties/5fc06c9ff8981c482d131b80"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Code Smell 35 - State as Properties](https://maximilianocontieri.com/code-smell-35-state-as-properties?utm_source=hashnode&utm_medium=feed)

When an object changes its state the best solution is to change the attribute, isn't it? Problems Mutability Attributes polluting Setters https://maximilianocontieri.com/code-smell-28-setters Solutions 1 - Model states as mathematical set inclu...

Nov 27, 2020 · 2 min read · maximilianocontieri.com  
Read the article

-   [#programming](https://hashnode.com/tag/programming)
-   [#code-smell-1](https://hashnode.com/tag/code-smell-1)
-   [#2articles1week](https://hashnode.com/tag/2articles1week)
-   [#software-engineering](https://hashnode.com/tag/software-engineering)

## Written by

[Maxi Contieri](https://hashnode.com/@mcsee)

@mcsee · Buenos Aires

  
[View profile](https://hashnode.com/@mcsee)

Software Engineer

I’m a senior software engineer loving clean code, and declarative designs. S.O.L.I.D. and agile methodologies fan.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
