Like eight or so years ago, I sent a method I had to modify to the printer
(so I could study it on regular paper) and it came out on 14 pages.


On Thu, Jul 18, 2013 at 3:04 PM, Donal Lafferty
<donal.laffe...@citrix.com>wrote:

> > -----Original Message-----
> > From: Chip Childers [mailto:chip.child...@sungard.com]
> > Sent: 18 July 2013 9:43 PM
> > To: dev@cloudstack.apache.org
> > Subject: Re: [DISCUSS] coding convention for method - and class length
> >
> > On Thu, Jul 18, 2013 at 02:34:36PM -0600, Mike Tutkowski wrote:
> > > I'm not sure how I feel about an arbitrary number of lines per method
> > > (although 200 is obviously quite high and I would recommend
> > > modularizing such a method), but I'm not in favor of limiting the
> > > number of methods per class (especially not to just 10). Some types of
> > > objects simply need many discrete operations and 10 is too limiting.
> >
> > +1 to both thoughts.
> >
> > Smaller methods is good, but a specific number of lines as policy vs. a
> rule of
> > thumb are two different things.
> >
> > I completely agree with Daan's underlying concern though...  some of
> these
> > class files are horrible to try and comprehend.
> >
> > My favorite example:
> >
> > https://git-wip-
> >
> us.apache.org/repos/asf/cloudstack/?p=cloudstack.git;a=blob_plain;f=plugin
> > s/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceB
> > ase.java;hb=master
> >
> [Donal Lafferty]
> StyleCheck sets a default limit of 150 lines.
>
> Meanwhile, have you heard of the function 'best kick' in a certain
> company's soccer video game?  IIRC, it's several 1000 lines.
>
>


-- 
*Mike Tutkowski*
*Senior CloudStack Developer, SolidFire Inc.*
e: mike.tutkow...@solidfire.com
o: 303.746.7302
Advancing the way the world uses the
cloud<http://solidfire.com/solution/overview/?video=play>
*™*

Reply via email to