connectionMessages.h 760 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #ifndef ASSETBUILDER_CONNECTIONMESSAGE_H
  9. #define ASSETBUILDER_CONNECTIONMESSAGE_H
  10. #include <QByteArray>
  11. namespace AssetProcessor
  12. {
  13. struct MessageHeader
  14. {
  15. unsigned int type;
  16. unsigned int size;
  17. unsigned int serial;
  18. };
  19. // This is the framing for all packets sent to/from the AssetProcessor
  20. struct Message
  21. {
  22. MessageHeader header;
  23. QByteArray payload;
  24. Message() = default;
  25. Message(const Message&) = default;
  26. };
  27. }
  28. #endif // ASSETBUILDER_CONNECTIONMESSAGE_H