@ -4,11 +4,11 @@ All strings in the datagram are utf-8 encoded.
```Datagram format
1 byte: [0-7 (byte 0 ): VERSION(0x11, first quartet is major version, second is minor)]
1 byte: [8-15 (byte 1 ): REQUEST/RESPONSE CODE]
2 bytes: [16-31 (bytes 2-3): CHECKSUM (UDP only)]
4 bytes: [32-63 (bytes 4-7): PAYLOAD SIZE IN BYTES]
x bytes: [64-xx (bytes 8-?): PAYLOAD]
1 byte: [(byte 0 ): VERSION(0x11, first quartet is major version, second is minor)]
1 byte: [(byte 1 ): REQUEST/RESPONSE CODE]
2 bytes: [(bytes 2-3): CHECKSUM (UDP only)]
4 bytes: [(bytes 4-7): PAYLOAD SIZE IN BYTES]
x bytes: [(bytes 8-?): PAYLOAD]
```
@ -46,9 +46,9 @@ Payload size for Not found is zero.
Payload contains
```
8 bytes: [64-127 (bytes 8-16): OFFSET OF FILE CONTENT IN BYTES]
8 bytes: [128-191 (bytes 17-24): TOTAL FILESIZE]
4 bytes: [192-223 (bytes 25-28): FILENAME SIZE] (cannot be > to PAYLOAD_SIZE - 20 or be zero)
8 bytes: [(bytes 8-15): OFFSET OF FILE CONTENT IN BYTES]
8 bytes: [(bytes 16-23): TOTAL FILESIZE]
4 bytes: [(bytes 24-27): FILENAME SIZE] (cannot be > to PAYLOAD_SIZE - 20 or be zero)
y bytes: [<FILENAME>]
z bytes: [PARTIAL CONTENT]
```
@ -57,9 +57,9 @@ z bytes: [PARTIAL CONTENT]
Payload contains
```
8 bytes: [64-127 (bytes 8-16): OFFSET OF FILE CONTENT IN BYTES]
8 bytes: [128-191 (bytes 17-24): MAX SIZE OF PARTIAL CONTENT (partial content in response should not excess this size, but this can be less (by example if endoffile is reached or server doesn't have the full block requested)
4 bytes: [192-223 (bytes 25-28): FILENAME SIZE] (cannot be > to PAYLOAD_SIZE - 20 or be zero)
8 bytes: [(bytes 8-15): OFFSET OF FILE CONTENT IN BYTES]
8 bytes: [(bytes 16-23): MAX SIZE OF PARTIAL CONTENT (partial content in response should not excess this size, but this can be less (by example if endoffile is reached or server doesn't have the full block requested)
4 bytes: [(bytes 24-27): FILENAME SIZE] (cannot be > to PAYLOAD_SIZE - 20 or be zero)