Skip to content
foomo golang integration
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

foomo - golang integration module

This foomo php module is designed to work with the gofoomo Go package .

Generate Go structs for php value objects

This is a snippet for a foomo module class:

// typically the make method of a foomo module class is a good place to generate code
public static function make($target, \Foomo\Modules\MakeResult $result)
    switch($target) {
        case 'all':
            // typically point to you go path 
            $goPath = self::getBaseDir('go');
            if(file_exists($goPath) && is_dir($goPath) && is_writable($goPath)) {
                // this call will generate gopath/src/
                    $package = '',
                $result->addEntry('wrote go value object sources');
            } else {
                $result->addEntry('can not write go value object sources');
            parent::make($target, $result);
You can’t perform that action at this time.