|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.memphis.ccrg.lida.episodicmemory.sdm.HardLocationImpl
public class HardLocationImpl
Default implementation of HardLocation.
Constructor Summary | |
---|---|
HardLocationImpl(cern.colt.bitvector.BitVector address)
|
|
HardLocationImpl(cern.colt.bitvector.BitVector address,
int wordLength)
|
Method Summary | |
---|---|
cern.colt.bitvector.BitVector |
getAddress()
|
byte[] |
getCounters()
Returns the counters of this HardLocation Each HardLocation has wordSize counters. |
int |
getWriteCount()
|
int |
hammingDistance(cern.colt.bitvector.BitVector vector)
Returns the Hamming distance between vector and the address of this HardLocation |
int[] |
read(int[] buff)
This method reads this HardLocation and sums the reading vector to int[] buffer. |
void |
setAddress(cern.colt.bitvector.BitVector address)
Sets the address of this HardLocation in the vector Space |
void |
setCounters(byte[] newCounters)
Sets the counters of this HardLocation Each HardLocation has wordSize counters. |
void |
write(cern.colt.bitvector.BitVector word)
Writes BitVector word to this HardLocation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HardLocationImpl(cern.colt.bitvector.BitVector address, int wordLength)
address
- BitVector
wordLength
- intpublic HardLocationImpl(cern.colt.bitvector.BitVector address)
address
- BitVector address of this HardLocationMethod Detail |
---|
public cern.colt.bitvector.BitVector getAddress()
getAddress
in interface HardLocation
public void setAddress(cern.colt.bitvector.BitVector address)
HardLocation
setAddress
in interface HardLocation
address
- the address to setpublic byte[] getCounters()
HardLocation
getCounters
in interface HardLocation
public int getWriteCount()
getWriteCount
in interface HardLocation
public void write(cern.colt.bitvector.BitVector word)
HardLocation
write
in interface HardLocation
word
- word to be writtenpublic void setCounters(byte[] newCounters)
HardLocation
setCounters
in interface HardLocation
newCounters
- new counterspublic int[] read(int[] buff)
HardLocation
read
in interface HardLocation
buff
- buffer to be added to this hardlocation
public int hammingDistance(cern.colt.bitvector.BitVector vector)
HardLocation
hammingDistance
in interface HardLocation
vector
- vector to compare with this hardlocation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |