Jolyon wrote:
Whilst I agree with the rest of your comments about keeping forms and
business objects separate - this one caught my attention:
This facility was afaik originally created to fix a
shortcoming in .NET which was the lack of separate resource
files to store form designs (i.e. no
This is a very interesting topic - I would love to hear others ideas of
organising source for big projects, and any other web references.
My quick thoughts:
Note as far as the Delphi compiler is concerned it is fine with units of
thousands of lines, its still a one pass compiler, and if the
Thanks everyone for the input.
I managed to refractor a unit with source code 1600 lines down to 677 lines by
splitting to multiple classes. ;-)
Regards
Have a nice day
Regards
Leigh
___
NZ Borland Developers Group - Delphi mailing list
Post:
Good afternoon,
I am facing a trouble. Some of the class I wrote reaches more than 1600 lines.
I don't like it. The methods in the class are ordinary range from one line to
200 lines. I really like each method sitting in their own unit. Just like abap
in sap. It is easy to maintain 200 lines
...@delphi.org.nz] On
Behalf Of Leigh Wanstead
Sent: Monday, 5 July 2010 15:50
To: NZ Borland Developers Group - Delphi List
Subject: [DUG] unit source code size
Good afternoon,
I am facing a trouble. Some of the class I wrote reaches more than 1600
lines. I don't like it. The methods
Can you refactor your code?
See if you can break your classes or methods into smaller segments.
Depending upon your class relationship, can you reduce it to one class per unit?
If you have such large methods (200 lines seems like is a lot!), you
can break them up into smaller methods.
If it
Developers Group - Delphi List
Subject: Re: [DUG] unit source code size
Can you refactor your code?
See if you can break your classes or methods into smaller segments.
Depending upon your class relationship, can you reduce it to one class per unit?
If you have such large methods (200 lines seems
...@delphi.org.nz] On
Behalf Of Colin Johnsun
Sent: Monday, 5 July 2010 4:39 p.m.
To: NZ Borland Developers Group - Delphi List
Subject: Re: [DUG] unit source code size
Can you refactor your code?
See if you can break your classes or methods into smaller segments.
Depending upon your class
: Re: [DUG] unit source code size
Hi Colin,
I am constantly refactoring code, but sometimes the form unit just grows
bigger and bigger.
Regards
Leigh
-Original Message-
From: delphi-boun...@delphi.org.nz [mailto:delphi-boun...@delphi.org.nz] On
Behalf Of Colin Johnsun
Sent: Monday, 5 July
Hi Leigh,
On 5 July 2010 14:54, Leigh Wanstead lei...@softtech.co.nz wrote:
Hi Colin,
I am constantly refactoring code, but sometimes the form unit just grows
bigger and bigger.
Regards
Leigh
-Original Message-
The amount of code shouldn't bother you. What matters is that the
...@delphi.org.nz [mailto:delphi-boun...@delphi.org.nz] On
Behalf Of Jolyon Smith
Sent: Monday, 5 July 2010 5:03 p.m.
To: 'NZ Borland Developers Group - Delphi List'
Subject: Re: [DUG] unit source code size
Form units should not usually have methods with 200+ lines.
Forms should have minimal processing, events
Developers Group - Delphi List
Subject: Re: [DUG] unit source code size
Hi Colin,
I am constantly refactoring code, but sometimes the form unit just grows
bigger and bigger.
Regards
Leigh
-Original Message-
From: delphi-boun...@delphi.org.nz [mailto:delphi-boun...@delphi.org.nz
12 matches
Mail list logo