/*
 * Copyright (C) 2008 The Trustees of Columbia University in the City of New York. 
 * All rights reserved.
 *
 * See the file LICENSE included in this distribution for details.
 */

#ifndef _DISTANCE_H
#define _DISTANCE_H

#ifdef _WENGO
#include "p2pp/common/types.h"
#include "p2pp/bigint/bigint.h"
#endif

#ifndef _WENGO
#include "types.h"
#include "bigint.h"
#endif

class Distance {

protected:
  uint32 m_uiBase; //variable which tells the size of the log base
  uint32 m_uiKeyLen; //Length of the key in bits
  uint32 m_uiLastIndex;

  BigInt m_objKey; //The base key from which all computations are made

public:
  Distance();
  virtual ~Distance();  

  void setParams(uint32 uiBase, uint32 uiKeyLen);
  uint32 getBase();
  

  void setKey(const BigInt& objKey);
  BigInt getKey();

  virtual int32 getKeyAt(uint32 iPos, BigInt& objInt);

};
//Distance


#endif
