title: How can I distinguish whether Switch,Checkbox Value is changed by user or programmatically (including by retention)?
body: <pre><code>setOnCheckedChangeListener(new OnCheckedChangeListener() {
              @Override
              public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
                  // How to check whether the checkbox/switch has been checked
                  // by user or it has been checked programatically ?
  
                  if (isNotSetByUser())
                      return;
                  handleSetbyUser();
              }
          });
  </code></pre>
  
  <p>How to implement method <code>isNotSetByUser()</code>?</p>