MCPcopy Create free account
hub / github.com/Kitware/ParaView / ParseCommand

Method ParseCommand

Remoting/ClientServerStream/vtkClientServerStream.cxx:1657–1675  ·  view source on GitHub ↗

----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

1655
1656//----------------------------------------------------------------------------
1657unsigned char* vtkClientServerStream::ParseCommand(
1658 int order, unsigned char* data, unsigned char* begin, unsigned char* end)
1659{
1660 // Byte-swap this command's identifier.
1661 if (data > end - sizeof(vtkTypeUInt32))
1662 {
1663 /* ERROR */
1664 return nullptr;
1665 }
1666 this->PerformByteSwap(order, data, 1, sizeof(vtkTypeUInt32));
1667
1668 // Mark the start of the command.
1669 this->Internal->StartIndex =
1670 this->Internal->ValueOffsets.end() - this->Internal->ValueOffsets.begin();
1671 this->Internal->ValueOffsets.push_back(data - begin);
1672
1673 // Return the position after the command identifier.
1674 return data + sizeof(vtkTypeUInt32);
1675}
1676
1677//----------------------------------------------------------------------------
1678void vtkClientServerStream::ParseEnd()

Callers 1

ParseDataMethod · 0.95

Calls 4

PerformByteSwapMethod · 0.95
push_backMethod · 0.80
endMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected