working with classes and packages, can I have one main folder?
Show older comments
Hello all,
I am refactoring a large codebase, and my approach to organise things is to make a class which describes the top level, lets call it " top_lvl_obj ". Alongside this class definition I have a folder I made into a Package by adding a + sign next to it, lets call it " +utilities ".
To showcase how the object works I have a demo.m script, and so my workspace looks like:
+utilities
@top_lvl_obj
demo.m
Ideally I want to move the +utilities folder into the @top_lvl_obj in order to have a single source code folder next to the demo.m script. This does not seem to be possible, and I'm not certain if there is a way around it.
I might be missing something, but I think the @class_name folder use is not very practical since it essentially works for only one m file, so a folder has one file in it, and each classdef needs another folder, which is a not very elegant way to organise files.
Thank you in advance,
Andreas.
Accepted Answer
More Answers (0)
Categories
Find more on Files and Folders in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!