diff options
| author | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2023-09-21 01:53:59 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-09-21 01:53:59 +0300 |
| commit | 171e350e348afadb55967b9c13d5eadc7f7d2cf4 (patch) | |
| tree | 14ec93df8ccc1aca0cf453f826d46a402b09dc8f /pkg/messages/types/svcPacketEntities.go | |
| parent | define todos on packets (diff) | |
| download | sdp.go-171e350e348afadb55967b9c13d5eadc7f7d2cf4.tar.gz sdp.go-171e350e348afadb55967b9c13d5eadc7f7d2cf4.tar.bz2 sdp.go-171e350e348afadb55967b9c13d5eadc7f7d2cf4.zip | |
add strings builder, customize ALL outputs (#6)
Diffstat (limited to 'pkg/messages/types/svcPacketEntities.go')
| -rw-r--r-- | pkg/messages/types/svcPacketEntities.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pkg/messages/types/svcPacketEntities.go b/pkg/messages/types/svcPacketEntities.go index 2d86bf2..05b6794 100644 --- a/pkg/messages/types/svcPacketEntities.go +++ b/pkg/messages/types/svcPacketEntities.go | |||
| @@ -2,6 +2,7 @@ package messages | |||
| 2 | 2 | ||
| 3 | import ( | 3 | import ( |
| 4 | "github.com/pektezol/bitreader" | 4 | "github.com/pektezol/bitreader" |
| 5 | "github.com/pektezol/demoparser/pkg/writer" | ||
| 5 | ) | 6 | ) |
| 6 | 7 | ||
| 7 | type SvcPacketEntities struct { | 8 | type SvcPacketEntities struct { |
| @@ -30,5 +31,12 @@ func ParseSvcPacketEntities(reader *bitreader.Reader) SvcPacketEntities { | |||
| 30 | svcPacketEntities.Length = uint32(reader.TryReadBits(20)) | 31 | svcPacketEntities.Length = uint32(reader.TryReadBits(20)) |
| 31 | svcPacketEntities.UpdatedBaseline = reader.TryReadBool() | 32 | svcPacketEntities.UpdatedBaseline = reader.TryReadBool() |
| 32 | svcPacketEntities.Data = reader.TryReadBitsToSlice(uint64(svcPacketEntities.Length)) | 33 | svcPacketEntities.Data = reader.TryReadBitsToSlice(uint64(svcPacketEntities.Length)) |
| 34 | writer.TempAppendLine("\t\tMax Entries: %d", svcPacketEntities.MaxEntries) | ||
| 35 | writer.TempAppendLine("\t\tIs Delta: %t", svcPacketEntities.IsDelta) | ||
| 36 | writer.TempAppendLine("\t\tDelta From: %d", svcPacketEntities.DeltaFrom) | ||
| 37 | writer.TempAppendLine("\t\tBaseline: %t", svcPacketEntities.BaseLine) | ||
| 38 | writer.TempAppendLine("\t\tUpdated Baseline: %t", svcPacketEntities.UpdatedBaseline) | ||
| 39 | writer.TempAppendLine("\t\t%d Updated Entries:", svcPacketEntities.UpdatedEntries) | ||
| 40 | writer.TempAppendLine("\t\tData: %v", svcPacketEntities.Data) | ||
| 33 | return svcPacketEntities | 41 | return svcPacketEntities |
| 34 | } | 42 | } |