You are here

protected function MigrateExecutable::formatSize in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate/src/MigrateExecutable.php \Drupal\migrate\MigrateExecutable::formatSize()
  2. 10 core/modules/migrate/src/MigrateExecutable.php \Drupal\migrate\MigrateExecutable::formatSize()

Generates a string representation for the given byte count.

Parameters

int $size: A size in bytes.

Return value

string A translated string representation of the size.

1 call to MigrateExecutable::formatSize()
MigrateExecutable::memoryExceeded in core/modules/migrate/src/MigrateExecutable.php
Tests whether we've exceeded the desired memory threshold.
1 method overrides MigrateExecutable::formatSize()
TestMigrateExecutable::formatSize in core/modules/migrate/tests/src/Unit/TestMigrateExecutable.php
Generates a string representation for the given byte count.

File

core/modules/migrate/src/MigrateExecutable.php, line 573

Class

MigrateExecutable
Defines a migrate executable class.

Namespace

Drupal\migrate

Code

protected function formatSize($size) {
  return format_size($size);
}