@Override
  public void tracePreExecution(final MessageFrame messageFrame) {
    stack = new ArrayList<>(messageFrame.stackSize());
    for (int i = messageFrame.stackSize() - 1; i >= 0; i--) {
      stack.add("\"" + shortBytes(messageFrame.getStackItem(i)) + "\"");
    }
    pc = messageFrame.getPC();
    section = messageFrame.getSection();
    gas = messageFrame.getRemainingGas();
    memorySize = messageFrame.memoryWordSize() * 32;
    if (showMemory && memorySize > 0) {
      memory = messageFrame.readMemory(0, messageFrame.memoryWordSize() * 32L);
    } else {
      memory = null;
    }
    depth = messageFrame.getMessageStackSize();
    functionDepth =
        messageFrame.getCode().getEofVersion() > 0 ? messageFrame.returnStackSize() + 1 : 0;

    StringBuilder sb = new StringBuilder();
    if (showStorage) {
      var updater = messageFrame.getWorldUpdater();
      var account = updater.getAccount(messageFrame.getRecipientAddress());
      if (account != null && !account.getUpdatedStorage().isEmpty()) {
        boolean[] shownEntry = {false};
        sb.append(",\"storage\":{");
        account
            .getUpdatedStorage()
            .forEach(
                (k, v) -> {
                  if (shownEntry[0]) {
                    sb.append(",");
                  } else {
                    shownEntry[0] = true;
                  }
                  sb.append("\"")
                      .append(k.toQuantityHexString())
                      .append("\":\"")
                      .append(v.toQuantityHexString())
                      .append("\"");
                });
        sb.append("}");
      }
    }
    storageString = sb.toString();
  }
Long number as hex string.

@param number the number
@return the string
evm/src/main/java/org/hyperledger/besu/evm/tracing/StandardJsonTracer.java