title: Call custom method in custom view with Data Binding
body: <p>Using Data Binding, how would I reference a custom method inside a custom view?  I'm attempting to set a listener inside my custom view...</p>
  
  <pre><code>public class MyCustomView extends LinearLayout {
  
      //...view init stuff
  
      private VisibilityListener mListener;
  
      public void setVisibilityListener(VisibilityListener listener) {
          mListener = listener;
      }
  
      public interface VisibilityListener {
          void onVisibilityChanged(boolean isVisible);
      }
  }
  </code></pre>
  
  <p></p>
  
  <pre><code>public class MainActivity extends AppCompatActivity implements VisibilityListener {
  
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate();
  
          MainActivityBinding binding = DataBindingUtil.setContentView(this, R.layout.main_activity);
  
          // What I'm trying to accomplish...
          binding.myCustomView.setVisibilityListener(this);
      }
  }
  </code></pre>