switch ( tFilter.m_eType )
{
case SPH_FILTER_RANGE:
tFilter.m_uMinValue = ( iVer>=0x114 ) ? tReq.GetUint64() : tReq.GetDword ();
tFilter.m_uMaxValue = ( iVer>=0x114 ) ? tReq.GetUint64() : tReq.GetDword ();
break;
case SPH_FILTER_FLOATRANGE:
tFilter.m_fMinValue = tReq.GetFloat ();
tFilter.m_fMaxValue = tReq.GetFloat ();
break;
case SPH_FILTER_VALUES:
{
bool bRes = ( iVer>=0x114 )
? tReq.GetQwords ( tFilter.m_dValues, g_iMaxFilterValues, "invalid attribute set length %d (should be in 0..%d range)" )
: tReq.GetDwords ( tFilter.m_dValues, g_iMaxFilterValues, "invalid attribute set length %d (should be in 0..%d range)" );
if ( !bRes )
return false;
}
break;
default:
tReq.SendErrorReply ( "unknown filter type (type-id=%d)", tFilter.m_eType );
return false;
}