AutoCode and AutoSQL are twins. Although AutoCode comes earlier few day than AutoSQL, they present the same Perl spirit.
"If we're going to talk about good software design, we have to talk about Laziness, Impatience, and Hubris, the basis of good software design. - Larry Wall, Chapter 10, Programming Perl 3rd Ed"
The pattern of accessor name, or broadly speaking method, is fixed as
/^[_a-z][_a-z0-9]+$/
in the module AutoCode::AccessorMaker.
The why the pattern should be that are:
it should be a vilad Perl method name
the feedback from AutoSQL --
If the question of RFC 2 is not answered, then there is another problem. There will be a method called 'flatten_name' in AutoCode::Schema, simply performing
"\L$name"
AutoCode::AccessorMaker, as well as historic AutoCode::Initializer, should be so-called 'static class', in Java terms.
This instance of such makers does not mean anything. All methods inside should be used regardless of the state of any instance; they just act as normal methods
The configuration on such static class should be static too. For example, in AutoCode::AccessorMaker, you can let this maker marks itself as the meta-info of the generated classes.
$AutoCode::AccessorMaker::mark_maker=1;
Then all generated module, before the above value is changed again, will have a %META as a class variable to store which is the maker of it, etc.
When you invoke the method in this static class, there are 2 strategies.
AutoCode::AccessorMaker->make_scalar_accessor
AutoCode::AccessorMaker::make_scalar_accessor
I have some unspoken sense that the first one is better, though the second one looks more like a normal method out of the OOP concept.
This is a out-of-topic.
the RFC numbers could not be sequential according to the categories of topic. It is more of flexibility to stuff in any idea which sparks on your mind, and organize it afterward.
The idea comes randomly and preciously. Don't leak them due to your mismanagement. :-)
To install AutoCode::Root, copy and paste the appropriate command in to your terminal.
cpanm
cpanm AutoCode::Root
CPAN shell
perl -MCPAN -e shell install AutoCode::Root
For more information on module installation, please visit the detailed CPAN module installation guide.