python private method return value
<p>Im new to OOP and therefore I got one question. Say I got a simple class with one public and one private method. If I call the private method in the public method - should it return a value, or should that value be set as a field in my object eg:</p>

<pre><code>class Test:
    def __init__(self, path):
        self.path = path
    def __getNoOfFiles(self):
       'count files in self.path'
       return no_of_files
    def readDir(self)
        ...
        no_of_files = __getNoOfFiles()
</code></pre>

<p>or</p>

<pre><code>class Test:
    def __init__(self, path):
        self.path = path
        self.no_of_files = 0
    def __getNoOfFiles(self):
       self.no_of_files = 'count files in self.path'
    def readDir(self)
        __getNoOfFiles()
        no_of_files = self.no_of_files 
</code></pre>
