Package sizzle.types

Source Code of sizzle.types.SizzleFingerprint

package sizzle.types;

import sizzle.compiler.TypeException;

/**
* A {@link SizzleScalar} representing a 64 bit signature value.
*
* @author anthonyu
*
*/
public class SizzleFingerprint extends SizzleScalar {
  /** {@inheritDoc} */
  @Override
  public SizzleScalar arithmetics(final SizzleType that) {
    // no math for fingerprints
    throw new TypeException("incorrect type " + this + " for arithmetic with " + that);
  }

  /** {@inheritDoc} */
  @Override
  public boolean accepts(final SizzleType that) {
    return this.assigns(that);
  }

  /** {@inheritDoc} */
  @Override
  public String toJavaType() {
    return "long";
  }

  /** {@inheritDoc} */
  @Override
  public String toString() {
    return "fingerprint";
  }
}
TOP

Related Classes of sizzle.types.SizzleFingerprint

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.