title: How could I convert a 64-width binary string to long in Java?
body: <p>I want to convert a 64-width binary string to long, there is a static method:</p>
  
  <pre><code>Long.parseLong(String s, int radix)
  </code></pre>
  
  <p>to do this, but it isn't suitable for my case. </p>
  
  <p>The problem is my binary string is a machine-style long int. </p>
  
  <p>For example:</p>
  
  <p><code>1111111111111111111111111111111111111111111111111111111110000101</code> 
  represents <code>-123</code>, but this method recognize it as a huge positive number, this troubles me, how could I solve this problem? </p>
  
  <p>Must I write a function that does the complement?</p>