get difference in all

@param Verta|null $v

@return string
771926
public function formatDifference(Verta $v = null)
    {
        $difference = $this->diffSeconds($v);
        $absolute = $difference < 0 ? self::POST : self::PRE;
        $difference = abs($difference);

        for ($j = 0; $difference >= static::$unitNumber[$j] and $j < count(static::$unitNumber) - 1; $j++) {
            $difference /= static::$unitNumber[$j];
        }
        $difference = intval(round($difference));

        if($difference === 0) {
            return self::NOW;
        }

        return sprintf('%s %s %s', $difference, static::$unitName[$j], $absolute);
    }
133345
private function render_difference(): string
    {
        if (($period = $this->secondsSince()) < 60) {
            return \esc_html__('Few seconds ago', 'grotto-wp-posts');
        }

        if (($period = $this->minutesSince()) < 60) {
            return \sprintf(
                \esc_html(\_n(
                    '1 minute ago',
                    '%s minutes ago',
                    $period,
                    'grotto-wp-posts'
                )),
                \number_format_i18n($period)
            );
        }

        if (($period = $this->hoursSince()) < 24) {
            return \sprintf(
                \esc_html(\_n(
                    '1 hour ago',
                    '%s hours ago',
                    $period,
                    'grotto-wp-posts'
                )),
                \number_format_i18n($period)
            );
        }

        if (($period = $this->daysSince()) < 7) {
            return \sprintf(
                \esc_html(\_n(
                    '1 day ago',
                    '%s days ago',
                    $period,
                    'grotto-wp-posts'
                )),
                \number_format_i18n($period)
            );
        }

        if (($period = $this->weeksSince()) < 4) {
            return \sprintf(
                \esc_html(\_n(
                    '1 week ago',
                    '%s weeks ago',
                    $period,
                    'grotto-wp-posts'
                )),
                \number_format_i18n($period)
            );
        }

        if (($period = $this->monthsSince()) < 12) {
            return \sprintf(
                \esc_html(\_n(
                    '1 month ago',
                    '%s months ago',
                    $period,
                    'grotto-wp-posts'
                )),
                \number_format_i18n($period)
            );
        }

        $period = $this->yearsSince();
        return sprintf(
            \esc_html(\_n(
                '1 year ago',
                '%s years ago',
                $period,
                'grotto-wp-posts'
            )),
            \number_format_i18n($period)
        );
    }
1115478
public function getParam($prop)
    {
        if (isset($this->routeParams[$prop])) {
            return $this->routeParams[$prop];
        }
        
        $var = $this->searchParam($prop);
        
        if ($var) {
            global ${$var};
            return ${$var}[$prop];
        } else {
            if (isset($this->putParams[$prop])) {
                return $this->putParams[$prop];
            } elseif (isset($this->deleteParams[$prop])) {
                return $this->deleteParams[$prop];
            } elseif (isset($this->patchParams[$prop])) {
                return $this->patchParams[$prop];
            } elseif (isset($this->otherVerbParams[$prop])) {
                return $this->otherVerbParams[$prop];
            }
        }
        
        return null;
    }
966116
public static function compare($v1, $v2){
        $v1 = new SoftwareVersion($v1);
        $v2 = new SoftwareVersion($v2);
        
        return $v1->compareTo($v2);
    }
166455
public function getSwapTotal()
    {
        if (count($this->_swapDevices) > 0) {
            $total = 0;
            foreach ($this->_swapDevices as $dev) {
                $total += $dev->getTotal();
            }

            return $total;
        } else {
            return null;
        }
    }
679371
function &diff( $fromData, $toData)
    {
        if ( !$this->DiffEngineInstance )
            return null;

        $differ =& $this->DiffEngineInstance;
        $diffObject = $differ->createDifferenceObject( $fromData, $toData );
        return $diffObject;
    }
