src/Common/Console/Command/Make/Model.php
private function generateServiceDefinitions(\stdClass $oModel): array
    {
        return [
            //  Service definition
            implode("\n", [
                str_repeat(' ', $this->iServicesIndent) . '\'' . $oModel->service_name . '\' => function () {',
                str_repeat(' ', $this->iServicesIndent) . '    return new ' . $oModel->class_path . '();',
                str_repeat(' ', $this->iServicesIndent) . '},',
            ]),

            //  Resource definition
            implode("\n", [
                str_repeat(' ', $this->iServicesIndent) . '\'' . $oModel->service_name . '\' => function ($oObj) {',
                str_repeat(' ', $this->iServicesIndent) . '    return new ' . $oModel->resource_class_path . '($oObj);',
                str_repeat(' ', $this->iServicesIndent) . '},',
            ]),
        ];
    }
private function generateServiceDefinitions(\stdClass $oModel): array
    {
        return [
            //  Service definition
            implode("\n", [
                str_repeat(' ', $this->iServicesIndent) . '\'' . $oModel->service_name . '\' => function () {',
                str_repeat(' ', $this->iServicesIndent) . '    return new ' . $oModel->class_path . '();',
                str_repeat(' ', $this->iServicesIndent) . '},',
            ]),

            //  Resource definition
            implode("\n", [
                str_repeat(' ', $this->iServicesIndent) . '\'' . $oModel->service_name . '\' => function ($oObj) {',
                str_repeat(' ', $this->iServicesIndent) . '    return new ' . $oModel->resource_class_path . '($oObj);',
                str_repeat(' ', $this->iServicesIndent) . '},',
            ]),
        ];
    }
private function generateServiceDefinitions ( \ stdClass $ oModel ) : array { return [ //  Service definition implode ( "\n" , [ str_repeat ( ' ' , $ this -> iServicesIndent ) . '\'' . $ oModel -> service_name . '\' => function () {' , str_repeat ( ' ' , $ this -> iServicesIndent ) . '    return new ' . $ oModel -> class_path . '();' , str_repeat ( ' ' , $ this -> iServicesIndent ) . '},' , ] ) , //  Resource definition implode ( "\n" , [ str_repeat ( ' ' , $ this -> iServicesIndent ) . '\'' . $ oModel -> service_name . '\' => function ($oObj) {' , str_repeat ( ' ' , $ this -> iServicesIndent ) . '    return new ' . $ oModel -> resource_class_path . '($oObj);' , str_repeat ( ' ' , $ this -> iServicesIndent ) . '},' , ] ) , ] ; }
Genenrates the service file definitions for a model

@param \stdClass $oModel The model being created

@return string[]
Genenrates the service file definitions for a model