PHP code example of survos / dataset-bundle

1. Go to this page and download the library: Download survos/dataset-bundle library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

survos / dataset-bundle example snippets


$paths->stageDir('dc/tb09jw350', Stage::Normalize); // .../norm

use Survos\DataBundle\Service\DataPaths;

final class SomeService
{
    public function __construct(
        private readonly DataPaths $paths,
    ) {
    }
}

$paths->datasetDir('dc/tb09jw350');
$paths->extractDir('dc/tb09jw350');
$paths->extractFile('dc/tb09jw350');
$paths->normalizeDir('dc/tb09jw350');
$paths->normalizeFile('dc/tb09jw350');
$paths->profileDir('dc/tb09jw350');
$paths->profileFile('dc/tb09jw350');
$paths->termsDir('dc/tb09jw350');

$paths->pixieTenantDb('larco');

$paths->runsDir;
$paths->cacheDir;

$paths->ensureRootDirs();

$paths->ensureDatasetDirs('dc/tb09jw350');

$paths->atomicWrite($path, $contents);