Subversion Repositories oidplus

Rev

Rev 1439 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1439 Rev 1466
Line 1339... Line 1339...
1339
                return true;
1339
                return true;
1340
            }
1340
            }
1341
        }
1341
        }
1342
        return false;
1342
        return false;
1343
    }
1343
    }
-
 
1344
 
-
 
1345
    /**
-
 
1346
     * Return the size of a BigInteger in bits
-
 
1347
     *
-
 
1348
     * @return int
-
 
1349
     */
-
 
1350
    public function getLength()
-
 
1351
    {
-
 
1352
        $max = count($this->value) - 1;
-
 
1353
        return $max != -1 ?
-
 
1354
            $max * static::BASE + intval(ceil(log($this->value[$max] + 1, 2))) :
-
 
1355
            0;
-
 
1356
    }
1344
}
1357
}