23486 Posts in 18995 Topics by 2878 members
General questions about getting started with SilverStripe that don't fit in any of the categories above.
|Go to End|
6 January 2012 at 3:28pm
how does silverstripe find all the new files added? other frameworks and cms's generally need to be passed xml files containing the details of new files. I know it's not like a compiled language where new files are automatically included but I can't see how it does recognize all new files without adding includes everywhere. Anyone know this offhand?
7 January 2012 at 12:33am
Yep - this is the dev/build thing - it creates a manifest (list of files where the class mathes the filename) and then it auto loads those requried
13 January 2012 at 8:52am
thanks Swaiba for the quick reply, very much appreciated. It all makes a lot more sense now I searched for manifest.
For anyone else who comes across this I'll explain what I found, for each class ManifestBuilder.php stores in cache a file name manifestClassParse-ExamplePage_php-66d4f5ee00b281254d01a3dc361b71f4 where ExamplePage.php is a class I created. Inside is an array showing how this class is related to another class for example I have pasted Page.php manifest file below. While this doesn't need to be known for daily SS running I find it really interesting how they have built the foundations. Props to the development team
$classes = array (
'className' => 'Page',
'extends' => 'SiteTree',
'className' => 'Page_Controller',
'extends' => 'ContentController',
$interfaces = array (
|Go to Top|