include::../description.adoc[]

== Noncompliant Code Example

----
class Program
{
    public int Foo  //Non-Compliant
    {
        set
        {
            // ... some code ...
        }
    }
}
----

== Compliant Solution

----
class Program
{
    private int foo;

    public void SetFoo(int value)
    {
        // ... some code ...
        foo = value;
    }
}
----

or


----
class Program
{
  public int Foo { get; set; } // Compliant
}
----
