I think that's an interesting question, if you see it from this point of
view: "As soon as a Page object has been created, is it possible to get its
length without getting it? Page.get() is much slower than creating a Page
obiect, and there's a lot of attributes/methods that can be read
immediately, while other attributes need one Page.get(). Could be a
Page.getSize() a "first class method", that a user can read immediately?
Alex
2013/6/13 Merlijn van Deen <valhallasw(a)arctus.nl>
Hi Strainu,
On 13 June 2013 17:07, Strainu <strainu10(a)gmail.com> wrote:
Is there some reason why the Page class does not
have a getSize
function, except the fact that it's trivial to obtain it from .get() ?
I don't think there was a specific design decision not to implement it,
other than 'no-one ever needed it'. It's also not entirely clear what
'size' means in this context: the number of characters, the number of bytes
in a given encoding.
What is the use case where you think it would be useful?
Best,
Merlijn
_______________________________________________
Pywikipedia-l mailing list
Pywikipedia-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l