title: Lock a boolean method (How to return nothing from a boolean method or discard)
body: <p>I have a <code>private boolean status;</code> field.</p>
  <p>I'm trying to lock a class methods in this way:</p>
  <p><code>status == true</code> means class is locked and <code>status == false</code> means class is unlock</p>
  <p>if the class has been locked so methods cant invoke like:</p>
  <pre><code>  protected void flip ()
      {
          if (locked()) return;
          face = (int) (Math.random() * 2);
      }
  </code></pre>
  <p>To understand the problem, consider this:</p>
  <pre><code>   protected boolean isHeads ()
      {
      //if(!locked()) return false or true;
      //if I write upper command then its true or false like the bottom command and its unclear that this false or true is for which of them
      //if(!locked())
      //if i write this command then i have to write another return and its the same problem too;
          return (face == HEADS);
          
      }
  </code></pre>
  <p>P.S: I have an interface so I can't change the method about <code>locked()</code> and lock and etc;</p>