0 votes

From email:

Hi there,

This is in regards of Doctrine2/No Framework on OS X:

I am pretty sure at one point I got Skipper to write properties with protected access instead of private. Unfortunately I find no note how to do it, and now having it on a new computer and new install, I am back to private. Obviously I can do a search and replace, but…. was there a way to change it inside of a template. I just did a quick inspection of the framework files in the Show Package Contents but I didn’t find anything.

One issue that actually arises from private is that you use an embeddable in a base class then the database generator will throw an error about the property not existing in the derived classes.

Cheers!

Mario

in Solved by Skipper developer (141k points)
recategorized by

1 Answer

0 votes
Best answer

By default there is always private member access because it was recommended by Doctrine2 developers.

In latest version (3.2.5.1278) we prepared a way how to customize this value. It's in test mode so there is no way how to configure it from application or from configuration files and it's necessary to update export scripts.

In case more users will be interested in this option we will add it to configuration files.Here is how to configure it:

It's necessary to edit file Doctrine2.export.osc.

This file is located in InstallationDirector\Configurations\Frameworks directory on windows/linux or inside Skipper.app\Contents\Resources\Configurations\Frameworks on OS X

In function Doctrine2ExportPhpFile on line 126 there is following line:

var xslParams = new Array(); 
//xslParams["variable-access-rights"]  = "protected"; 
MLTools.XslTransformation(fileName, .....

Uncomment line `xslParams["variable-access-rights"] = "protected" and it's done

Note: Please keep in mind that this file will be updated after each application update. Currently it's not possible to store this settings in user-settings. As wrote before, this is experimental feature only

by Skipper developer (141k points)

Works like a charm! Thank you!

You're welcome ;-)

Works perfectly! Just be sure tor restart Skipper after changing the config file.

Thanks for feedback. Should be sufficient to close and re-open the project but app restart works always.