Get the size of the already opened file

@return integer
164346
public function size()
    {
        $position = ftell($this->_fileHandle);
        fseek($this->_fileHandle, 0, SEEK_END);
        $size = ftell($this->_fileHandle);
        fseek($this->_fileHandle, $position);

        return $size;
    }
410875
public function fileSizeKB(): string
    {
        $size = $this->fileSizeBytes();
        $size = intdiv($size + 1023, 1024);

        /* I18N: size of file in KB */
        return I18N::translate('%s KB', I18N::number($size));
    }
147788
private function getFileName()
    {
        --$this->currentFileIndex;
        do{
            ++$this->currentFileIndex;
            $fileName = $this->currentNoIndexFileName;
            if($this->currentFileIndex > 0)
            {
                $fileName .= '(' . $this->currentFileIndex . ')';
            }
            $fileName .= $this->currentFileExt;
        }while(is_file($fileName) && filesize($fileName) >= $this->maxSize);
        return $fileName;
    }
545915
def get_size(self):
    
    if not self._is_open:
      raise IOError('Not opened.')

    if self._fsntfs_data_stream:
      return self._fsntfs_data_stream.get_size()
    return self._fsntfs_file_entry.get_size()
614386
public function getSize() : ?string 
    {
        if ( ! $this->hasSize()) {
            $this->setSize($this->getDefaultSize());
        }
        return $this->size;
    }
944693
public function size()
    {
        $size = 0;
        if ( ! is_null($this->time)) {
            $size += 1 + Protobuf::size_varint($this->time);
        }
        if ( ! is_null($this->contents)) {
            foreach ($this->contents as $v) {
                $l = $v->size();
                $size += 1 + Protobuf::size_varint($l) + $l;
            }
        }

        return $size;
    }
72477
public function getMaxUploadFileSize()
    {
        static $max_size = -1;

        if ($max_size < 0) {
            // Start with post_max_size.
            $max_size = $this->parseFileSize(ini_get('post_max_size'));

            // If upload_max_size is less, then reduce. Except if upload_max_size is
            // zero, which indicates no limit.
            $upload_max = $this->parseFileSize(ini_get('upload_max_filesize'));

            if ($upload_max > 0 && $upload_max < $max_size) {
                $max_size = $upload_max;
            }
        }
        return $max_size;
    }
485469
public function size()
	{
		if ($this->is_empty())
			return 0;

		$count = 0;

		foreach ($this->errors as $attribute => $error)
			$count += count($error);

		return $count;
	}
532505
public function getMaxUploadSize()
    {
        $maxUpload = (int)(ini_get('upload_max_filesize'));
        $maxPost = (int)(ini_get('post_max_size'));
        $memoryLimit = (int)(ini_get('memory_limit'));
        return min($maxUpload, $maxPost, $memoryLimit);
    }
680914
static function size($filename, $returnFormatted = false) {
        if ($returnFormatted && self::isReadable($filename)) {
            return Number::readableSize((double)filesize($filename));
        }

        return file_exists($filename) ? filesize($filename) : 0;
    }
1145560
public function isFileEmpty()
    {
        $this->openFile();
        $saved_pointer = $this->getFilePointer();
        $this->rewindFile()->seekFileToEnd();
        $size_pointer = $this->getFilePointer();
        $this->seekFile($saved_pointer);

        return $size_pointer === 0;
    }
831338
public function getLength()
        {
        	if(!$this->_hasGetLen) {
        		$this->_hasGetLen = true;
		        $this->_length = $this->_redis->llen($this->_key);
	        }
                return $this->_length;
        }
266738
public function getSize() : ?int 
    {
        if ( ! $this->hasSize()) {
            $this->setSize($this->getDefaultSize());
        }
        return $this->size;
    }
962297
public function getSize(): int
    {
        if ($this->caching == false) {
            return filesize($this->getAbsoluteFilePath());
        }

        if ($this->size == null) {
            $this->size = filesize($this->getAbsoluteFilePath());
        }

        return $this->size;
    }
1198872
public function getSize()
    {

        if ($this->size) {
            return $this->size;
        }

        $this->size = new Size($this->__get('width'), $this->__get('height'));

        return $this->size;
    }
791878
protected function getSizeInfo()
	{
		$size = array();
		// since we check $i + 1 we need to stop one step earlier
		$this->dataLength = strlen($this->data) - 1;

		$sofStartRead = true;

		// Look through file for SOF marker
		for ($i = 2; $i < $this->dataLength; $i++)
		{
			$marker = $this->getNextMarker($i, $sofStartRead);

			if (in_array($marker, $this->sofMarkers))
			{
				// Extract size info from SOF marker
				return $this->extractSizeInfo($i);
			}
			else
			{
				// Extract length only
				$markerLength = $this->extractMarkerLength($i);

				if ($markerLength < 2)
				{
					return $size;
				}

				$i += $markerLength - 1;
				continue;
			}
		}

		return $size;
	}
765986
public function dirsize()
    {
        $size = 0;
        $directory = Folder::slashTerm($this->path);
        $stack = [$directory];
        $count = count($stack);
        for ($i = 0, $j = $count; $i < $j; $i++) {
            if (is_file($stack[$i])) {
                $size += filesize($stack[$i]);
            } elseif (is_dir($stack[$i])) {
                $dir = dir($stack[$i]);
                if ($dir) {
                    while (($entry = $dir->read()) !== false) {
                        if ($entry === '.' || $entry === '..') {
                            continue;
                        }
                        $add = $stack[$i] . $entry;

                        if (is_dir($stack[$i] . $entry)) {
                            $add = Folder::slashTerm($add);
                        }
                        $stack[] = $add;
                    }
                    $dir->close();
                }
            }
            $j = count($stack);
        }

        return $size;
    }