'Returns index of nxm_entry of given type'

def index(self, t):

    if isinstance(t, nxm_entry):
        t = t._nxm_type
    if (t not in self._map):
        return (-1)
    return self._parts.find(t)
