qy.java 3.44 KB
import com.google.common.hash.AbstractStreamingHashFunction;
import com.google.common.hash.AbstractStreamingHashFunction.AbstractStreamingHasher;
import com.google.common.hash.HashCode;
import com.google.common.hash.Hasher;
import com.google.common.primitives.UnsignedBytes;
import java.io.Serializable;
import java.nio.ByteBuffer;
import javax.annotation.Nullable;

public final class qy
  extends AbstractStreamingHashFunction
  implements Serializable
{
  private static final long serialVersionUID = 0L;
  private final int a;
  
  public qy(int paramInt)
  {
    this.a = paramInt;
  }
  
  private static int b(int paramInt)
  {
    return Integer.rotateLeft(-862048943 * paramInt, 15) * 461845907;
  }
  
  private static int c(int paramInt1, int paramInt2)
  {
    return Integer.rotateLeft(paramInt1 ^ paramInt2, 13) * 5 - 430675100;
  }
  
  private static HashCode d(int paramInt1, int paramInt2)
  {
    paramInt1 ^= paramInt2;
    paramInt1 = (paramInt1 ^ paramInt1 >>> 16) * -2048144789;
    paramInt1 = (paramInt1 ^ paramInt1 >>> 13) * -1028477387;
    return HashCode.fromInt(paramInt1 ^ paramInt1 >>> 16);
  }
  
  public final int bits()
  {
    return 32;
  }
  
  public final boolean equals(@Nullable Object paramObject)
  {
    boolean bool2 = false;
    boolean bool1 = bool2;
    if ((paramObject instanceof qy))
    {
      paramObject = (qy)paramObject;
      bool1 = bool2;
      if (this.a == ((qy)paramObject).a) {
        bool1 = true;
      }
    }
    return bool1;
  }
  
  public final int hashCode()
  {
    return getClass().hashCode() ^ this.a;
  }
  
  public final HashCode hashInt(int paramInt)
  {
    paramInt = b(paramInt);
    return d(c(this.a, paramInt), 4);
  }
  
  public final HashCode hashLong(long paramLong)
  {
    int j = (int)paramLong;
    int i = (int)(paramLong >>> 32);
    j = b(j);
    return d(c(c(this.a, j), b(i)), 8);
  }
  
  public final HashCode hashUnencodedChars(CharSequence paramCharSequence)
  {
    int i = this.a;
    int j = 1;
    while (j < paramCharSequence.length())
    {
      i = c(i, b(paramCharSequence.charAt(j - 1) | paramCharSequence.charAt(j) << '\020'));
      j += 2;
    }
    j = i;
    if ((paramCharSequence.length() & 0x1) == 1) {
      j = i ^ b(paramCharSequence.charAt(paramCharSequence.length() - 1));
    }
    return d(j, paramCharSequence.length() * 2);
  }
  
  public final Hasher newHasher()
  {
    return new qy.a(this.a);
  }
  
  public final String toString()
  {
    int i = this.a;
    return 31 + "Hashing.murmur3_32(" + i + ")";
  }
  
  static final class a
    extends AbstractStreamingHashFunction.AbstractStreamingHasher
  {
    private int a;
    private int b;
    
    a(int paramInt)
    {
      super();
      this.a = paramInt;
      this.b = 0;
    }
    
    public final HashCode a()
    {
      return qy.b(this.a, this.b);
    }
    
    protected final void process(ByteBuffer paramByteBuffer)
    {
      int i = qy.a(paramByteBuffer.getInt());
      this.a = qy.a(this.a, i);
      this.b += 4;
    }
    
    protected final void processRemaining(ByteBuffer paramByteBuffer)
    {
      int i = 0;
      this.b += paramByteBuffer.remaining();
      int j = 0;
      while (paramByteBuffer.hasRemaining())
      {
        j ^= UnsignedBytes.toInt(paramByteBuffer.get()) << i;
        i += 8;
      }
      this.a ^= qy.a(j);
    }
  }
}


/* Location:              /home/merong/decompile/hackery-dex2jar.jar!/qy.class
 * Java compiler version: 6 (50.0)
 * JD-Core Version:       0.7.1
 */