mirror of
https://gh.wpcy.net/https://github.com/mainwp/mainwp.dev.git
synced 2026-07-17 00:08:35 +08:00
3938 lines
210 KiB
HTML
3938 lines
210 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>MainWP Child Documentation</title>
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<base href="../">
|
|
<link rel="icon" href="images/favicon.ico"/>
|
|
<link rel="stylesheet" href="css/normalize.css">
|
|
<link rel="stylesheet" href="css/base.css">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com">
|
|
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@100;200;300;400;600;700&display=swap" rel="stylesheet">
|
|
<link href="https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@400;600;700&display=swap" rel="stylesheet">
|
|
<link rel="stylesheet" href="css/template.css">
|
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.0/css/all.min.css" integrity="sha256-ybRkN9dBjhcS2qrW1z+hfCxq+1aBdwyQM5wlQoQVt/0=" crossorigin="anonymous" />
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/themes/prism-okaidia.css">
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.css">
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.css">
|
|
<script src="https://cdn.jsdelivr.net/npm/fuse.js@3.4.6"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/css-vars-ponyfill@2"></script>
|
|
<script src="js/template.js"></script>
|
|
<script src="js/search.js"></script>
|
|
<script defer src="js/searchIndex.js"></script>
|
|
</head>
|
|
<body id="top">
|
|
<header class="phpdocumentor-header phpdocumentor-section">
|
|
<h1 class="phpdocumentor-title"><a href="" class="phpdocumentor-title__link">MainWP Child Documentation</a></h1>
|
|
<input class="phpdocumentor-header__menu-button" type="checkbox" id="menu-button" name="menu-button" />
|
|
<label class="phpdocumentor-header__menu-icon" for="menu-button">
|
|
<i class="fas fa-bars"></i>
|
|
</label>
|
|
<section data-search-form class="phpdocumentor-search">
|
|
<label>
|
|
<span class="visually-hidden">Search for</span>
|
|
<svg class="phpdocumentor-search__icon" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
<circle cx="7.5" cy="7.5" r="6.5" stroke="currentColor" stroke-width="2"/>
|
|
<line x1="12.4892" y1="12.2727" x2="19.1559" y2="18.9393" stroke="currentColor" stroke-width="3"/>
|
|
</svg>
|
|
<input type="search" class="phpdocumentor-field phpdocumentor-search__field" placeholder="Loading .." disabled />
|
|
</label>
|
|
</section>
|
|
|
|
<nav class="phpdocumentor-topnav">
|
|
<ul class="phpdocumentor-topnav__menu">
|
|
</ul>
|
|
</nav>
|
|
</header>
|
|
|
|
<main class="phpdocumentor">
|
|
<div class="phpdocumentor-section">
|
|
<input class="phpdocumentor-sidebar__menu-button" type="checkbox" id="sidebar-button" name="sidebar-button" />
|
|
<label class="phpdocumentor-sidebar__menu-icon" for="sidebar-button">
|
|
Menu
|
|
</label>
|
|
<aside class="phpdocumentor-column -three phpdocumentor-sidebar">
|
|
<section class="phpdocumentor-sidebar__category -namespaces">
|
|
<h2 class="phpdocumentor-sidebar__category-header">Namespaces</h2>
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="namespaces/mainwp.html" class="">MainWP</a>
|
|
</h4>
|
|
<ul class="phpdocumentor-list">
|
|
<li>
|
|
<a href="namespaces/mainwp-child.html" class="">Child</a>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="namespaces/paragonie.html" class="">ParagonIE</a>
|
|
</h4>
|
|
<ul class="phpdocumentor-list">
|
|
<li>
|
|
<a href="namespaces/paragonie-constanttime.html" class="">ConstantTime</a>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="namespaces/phpseclib3.html" class="">phpseclib3</a>
|
|
</h4>
|
|
<ul class="phpdocumentor-list">
|
|
<li>
|
|
<a href="namespaces/phpseclib3-common.html" class="">Common</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-crypt.html" class="">Crypt</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-exception.html" class="">Exception</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-file.html" class="">File</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-math.html" class="">Math</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-net.html" class="">Net</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="namespaces/phpseclib3-system.html" class="">System</a>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
</section>
|
|
<section class="phpdocumentor-sidebar__category -packages">
|
|
<h2 class="phpdocumentor-sidebar__category-header">Packages</h2>
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="packages/MainWP.html" class="">MainWP</a>
|
|
</h4>
|
|
<ul class="phpdocumentor-list">
|
|
<li>
|
|
<a href="packages/MainWP-Child.html" class="">Child</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="packages/MainWP-ChildCreditsPlugin.html" class="">ChildCreditsPlugin</a>
|
|
|
|
</li>
|
|
<li>
|
|
<a href="packages/MainWP-Dashboard.html" class="">Dashboard</a>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="packages/MainWPChild.html" class="">MainWPChild</a>
|
|
</h4>
|
|
|
|
<h4 class="phpdocumentor-sidebar__root-namespace">
|
|
<a href="packages/ParagonIE.html" class="">ParagonIE</a>
|
|
</h4>
|
|
<ul class="phpdocumentor-list">
|
|
<li>
|
|
<a href="packages/ParagonIE-ConstantTime.html" class="">ConstantTime</a>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
</section>
|
|
|
|
<section class="phpdocumentor-sidebar__category -reports">
|
|
<h2 class="phpdocumentor-sidebar__category-header">Reports</h2>
|
|
<h3 class="phpdocumentor-sidebar__root-package"><a href="graphs/classes.html">Class Diagram</a></h3>
|
|
<h3 class="phpdocumentor-sidebar__root-package"><a href="reports/deprecated.html">Deprecated</a></h3>
|
|
<h3 class="phpdocumentor-sidebar__root-package"><a href="reports/errors.html">Errors</a></h3>
|
|
<h3 class="phpdocumentor-sidebar__root-package"><a href="reports/markers.html">Markers</a></h3>
|
|
</section>
|
|
|
|
<section class="phpdocumentor-sidebar__category -indices">
|
|
<h2 class="phpdocumentor-sidebar__category-header">Indices</h2>
|
|
<h3 class="phpdocumentor-sidebar__root-package"><a href="indices/files.html">Files</a></h3>
|
|
</section>
|
|
</aside>
|
|
|
|
<div class="phpdocumentor-column -nine phpdocumentor-content">
|
|
<section>
|
|
<ul class="phpdocumentor-breadcrumbs">
|
|
<li class="phpdocumentor-breadcrumb"><a href="namespaces/phpseclib3.html">phpseclib3</a></li>
|
|
<li class="phpdocumentor-breadcrumb"><a href="namespaces/phpseclib3-math.html">Math</a></li>
|
|
</ul>
|
|
|
|
<article class="phpdocumentor-element -class">
|
|
<h2 class="phpdocumentor-content__title">
|
|
BigInteger
|
|
|
|
|
|
<div class="phpdocumentor-element__package">
|
|
in package
|
|
<ul class="phpdocumentor-breadcrumbs">
|
|
<li class="phpdocumentor-breadcrumb"><a href="packages/MainWP.html">MainWP</a></li>
|
|
<li class="phpdocumentor-breadcrumb"><a href="packages/MainWP-Child.html">Child</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<span class="phpdocumentor-element__implements">
|
|
implements
|
|
<abbr title="\JsonSerializable">JsonSerializable</abbr> </span>
|
|
|
|
</h2>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
|
|
|
|
</div>
|
|
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">39</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.39" class="phpdocumentor-element-found-in__source" data-line="39" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Pure-PHP arbitrary precision integer arithmetic library. Supports base-2, base-10, base-16, and base-256
|
|
numbers.</p>
|
|
|
|
|
|
|
|
|
|
<h5 class="phpdocumentor-tag-list__heading" id="tags">
|
|
Tags
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#tags" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-tag-list">
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">author</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
|
|
<section class="phpdocumentor-description"><p>Jim Wigginton <a href="mailto:terrafrost@php.net">terrafrost@php.net</a></p>
|
|
</section>
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<h3 id="toc">
|
|
Table of Contents
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#toc" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h3>
|
|
|
|
|
|
|
|
<h4 id="toc-interfaces">
|
|
Interfaces
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#toc-interfaces" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<dl class="phpdocumentor-table-of-contents">
|
|
<dt class="phpdocumentor-table-of-contents__entry -interface"><abbr title="\JsonSerializable">JsonSerializable</abbr></dt> </dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h4 id="toc-properties">
|
|
Properties
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#toc-properties" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<dl class="phpdocumentor-table-of-contents">
|
|
<dt class="phpdocumentor-table-of-contents__entry -property -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#property_engines">$engines</a>
|
|
<span>
|
|
: array<int, string> </span>
|
|
</dt>
|
|
<dd>Selected Engines</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -property -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#property_hex">$hex</a>
|
|
<span>
|
|
: string </span>
|
|
</dt>
|
|
<dd>Mode independent value used for serialization.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -property -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#property_mainEngine">$mainEngine</a>
|
|
<span>
|
|
: <abbr title="class-string<\phpseclib3\Math\BigInteger\Engines\Engine>">Engine></abbr> </span>
|
|
</dt>
|
|
<dd>Main Engine</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -property -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#property_precision">$precision</a>
|
|
<span>
|
|
: int </span>
|
|
</dt>
|
|
<dd>Precision (used only for serialization)</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -property -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#property_value">$value</a>
|
|
<span>
|
|
: object </span>
|
|
</dt>
|
|
<dd>The actual BigInteger object</dd>
|
|
|
|
</dl>
|
|
|
|
<h4 id="toc-methods">
|
|
Methods
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#toc-methods" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<dl class="phpdocumentor-table-of-contents">
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___clone">__clone()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>Clone</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___construct">__construct()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>Converts base-2, base-10, base-16, and binary strings (base-256) to BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___debugInfo">__debugInfo()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>__debugInfo() magic method</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___sleep">__sleep()</a>
|
|
<span>
|
|
: array<string|int, mixed> </span>
|
|
</dt>
|
|
<dd>Serialize</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___toString">__toString()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>__toString() magic method</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method___wakeup">__wakeup()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>Serialize</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_abs">abs()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Absolute value.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_add">add()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Adds two BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_between">between()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Tests BigInteger to see if it is between two integers, inclusive</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_and">bitwise_and()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical And</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftRotate">bitwise_leftRotate()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Left Rotate</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftShift">bitwise_leftShift()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Left Shift</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_not">bitwise_not()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Not</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_or">bitwise_or()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Or</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightRotate">bitwise_rightRotate()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Right Rotate</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightShift">bitwise_rightShift()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Right Shift</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_split">bitwise_split()</a>
|
|
<span>
|
|
: array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>> </span>
|
|
</dt>
|
|
<dd>Bitwise Split</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_xor">bitwise_xor()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Logical Exclusive Or</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_compare">compare()</a>
|
|
<span>
|
|
: int </span>
|
|
</dt>
|
|
<dd>Compares two numbers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_createRecurringModuloFunction">createRecurringModuloFunction()</a>
|
|
<span>
|
|
: callable </span>
|
|
</dt>
|
|
<dd>Create Recurring Modulo Function</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_divide">divide()</a>
|
|
<span>
|
|
: array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>> </span>
|
|
</dt>
|
|
<dd>Divides two BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_equals">equals()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Tests the equality of two numbers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_extendedGCD">extendedGCD()</a>
|
|
<span>
|
|
: array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>> </span>
|
|
</dt>
|
|
<dd>Calculates modular inverses.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_gcd">gcd()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Calculates the greatest common divisor</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_getEngine">getEngine()</a>
|
|
<span>
|
|
: array<string|int, string> </span>
|
|
</dt>
|
|
<dd>Returns the engine type</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_getLength">getLength()</a>
|
|
<span>
|
|
: int </span>
|
|
</dt>
|
|
<dd>Return the size of a BigInteger in bits</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_getLengthInBytes">getLengthInBytes()</a>
|
|
<span>
|
|
: int </span>
|
|
</dt>
|
|
<dd>Return the size of a BigInteger in bytes</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_getPrecision">getPrecision()</a>
|
|
<span>
|
|
: int|bool </span>
|
|
</dt>
|
|
<dd>Get Precision</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_isNegative">isNegative()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Is Negative?</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_isOdd">isOdd()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Is Odd?</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_isPrime">isPrime()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Checks a numer to see if it's prime</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_jsonSerialize">jsonSerialize()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>JSON Serialize</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_max">max()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Return the maximum BigInteger between an arbitrary number of BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_min">min()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Return the minimum BigInteger between an arbitrary number of BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_minMaxBits">minMaxBits()</a>
|
|
<span>
|
|
: array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>> </span>
|
|
</dt>
|
|
<dd>Returns the smallest and largest n-bit number</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_modInverse">modInverse()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Calculates modular inverses.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_modPow">modPow()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Performs modular exponentiation.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_multiply">multiply()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Multiplies two BigIntegers</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_negate">negate()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Negate</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_pow">pow()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Performs exponentiation.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_powMod">powMod()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Performs modular exponentiation.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_random">random()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Generates a random number of a certain size</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_randomPrime">randomPrime()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Generates a random prime number of a certain size</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_randomRange">randomRange()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Generate a random number between a range</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_randomRangePrime">randomRangePrime()</a>
|
|
<span>
|
|
: false|<a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Generate a random prime number between a range</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_root">root()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Calculates the nth root of a biginteger.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_scan1divide">scan1divide()</a>
|
|
<span>
|
|
: int </span>
|
|
</dt>
|
|
<dd>Scan for 1 and right shift by that amount</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_setEngine">setEngine()</a>
|
|
<span>
|
|
: void </span>
|
|
</dt>
|
|
<dd>Sets engine type.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_setPrecision">setPrecision()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>Set Precision</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_subtract">subtract()</a>
|
|
<span>
|
|
: <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span>
|
|
</dt>
|
|
<dd>Subtracts two BigIntegers.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_testBit">testBit()</a>
|
|
<span>
|
|
: bool </span>
|
|
</dt>
|
|
<dd>Tests if a bit is set</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_toBits">toBits()</a>
|
|
<span>
|
|
: string </span>
|
|
</dt>
|
|
<dd>Converts a BigInteger to a bit string (eg. base-2).</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_toBytes">toBytes()</a>
|
|
<span>
|
|
: string </span>
|
|
</dt>
|
|
<dd>Converts a BigInteger to a byte string (eg. base-256).</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_toHex">toHex()</a>
|
|
<span>
|
|
: string </span>
|
|
</dt>
|
|
<dd>Converts a BigInteger to a hex string (eg. base-16).</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -public">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_toString">toString()</a>
|
|
<span>
|
|
: string </span>
|
|
</dt>
|
|
<dd>Converts a BigInteger to a base-10 number.</dd>
|
|
|
|
<dt class="phpdocumentor-table-of-contents__entry -method -private">
|
|
<a class="" href="classes/phpseclib3-Math-BigInteger.html#method_initialize_static_variables">initialize_static_variables()</a>
|
|
<span>
|
|
: mixed </span>
|
|
</dt>
|
|
<dd>Initialize static variables</dd>
|
|
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section class="phpdocumentor-properties">
|
|
<h3 class="phpdocumentor-elements__header" id="properties">
|
|
Properties
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#properties" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h3>
|
|
<article
|
|
class="
|
|
phpdocumentor-element
|
|
-property
|
|
-private
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="property_engines">
|
|
$engines
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_engines" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
<span class="phpdocumentor-element__modifiers">
|
|
</span>
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">53</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.53" class="phpdocumentor-element-found-in__source" data-line="53" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Selected Engines</p>
|
|
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__type">array<int, string></span>
|
|
<span class="phpdocumentor-signature__name">$engines</span>
|
|
</code>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="
|
|
phpdocumentor-element
|
|
-property
|
|
-private
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="property_hex">
|
|
$hex
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_hex" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
<span class="phpdocumentor-element__modifiers">
|
|
</span>
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">69</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.69" class="phpdocumentor-element-found-in__source" data-line="69" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Mode independent value used for serialization.</p>
|
|
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__type">string</span>
|
|
<span class="phpdocumentor-signature__name">$hex</span>
|
|
</code>
|
|
|
|
|
|
|
|
|
|
<h5 class="phpdocumentor-tag-list__heading" id="tags">
|
|
Tags
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_hex#tags" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-tag-list">
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">see</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
<span class="phpdocumentor-tag-link"><abbr title="\phpseclib3\Math\self::__sleep()">self::__sleep()</abbr></span>
|
|
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">see</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
<span class="phpdocumentor-tag-link"><abbr title="\phpseclib3\Math\self::__wakeup()">self::__wakeup()</abbr></span>
|
|
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="
|
|
phpdocumentor-element
|
|
-property
|
|
-private
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="property_mainEngine">
|
|
$mainEngine
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_mainEngine" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
<span class="phpdocumentor-element__modifiers">
|
|
</span>
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">46</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.46" class="phpdocumentor-element-found-in__source" data-line="46" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Main Engine</p>
|
|
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__type"><abbr title="class-string<\phpseclib3\Math\BigInteger\Engines\Engine>">Engine></abbr></span>
|
|
<span class="phpdocumentor-signature__name">$mainEngine</span>
|
|
</code>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="
|
|
phpdocumentor-element
|
|
-property
|
|
-private
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="property_precision">
|
|
$precision
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_precision" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
<span class="phpdocumentor-element__modifiers">
|
|
</span>
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">78</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.78" class="phpdocumentor-element-found-in__source" data-line="78" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Precision (used only for serialization)</p>
|
|
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__type">int</span>
|
|
<span class="phpdocumentor-signature__name">$precision</span>
|
|
</code>
|
|
|
|
|
|
|
|
|
|
<h5 class="phpdocumentor-tag-list__heading" id="tags">
|
|
Tags
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_precision#tags" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-tag-list">
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">see</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
<span class="phpdocumentor-tag-link"><abbr title="\phpseclib3\Math\self::__sleep()">self::__sleep()</abbr></span>
|
|
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">see</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
<span class="phpdocumentor-tag-link"><abbr title="\phpseclib3\Math\self::__wakeup()">self::__wakeup()</abbr></span>
|
|
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="
|
|
phpdocumentor-element
|
|
-property
|
|
-private
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="property_value">
|
|
$value
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#property_value" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
<span class="phpdocumentor-element__modifiers">
|
|
</span>
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">60</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.60" class="phpdocumentor-element-found-in__source" data-line="60" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">The actual BigInteger object</p>
|
|
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__type">object</span>
|
|
<span class="phpdocumentor-signature__name">$value</span>
|
|
</code>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
</section>
|
|
|
|
<section class="phpdocumentor-methods">
|
|
<h3 class="phpdocumentor-elements__header" id="methods">
|
|
Methods
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#methods" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h3>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___clone">
|
|
__clone()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___clone" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">800</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.800" class="phpdocumentor-element-found-in__source" data-line="800" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Clone</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__clone</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___construct">
|
|
__construct()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___construct" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">168</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.168" class="phpdocumentor-element-found-in__source" data-line="168" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Converts base-2, base-10, base-16, and binary strings (base-256) to BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__construct</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">string|int|<a href="classes/phpseclib3-Math-BigInteger-Engines-Engine.html"><abbr title="\phpseclib3\Math\BigInteger\Engines\Engine">Engine</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">0</span><span> ]</span></span><span class="phpdocumentor-signature__argument"><span>[</span><span>, </span><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$base</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">10</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>If the second parameter - $base - is negative, then it will be assumed that the number's are encoded using
|
|
two's compliment. The sole exception to this is -10, which is treated the same as 10 is.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">string|int|<a href="classes/phpseclib3-Math-BigInteger-Engines-Engine.html"><abbr title="\phpseclib3\Math\BigInteger\Engines\Engine">Engine</abbr></a></span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">0</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
<section class="phpdocumentor-description"><p>Base-10 number or base-$base number if $base set.</p>
|
|
</section>
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$base</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">10</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___debugInfo">
|
|
__debugInfo()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___debugInfo" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">205</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.205" class="phpdocumentor-element-found-in__source" data-line="205" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">__debugInfo() magic method</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__debugInfo</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Will be called, automatically, when print_r() or var_dump() are called</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___sleep">
|
|
__sleep()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___sleep" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">412</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.412" class="phpdocumentor-element-found-in__source" data-line="412" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Serialize</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__sleep</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, mixed></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Will be called, automatically, when serialize() is called on a BigInteger object.</p>
|
|
<p>__sleep() / __wakeup() have been around since PHP 4.0</p>
|
|
<p>\Serializable was introduced in PHP 5.1 and deprecated in PHP 8.1:
|
|
https://wiki.php.net/rfc/phase_out_serializable</p>
|
|
<p>__serialize() / __unserialize() were introduced in PHP 7.4:
|
|
https://wiki.php.net/rfc/custom_object_serialization</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, mixed></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___toString">
|
|
__toString()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___toString" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">195</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.195" class="phpdocumentor-element-found-in__source" data-line="195" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">__toString() magic method</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__toString</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method___wakeup">
|
|
__wakeup()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method___wakeup" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">427</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.427" class="phpdocumentor-element-found-in__source" data-line="427" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Serialize</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">__wakeup</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Will be called, automatically, when unserialize() is called on a BigInteger object.</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_abs">
|
|
abs()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_abs" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">367</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.367" class="phpdocumentor-element-found-in__source" data-line="367" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Absolute value.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">abs</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_add">
|
|
add()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_add" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">252</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.252" class="phpdocumentor-element-found-in__source" data-line="252" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Adds two BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">add</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$y</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$y</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_between">
|
|
between()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_between" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">792</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.792" class="phpdocumentor-element-found-in__source" data-line="792" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Tests BigInteger to see if it is between two integers, inclusive</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">between</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$min</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$max</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$min</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$max</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_and">
|
|
bitwise_and()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_and" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">530</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.530" class="phpdocumentor-element-found-in__source" data-line="530" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical And</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_and</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_leftRotate">
|
|
bitwise_leftRotate()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftRotate" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">591</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.591" class="phpdocumentor-element-found-in__source" data-line="591" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Left Rotate</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_leftRotate</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$shift</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Instead of the top x bits being dropped they're appended to the shifted bit string.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$shift</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_leftShift">
|
|
bitwise_leftShift()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftShift" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">578</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.578" class="phpdocumentor-element-found-in__source" data-line="578" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Left Shift</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_leftShift</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$shift</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Shifts BigInteger's by $shift bits, effectively multiplying by 2**$shift.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$shift</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_not">
|
|
bitwise_not()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_not" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">519</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.519" class="phpdocumentor-element-found-in__source" data-line="519" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Not</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_not</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_or">
|
|
bitwise_or()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_or" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">541</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.541" class="phpdocumentor-element-found-in__source" data-line="541" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Or</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_or</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_rightRotate">
|
|
bitwise_rightRotate()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightRotate" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">604</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.604" class="phpdocumentor-element-found-in__source" data-line="604" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Right Rotate</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_rightRotate</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$shift</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Instead of the bottom x bits being dropped they're prepended to the shifted bit string.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$shift</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_rightShift">
|
|
bitwise_rightShift()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightShift" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">565</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.565" class="phpdocumentor-element-found-in__source" data-line="565" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Right Shift</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_rightShift</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$shift</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Shifts BigInteger's by $shift bits, effectively dividing by 2**$shift.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$shift</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_split">
|
|
bitwise_split()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_split" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">886</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.886" class="phpdocumentor-element-found-in__source" data-line="886" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Bitwise Split</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_split</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$split</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Splits BigInteger's into chunks of $split bits</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$split</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_bitwise_xor">
|
|
bitwise_xor()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_xor" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">552</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.552" class="phpdocumentor-element-found-in__source" data-line="552" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Logical Exclusive Or</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">bitwise_xor</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_compare">
|
|
compare()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_compare" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">496</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.496" class="phpdocumentor-element-found-in__source" data-line="496" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Compares two numbers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">compare</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$y</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Although one might think !$x->compare($y) means $x != $y, it, in fact, means the opposite. The reason for this
|
|
is demonstrated thusly:</p>
|
|
<p>$x > $y: $x->compare($y) > 0
|
|
$x < $y: $x->compare($y) < 0
|
|
$x == $y: $x->compare($y) == 0</p>
|
|
<p>Note how the same comparison operator is used. If you want to test for equality, use $x->equals($y).</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$y</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
<h5 class="phpdocumentor-tag-list__heading" id="tags">
|
|
Tags
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_compare#tags" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-tag-list">
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">see</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
<span class="phpdocumentor-tag-link"><abbr title="\phpseclib3\Math\self::equals()">self::equals()</abbr></span>
|
|
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">int</span>
|
|
—
|
|
<section class="phpdocumentor-description"><p>in case < 0 if $this is less than $y; > 0 if $this is greater than $y, and 0 if they are equal.</p>
|
|
</section>
|
|
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_createRecurringModuloFunction">
|
|
createRecurringModuloFunction()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_createRecurringModuloFunction" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">870</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.870" class="phpdocumentor-element-found-in__source" data-line="870" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Create Recurring Modulo Function</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">createRecurringModuloFunction</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">callable</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Sometimes it may be desirable to do repeated modulos with the same number outside of
|
|
modular exponentiation</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">callable</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_divide">
|
|
divide()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_divide" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">304</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.304" class="phpdocumentor-element-found-in__source" data-line="304" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Divides two BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">divide</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$y</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Returns an array whose first element contains the quotient and whose second element contains the
|
|
"common residue". If the remainder would be positive, the "common residue" and the remainder are the
|
|
same. If the remainder would be negative, the "common residue" is equal to the sum of the remainder
|
|
and the divisor (basically, the "common residue" is the first positive modulo).</p>
|
|
<p>Here's an example:
|
|
<code class="prettyprint"></p>
|
|
<?php
|
|
$a = new \phpseclib3\Math\BigInteger('10');
|
|
$b = new \phpseclib3\Math\BigInteger('20');
|
|
|
|
list($quotient, $remainder) = $a->divide($b);
|
|
|
|
echo $quotient->toString(); // outputs 0
|
|
echo "\r\n";
|
|
echo $remainder->toString(); // outputs 10
|
|
?>
|
|
</code>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$y</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_equals">
|
|
equals()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_equals" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">509</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.509" class="phpdocumentor-element-found-in__source" data-line="509" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Tests the equality of two numbers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">equals</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>If you need to see if one number is greater than or less than another number, use BigInteger::compare()</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_extendedGCD">
|
|
extendedGCD()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_extendedGCD" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">334</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.334" class="phpdocumentor-element-found-in__source" data-line="334" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Calculates modular inverses.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">extendedGCD</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Say you have (30 mod 17 * x mod 17) mod 17 == 1. x can be found using modular inverses.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_gcd">
|
|
gcd()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_gcd" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">357</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.357" class="phpdocumentor-element-found-in__source" data-line="357" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Calculates the greatest common divisor</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">gcd</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Say you have 693 and 609. The GCD is 21.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_getEngine">
|
|
getEngine()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_getEngine" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">125</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.125" class="phpdocumentor-element-found-in__source" data-line="125" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Returns the engine type</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">getEngine</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, string></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, string></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_getLength">
|
|
getLength()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_getLength" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">635</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.635" class="phpdocumentor-element-found-in__source" data-line="635" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Return the size of a BigInteger in bits</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">getLength</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">int</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_getLengthInBytes">
|
|
getLengthInBytes()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_getLengthInBytes" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">645</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.645" class="phpdocumentor-element-found-in__source" data-line="645" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Return the size of a BigInteger in bytes</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">getLengthInBytes</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">int</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_getPrecision">
|
|
getPrecision()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_getPrecision" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">392</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.392" class="phpdocumentor-element-found-in__source" data-line="392" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Get Precision</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">getPrecision</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int|bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Returns the precision if it exists, false if it doesn't</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">int|bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_isNegative">
|
|
isNegative()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_isNegative" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">831</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.831" class="phpdocumentor-element-found-in__source" data-line="831" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Is Negative?</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">isNegative</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_isOdd">
|
|
isOdd()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_isOdd" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">810</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.810" class="phpdocumentor-element-found-in__source" data-line="810" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Is Odd?</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">isOdd</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_isPrime">
|
|
isPrime()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_isPrime" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">726</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.726" class="phpdocumentor-element-found-in__source" data-line="726" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Checks a numer to see if it's prime</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">isPrime</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">int|bool </span><span class="phpdocumentor-signature__argument__name">$t</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">false</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Assuming the $t parameter is not set, this function has an error rate of 2**-80. The main motivation for the
|
|
$t parameter is distributability. BigInteger::randomPrime() can be distributed across multiple pageloads
|
|
on a website instead of just one.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$t</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int|bool</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">false</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_jsonSerialize">
|
|
jsonSerialize()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_jsonSerialize" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">444</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.444" class="phpdocumentor-element-found-in__source" data-line="444" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">JSON Serialize</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">jsonSerialize</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Will be called, automatically, when json_encode() is called on a BigInteger object.</p>
|
|
</section>
|
|
|
|
|
|
|
|
<h5 class="phpdocumentor-tag-list__heading" id="tags">
|
|
Tags
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_jsonSerialize#tags" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-tag-list">
|
|
<dt class="phpdocumentor-tag-list__entry">
|
|
<span class="phpdocumentor-tag__name">@return</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-tag-list__definition">
|
|
|
|
<section class="phpdocumentor-description"><p>array{hex: string, precision?: int]</p>
|
|
</section>
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
<section class="phpdocumentor-attributes">
|
|
<h5 class="phpdocumentor-elements__header" id="attributes">
|
|
Attributes <a href="classes/phpseclib3-Math-BigInteger.html#method_jsonSerialize#attributes" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
#[<abbr title="\ReturnTypeWillChange">ReturnTypeWillChange</abbr>]
|
|
</dt>
|
|
</dl>
|
|
</section>
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_max">
|
|
max()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_max" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">776</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.776" class="phpdocumentor-element-found-in__source" data-line="776" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Return the maximum BigInteger between an arbitrary number of BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">max</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__variadic-operator">...</span><span class="phpdocumentor-signature__argument__name">$nums</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$nums</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_min">
|
|
min()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_min" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">761</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.761" class="phpdocumentor-element-found-in__source" data-line="761" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Return the minimum BigInteger between an arbitrary number of BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">min</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__variadic-operator">...</span><span class="phpdocumentor-signature__argument__name">$nums</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$nums</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_minMaxBits">
|
|
minMaxBits()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_minMaxBits" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">615</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.615" class="phpdocumentor-element-found-in__source" data-line="615" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Returns the smallest and largest n-bit number</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">minMaxBits</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$bits</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$bits</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">array<string|int, <a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a>></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_modInverse">
|
|
modInverse()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_modInverse" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">321</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.321" class="phpdocumentor-element-found-in__source" data-line="321" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Calculates modular inverses.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">modInverse</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Say you have (30 mod 17 * x mod 17) mod 17 == 1. x can be found using modular inverses.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_modPow">
|
|
modPow()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_modPow" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">473</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.473" class="phpdocumentor-element-found-in__source" data-line="473" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Performs modular exponentiation.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">modPow</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$e</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$e</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_multiply">
|
|
multiply()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_multiply" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">274</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.274" class="phpdocumentor-element-found-in__source" data-line="274" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Multiplies two BigIntegers</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">multiply</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_negate">
|
|
negate()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_negate" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">843</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.843" class="phpdocumentor-element-found-in__source" data-line="843" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Negate</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">negate</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Given $k, returns -$k</p>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_pow">
|
|
pow()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_pow" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">750</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.750" class="phpdocumentor-element-found-in__source" data-line="750" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Performs exponentiation.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">pow</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_powMod">
|
|
powMod()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_powMod" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">461</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.461" class="phpdocumentor-element-found-in__source" data-line="461" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Performs modular exponentiation.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">powMod</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$e</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$n</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$e</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_random">
|
|
random()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_random" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">658</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.658" class="phpdocumentor-element-found-in__source" data-line="658" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Generates a random number of a certain size</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">random</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$size</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Bit length is equal to $size</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$size</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_randomPrime">
|
|
randomPrime()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_randomPrime" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">674</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.674" class="phpdocumentor-element-found-in__source" data-line="674" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Generates a random prime number of a certain size</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">randomPrime</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$size</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Bit length is equal to $size</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$size</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_randomRange">
|
|
randomRange()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_randomRange" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">710</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.710" class="phpdocumentor-element-found-in__source" data-line="710" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Generate a random number between a range</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">randomRange</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$min</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$max</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Returns a random number between $min and $max where $min and $max
|
|
can be defined using one of the two methods:</p>
|
|
<p>BigInteger::randomRange($min, $max)
|
|
BigInteger::randomRange($max, $min)</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$min</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$max</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_randomRangePrime">
|
|
randomRangePrime()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_randomRangePrime" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">691</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.691" class="phpdocumentor-element-found-in__source" data-line="691" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Generate a random prime number between a range</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">randomRangePrime</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$min</span></span><span class="phpdocumentor-signature__argument"><span>, </span><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$max</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">false|<a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>If there's not a prime within the given range, false will be returned.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$min</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$max</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">false|<a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_root">
|
|
root()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_root" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">739</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.739" class="phpdocumentor-element-found-in__source" data-line="739" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Calculates the nth root of a biginteger.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">root</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$n</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">2</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Returns the nth root of a positive biginteger, where n defaults to 2</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$n</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">2</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
<section class="phpdocumentor-description"><p>optional</p>
|
|
</section>
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_scan1divide">
|
|
scan1divide()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_scan1divide" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">856</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.856" class="phpdocumentor-element-found-in__source" data-line="856" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Scan for 1 and right shift by that amount</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">scan1divide</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$r</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">int</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>ie. $s = gmp_scan1($n, 0) and $r = gmp_div_q($n, gmp_pow(gmp_init('2'), $s));</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$r</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">int</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_setEngine">
|
|
setEngine()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_setEngine" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">89</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.89" class="phpdocumentor-element-found-in__source" data-line="89" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Sets engine type.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">setEngine</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">string </span><span class="phpdocumentor-signature__argument__name">$main</span></span><span class="phpdocumentor-signature__argument"><span>[</span><span>, </span><span class="phpdocumentor-signature__argument__return-type">array<int, string> </span><span class="phpdocumentor-signature__argument__name">$modexps</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">['DefaultEngine']</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">void</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Throws an exception if the type is invalid</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$main</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">string</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$modexps</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">array<int, string></span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">['DefaultEngine']</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
<section class="phpdocumentor-description"><p>optional</p>
|
|
</section>
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_setPrecision">
|
|
setPrecision()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_setPrecision" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">380</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.380" class="phpdocumentor-element-found-in__source" data-line="380" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Set Precision</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">setPrecision</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$bits</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Some bitwise operations give different results depending on the precision being used. Examples include left
|
|
shift, not, and rotates.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$bits</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_subtract">
|
|
subtract()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_subtract" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">263</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.263" class="phpdocumentor-element-found-in__source" data-line="263" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Subtracts two BigIntegers.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">subtract</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a> </span><span class="phpdocumentor-signature__argument__name">$y</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$y</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type"><a href="classes/phpseclib3-Math-BigInteger.html"><abbr title="\phpseclib3\Math\BigInteger">BigInteger</abbr></a></span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_testBit">
|
|
testBit()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_testBit" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">821</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.821" class="phpdocumentor-element-found-in__source" data-line="821" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Tests if a bit is set</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">testBit</span><span>(</span><span class="phpdocumentor-signature__argument"><span class="phpdocumentor-signature__argument__return-type">int </span><span class="phpdocumentor-signature__argument__name">$x</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">bool</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$x</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">int</span>
|
|
</dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">bool</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_toBits">
|
|
toBits()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_toBits" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">241</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.241" class="phpdocumentor-element-found-in__source" data-line="241" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Converts a BigInteger to a bit string (eg. base-2).</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">toBits</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">bool </span><span class="phpdocumentor-signature__argument__name">$twos_compliment</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">false</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
<section class="phpdocumentor-description"><p>Negative numbers are saved as positive numbers, unless $twos_compliment is set to true, at which point, they're
|
|
saved as two's compliment.</p>
|
|
</section>
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$twos_compliment</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">bool</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">false</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">string</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_toBytes">
|
|
toBytes()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_toBytes" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">216</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.216" class="phpdocumentor-element-found-in__source" data-line="216" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Converts a BigInteger to a byte string (eg. base-256).</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">toBytes</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">bool </span><span class="phpdocumentor-signature__argument__name">$twos_compliment</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">false</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$twos_compliment</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">bool</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">false</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">string</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_toHex">
|
|
toHex()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_toHex" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">227</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.227" class="phpdocumentor-element-found-in__source" data-line="227" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Converts a BigInteger to a hex string (eg. base-16).</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">toHex</span><span>(</span><span class="phpdocumentor-signature__argument"><span>[</span><span class="phpdocumentor-signature__argument__return-type">bool </span><span class="phpdocumentor-signature__argument__name">$twos_compliment</span><span> = </span><span class="phpdocumentor-signature__argument__default-value">false</span><span> ]</span></span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
<h5 class="phpdocumentor-argument-list__heading">Parameters</h5>
|
|
<dl class="phpdocumentor-argument-list">
|
|
<dt class="phpdocumentor-argument-list__entry">
|
|
<span class="phpdocumentor-signature__argument__name">$twos_compliment</span>
|
|
: <span class="phpdocumentor-signature__argument__return-type">bool</span>
|
|
= <span class="phpdocumentor-signature__argument__default-value">false</span> </dt>
|
|
<dd class="phpdocumentor-argument-list__definition">
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">string</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-public
|
|
"
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_toString">
|
|
toString()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_toString" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">187</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.187" class="phpdocumentor-element-found-in__source" data-line="187" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Converts a BigInteger to a base-10 number.</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">public</span>
|
|
<span class="phpdocumentor-signature__name">toString</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">string</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<section>
|
|
<h5 class="phpdocumentor-return-value__heading">Return values</h5>
|
|
<span class="phpdocumentor-signature__response_type">string</span>
|
|
</section>
|
|
|
|
</article>
|
|
<article
|
|
class="phpdocumentor-element
|
|
-method
|
|
-private
|
|
-static "
|
|
>
|
|
<h4 class="phpdocumentor-element__name" id="method_initialize_static_variables">
|
|
initialize_static_variables()
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#method_initialize_static_variables" class="headerlink"><i class="fas fa-link"></i></a>
|
|
|
|
</h4>
|
|
<aside class="phpdocumentor-element-found-in">
|
|
<abbr class="phpdocumentor-element-found-in__file" title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php"><a href="files/libs-phpseclib-vendor-phpseclib-phpseclib-phpseclib-math-biginteger.html"><abbr title="libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php">BigInteger.php</abbr></a></abbr>
|
|
:
|
|
<span class="phpdocumentor-element-found-in__line">135</span>
|
|
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#source-view.135" class="phpdocumentor-element-found-in__source" data-line="135" data-modal="source-view" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt"></a>
|
|
</aside>
|
|
|
|
<p class="phpdocumentor-summary">Initialize static variables</p>
|
|
|
|
<code class="phpdocumentor-code phpdocumentor-signature ">
|
|
<span class="phpdocumentor-signature__visibility">private</span>
|
|
<span class="phpdocumentor-signature__static">static</span> <span class="phpdocumentor-signature__name">initialize_static_variables</span><span>(</span><span>)</span><span> : </span><span class="phpdocumentor-signature__response_type">mixed</span></code>
|
|
|
|
<div class="phpdocumentor-label-line">
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
</section>
|
|
|
|
<div class="phpdocumentor-modal" id="source-view">
|
|
<div class="phpdocumentor-modal-bg" data-exit-button></div>
|
|
<div class="phpdocumentor-modal-container">
|
|
<div class="phpdocumentor-modal-content">
|
|
<pre style="max-height: 500px; overflow-y: scroll" data-src="files/libs/phpseclib/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger.php.txt" class="language-php line-numbers linkable-line-numbers"></pre>
|
|
</div>
|
|
<button data-exit-button class="phpdocumentor-modal__close">×</button>
|
|
</div>
|
|
</div>
|
|
|
|
<script type="text/javascript">
|
|
(function () {
|
|
function loadExternalCodeSnippet(el, url, line) {
|
|
Array.prototype.slice.call(el.querySelectorAll('pre[data-src]')).forEach((pre) => {
|
|
const src = url || pre.getAttribute('data-src').replace(/\\/g, '/');
|
|
const language = 'php';
|
|
|
|
const code = document.createElement('code');
|
|
code.className = 'language-' + language;
|
|
pre.textContent = '';
|
|
pre.setAttribute('data-line', line)
|
|
code.textContent = 'Loading…';
|
|
pre.appendChild(code);
|
|
|
|
var xhr = new XMLHttpRequest();
|
|
|
|
xhr.open('GET', src, true);
|
|
|
|
xhr.onreadystatechange = function () {
|
|
if (xhr.readyState !== 4) {
|
|
return;
|
|
}
|
|
|
|
if (xhr.status < 400 && xhr.responseText) {
|
|
code.textContent = xhr.responseText;
|
|
Prism.highlightElement(code);
|
|
return;
|
|
}
|
|
|
|
if (xhr.status === 404) {
|
|
code.textContent = '✖ Error: File could not be found';
|
|
return;
|
|
}
|
|
|
|
if (xhr.status >= 400) {
|
|
code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
|
|
return;
|
|
}
|
|
|
|
code.textContent = '✖ Error: An unknown error occurred';
|
|
};
|
|
|
|
xhr.send(null);
|
|
});
|
|
}
|
|
|
|
const modalButtons = document.querySelectorAll("[data-modal]");
|
|
const openedAsLocalFile = window.location.protocol === 'file:';
|
|
if (modalButtons.length > 0 && openedAsLocalFile) {
|
|
console.warn(
|
|
'Viewing the source code is unavailable because you are opening this page from the file:// scheme; ' +
|
|
'browsers block XHR requests when a page is opened this way'
|
|
);
|
|
}
|
|
|
|
modalButtons.forEach(function (trigger) {
|
|
if (openedAsLocalFile) {
|
|
trigger.setAttribute("hidden", "hidden");
|
|
}
|
|
|
|
trigger.addEventListener("click", function (event) {
|
|
event.preventDefault();
|
|
const modal = document.getElementById(trigger.dataset.modal);
|
|
if (!modal) {
|
|
console.error(`Modal with id "${trigger.dataset.modal}" could not be found`);
|
|
return;
|
|
}
|
|
modal.classList.add("phpdocumentor-modal__open");
|
|
|
|
loadExternalCodeSnippet(modal, trigger.dataset.src || null, trigger.dataset.line)
|
|
const exits = modal.querySelectorAll("[data-exit-button]");
|
|
exits.forEach(function (exit) {
|
|
exit.addEventListener("click", function (event) {
|
|
event.preventDefault();
|
|
modal.classList.remove("phpdocumentor-modal__open");
|
|
});
|
|
});
|
|
});
|
|
});
|
|
})();
|
|
</script>
|
|
|
|
</article>
|
|
</section>
|
|
<section class="phpdocumentor-on-this-page__sidebar">
|
|
|
|
<section class="phpdocumentor-on-this-page__content">
|
|
<strong class="phpdocumentor-on-this-page__title">On this page</strong>
|
|
|
|
<ul class="phpdocumentor-list -clean">
|
|
<li class="phpdocumentor-on-this-page-section__title">Table Of Contents</li>
|
|
<li>
|
|
<ul class="phpdocumentor-list -clean">
|
|
<li><a href="classes/phpseclib3-Math-BigInteger.html#toc-properties">Properties</a></li>
|
|
<li><a href="classes/phpseclib3-Math-BigInteger.html#toc-methods">Methods</a></li>
|
|
</ul>
|
|
</li>
|
|
|
|
<li class="phpdocumentor-on-this-page-section__title">Properties</li>
|
|
<li>
|
|
<ul class="phpdocumentor-list -clean">
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#property_engines">$engines</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#property_hex">$hex</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#property_mainEngine">$mainEngine</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#property_precision">$precision</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#property_value">$value</a></li>
|
|
</ul>
|
|
</li>
|
|
|
|
<li class="phpdocumentor-on-this-page-section__title">Methods</li>
|
|
<li>
|
|
<ul class="phpdocumentor-list -clean">
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___clone">__clone()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___construct">__construct()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___debugInfo">__debugInfo()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___sleep">__sleep()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___toString">__toString()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method___wakeup">__wakeup()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_abs">abs()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_add">add()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_between">between()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_and">bitwise_and()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftRotate">bitwise_leftRotate()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_leftShift">bitwise_leftShift()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_not">bitwise_not()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_or">bitwise_or()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightRotate">bitwise_rightRotate()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_rightShift">bitwise_rightShift()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_split">bitwise_split()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_bitwise_xor">bitwise_xor()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_compare">compare()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_createRecurringModuloFunction">createRecurringModuloFunction()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_divide">divide()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_equals">equals()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_extendedGCD">extendedGCD()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_gcd">gcd()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_getEngine">getEngine()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_getLength">getLength()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_getLengthInBytes">getLengthInBytes()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_getPrecision">getPrecision()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_isNegative">isNegative()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_isOdd">isOdd()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_isPrime">isPrime()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_jsonSerialize">jsonSerialize()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_max">max()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_min">min()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_minMaxBits">minMaxBits()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_modInverse">modInverse()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_modPow">modPow()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_multiply">multiply()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_negate">negate()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_pow">pow()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_powMod">powMod()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_random">random()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_randomPrime">randomPrime()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_randomRange">randomRange()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_randomRangePrime">randomRangePrime()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_root">root()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_scan1divide">scan1divide()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_setEngine">setEngine()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_setPrecision">setPrecision()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_subtract">subtract()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_testBit">testBit()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_toBits">toBits()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_toBytes">toBytes()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_toHex">toHex()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_toString">toString()</a></li>
|
|
<li class=""><a href="classes/phpseclib3-Math-BigInteger.html#method_initialize_static_variables">initialize_static_variables()</a></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</section>
|
|
|
|
</section>
|
|
</div>
|
|
<section data-search-results class="phpdocumentor-search-results phpdocumentor-search-results--hidden">
|
|
<section class="phpdocumentor-search-results__dialog">
|
|
<header class="phpdocumentor-search-results__header">
|
|
<h2 class="phpdocumentor-search-results__title">Search results</h2>
|
|
<button class="phpdocumentor-search-results__close"><i class="fas fa-times"></i></button>
|
|
</header>
|
|
<section class="phpdocumentor-search-results__body">
|
|
<ul class="phpdocumentor-search-results__entries"></ul>
|
|
</section>
|
|
</section>
|
|
</section>
|
|
</div>
|
|
<a href="classes/phpseclib3-Math-BigInteger.html#top" class="phpdocumentor-back-to-top"><i class="fas fa-chevron-circle-up"></i></a>
|
|
|
|
</main>
|
|
|
|
<script>
|
|
cssVars({});
|
|
</script>
|
|
<script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/prism.min.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/autoloader/prism-autoloader.min.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-numbers/prism-line-numbers.min.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/prismjs@1.23.0/plugins/line-highlight/prism-line-highlight.min.js"></script>
|
|
</body>
|
|
</html>
|