import”@patchwork/contracts/PatchworkUtils/PatchworkUtils.sol”;
Functions
toString8
Converts uint64 raw data to an 8 character string| Name | Type | Description | 
|---|---|---|
raw | uint64 | the raw data | 
| Name | Type | Description | 
|---|---|---|
out | string | the string | 
toString16
Converts uint128 raw data to a 16 character string| Name | Type | Description | 
|---|---|---|
raw | uint128 | the raw data | 
| Name | Type | Description | 
|---|---|---|
out | string | the string | 
toString32
Converts uint256 raw data to a 32 character string| Name | Type | Description | 
|---|---|---|
raw | uint256 | the raw data | 
| Name | Type | Description | 
|---|---|---|
out | string | the string | 
trimUp
Trims a raw string to its null-terminated length| Name | Type | Description | 
|---|---|---|
byteArray | bytes | the raw string | 
| Name | Type | Description | 
|---|---|---|
out | string | the trimmed string | 
convertUint16ToBytes
Converts a uint16 into a 2-byte array| Name | Type | Description | 
|---|---|---|
input | uint16 | the uint16 | 
| Name | Type | Description | 
|---|---|---|
<none> | bytes | bytes the array | 
strToUint256
Converts a string to a uint256| Name | Type | Description | 
|---|---|---|
str | string | the string to convert | 
| Name | Type | Description | 
|---|---|---|
val | uint256 | the uint256 value |