lib/sp_store/p_chip/soft_node_cache.rb
def check_entry(entry)
    if entry < 0 || entry >= @capacity
      raise ArgumentError, "Invalid cache entry #{entry.inspect}"
    end
  end
# Checks that an entry number points to a valid entry in the cache.
#
# Args:
#   entry:: the entry number to be verified
#
# Raises:
#   RuntimeError:: if the entry number is invalid
#
# This method is called by public methods to validate their arguments. The
# method can be made unnecessary in the FPGA implementation, if the cache
# holds 2^n entries (only n bits will be read from the entry arguments).
Checks that an entry number points to a valid entry in the cache.
Args:
entry:: the entry number to be verified

: if the entry number is invalid

This method is called by public methods to validate their arguments. The
method can be made unnecessary in the FPGA implementation, if the cache
holds 2^n entries (only n bits will be read from the entry arguments).
Checks that an entry number points to a valid entry in the cache . Args : entry :: the entry number to be verified : if the entry number is invalid This method is called by public methods to validate their arguments . The method can be made unnecessary in the FPGA implementation if the cache holds 2^n entries ( only n bits will be read from the entry arguments ) .
def check_entry(entry)
    if entry < 0 || entry >= @capacity
      raise ArgumentError, "Invalid cache entry #{entry.inspect}"
    end
  end
def check_entry ( entry ) if entry < 0 || entry >= @capacity raise ArgumentError , "Invalid cache entry #{entry.inspect}" end end
Checks that an entry number points to a valid entry in the cache.
Checks that an entry number points to a valid entry in the cache .
entry