1157888
public function get_diff()
	{
		$diff = array(0 => array(), 1 => array());
		foreach ($this->_data as $key => $val)
		{
			if ($this->is_changed($key))
			{
				$diff[0][$key] = array_key_exists($key, $this->_original) ? $this->_original[$key] : null;
				$diff[1][$key] = $val;
			}
		}
		foreach ($this->_data_relations as $key => $val)
		{
			$rel = static::relations($key);
			if ($rel->singular)
			{
				$new_pk = null;
				if (empty($this->_original_relations[$key]) !== empty($val)
					or ( ! empty($this->_original_relations[$key]) and ! empty($val)
						and $this->_original_relations[$key] !== $new_pk = $val->implode_pk($val)
					))
				{
					$diff[0][$key] = isset($this->_original_relations[$key]) ? $this->_original_relations[$key] : null;
					$diff[1][$key] = isset($val) ? $new_pk : null;
				}
			}
			else
			{
				$original_pks = empty($this->_original_relations[$key]) ? array() : $this->_original_relations[$key];
				$new_pks = array();
				if ($val)
				{
					foreach ($val as $v)
					{
						if ( ! in_array(($new_pk = $v->implode_pk($v)), $original_pks))
						{
							$new_pks[] = $new_pk;
						}
						else
						{
							$original_pks = array_diff($original_pks, array($new_pk));
						}
					}
				}
				if ( ! empty($original_pks) or ! empty($new_pks)) {
					$diff[0][$key] = empty($original_pks) ? null : $original_pks;
					$diff[1][$key] = empty($new_pks) ? null : $new_pks;
				}
			}
		}

		return $diff;
	}
484128
public function findVirtual()
    {
        $results = [];
        foreach ($this->columns as $name => $column) {
            if ($column->isVirtual()) {
                $results[] = $name;
            }
        }

        return new Result($results, $this->columns);
    }
196854
public function diff($from, $to): string
    {
        $diff = $this->differ->diff($from, $to);

        if (preg_match(
            '/(?:[^\n]*(\n)){' . self::DIFF_MAX_LINES . '}/',
            $diff,
            $matches,
            PREG_OFFSET_CAPTURE
        )) {
            $diff = substr($diff, 0, $matches[1][1]);
        }

        return $diff;
    }
995337
public function getVat() : ?int 
    {
        if ( ! $this->hasVat()) {
            $this->setVat($this->getDefaultVat());
        }
        return $this->vat;
    }
830204
public function getDiff()
    {
        $diff = [];

        foreach ($this->getUpdated() as $key) {
            $diff[$key]['old'] = $this->old($key);

            $diff[$key]['new'] = $this->new($key);
        }

        return $diff;
    }
507126
public function getVat() : ?string 
    {
        if ( ! $this->hasVat()) {
            $this->setVat($this->getDefaultVat());
        }
        return $this->vat;
    }
675693
public function prev()
    {
        $value = prev($this->_data);
        return key($this->_data) !== null ? $value : null;
    }
732752
public function getInsertDiff()
    {
        return array_udiff_assoc(
            $this->collection->toArray(),
            $this->snapshot,
            function($a, $b) { return $a === $b ? 0 : 1; }
        );
    }
719061
public function get($input) {
    if ($input instanceof Vertice && $this->has($input)) {
      return $this->V[$input->label];
    } elseif (array_key_exists($input, $this->V)) {
      return $this->V[$input];
    } else {
      return NULL;
    }
  }
175535
public function getParam($var = null)
    {
        $param = $this->_parameters;
        if (null !== $var) {
            if (isset($this->_parameters[$var])) {
                $param = $this->_parameters[$var];
            } else {
                $param = null;
            }
        }

        return $param;
    }
741790
static private function _checkData($arr, $v) 
    {
        foreach($arr as $key=>$value)
        {
            if(!is_array($key)) { 
                if ($res = static::_checkString($key, $v)) {
                    return $res;
                }
            } else { 
                if ($res = static::_checkData($key, $v)) {
                    return $res;
                }
            }
            
            if(!is_array($value)) { 
                if ($res = static::_checkString($value, $v)) {
                    return $res;
                }
            } else { 
                if ($res = static::_checkData($value, $v)) {
                    return $res;
                }
            }
        }
        
        return null;
    }