Login | Register
My pages Projects Community openCollabNet

Discussions > dev > Re: Code hacking style: method declaration and definition placement

Project highlights: :. Download .: :. Support .: :. FAQ .: :. Translations .: :. Donate .: :. Report Bug .:

tortoisesvn
Discussion topic

Back to topic list

Re: Code hacking style: method declaration and definition placement

Author steveking
Full name Stefan Küng
Date 2011-04-15 05:49:11 PDT
Message On 15.04.2011 09:31, Oto BREZINA wrote:
> Dear Stefan,
>
> I have to add some method into class. However I don't get way how to
> decide where to place it. Till now I use new to bottom, but now I need
> add public one.
>
> In our company we developed some rules to keep method organized, but
> they (expecialy my extensions :) ) are too tight to keep even in our
> small team. It seems you don't have any of those rules.
>
> Can you give me a hint how to decite where to place method declarationa
> and definition to keep your layout ?

Just put them where you think is appropriate. If there's a similar
method, add it below that one. If several methods are used for a
specific feature (e.g., all methods dealing with scrolling), try to keep
them grouped together.

But it's your decision where to place them.

Stefan

--
        ___
   oo // \\ "De Chelonian Mobile"
  (_,\/ \_/ \ TortoiseSVN
    \ \_/_\_/> The coolest Interface to (Sub)Version Control
    /_/ \_\ http://tortoisesvn.net

« Previous message in topic | 2 of 2 | Next message in topic »

Messages

Show all messages in topic

Code hacking style: method declaration and definition placement otik Oto BREZINA 2011-04-15 00:31:57 PDT
     Re: Code hacking style: method declaration and definition placement steveking Stefan Küng 2011-04-15 05:49:11 PDT
Messages per page: