How about adding IBytes
and IBencodex
?
#2560
Closed
greymistcube
started this conversation in
Ideas
Replies: 1 comment
-
Closing, since now we have |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
There are numerous entities in libplanet using
ImmutableArray<byte>
,byte[]
, and/orIValue
, most, if not all, of which have a canonical representation where conversion between the three are done quite frequently. However, without an overarchinginterface
, there are several problems:class
orstruct
wanting to haveImmutableArray<byte>
,byte[]
, and/orIValue
representation can have wildly different property/method names.Codec
instantiation.ImmutableArray<byte>
andbyte[]
.I'm thinking something along the lines of the following:
I'm not satisfied with the names tho. 🙄
I forgot where
ToByteArray()
andByteArray
were originally derived from, even though I am already accustomed to it, but I personally think it is really confusing to haveImmutableArray<byte> ByteArray
andbyte[] ToByteArray()
as they are currently being used.Beta Was this translation helpful? Give feedback.
All reactions