int QueryStillImageSensorConfigurations::WriteMessageBody(Packet& packet) const
{
    UInt startPos = packet.GetWritePos();
    UShort count = (UShort)mSensorList.size();
    List::const_iterator stillImageSensorConfigurations = mSensorList.begin();
    packet.Write(count);
    while(stillImageSensorConfigurations != mSensorList.end())
    {
        packet.Write(stillImageSensorConfigurations->GetSensorId());          //required
        packet.Write(stillImageSensorConfigurations->GetPresenceVector());    //required
        stillImageSensorConfigurations++;
    }

    return packet.GetWritePos() - startPos;
}
int QueryRangeSensorCapabilities::WriteMessageBody(Packet& packet) const
{
    UInt startPos = packet.GetWritePos();
    UShort count = (UShort)mSensorList.size();
    List::const_iterator sensor = mSensorList.begin();
    packet.Write(count);
    while(sensor != mSensorList.end())
    {
        packet.Write(sensor->GetSensorId());           //required
        packet.Write(sensor->GetPresenceVector());     //required
        sensor++;
    }

    return packet.GetWritePos() - startPos;
}
int QueryVisualSensorConfigurations::WriteMessageBody(Packet& packet) const
{
    UInt startPos = packet.GetWritePos();
    UShort count = (UShort)mSensorList.size();
    List::const_iterator visualSensorConfiguration = mSensorList.begin();
    packet.Write(count);
    while(visualSensorConfiguration != mSensorList.end())
    {
        packet.Write(visualSensorConfiguration->GetSensorID());           //required
        packet.Write(visualSensorConfiguration->GetPresenceVector());     //required
        visualSensorConfiguration++;
    }

    return packet.GetWritePos() - startPos;
}