I really suppose that it will be comforable api for using, but feel there are underwater rocks. 1) I have task to parsing a lot of websites 2) From all website I should get the same data types 3) I am able to design common interface as class, then implement this interface via a lot of classes, e.g. WebSite1 implements websiteInterface, WebSite2 implements websiteInterface and so on 4) Finnaly, i want to use WebSite1.addresses, and in this moment implementation of getter for field addresses make http request + parsing + formatting + return
Note 1: I don't wanna use WebSite1.get_addresses() because it seems to me, that user of WebSite API can think about addresses like about data, not some copmutions by method
Note 2: I think that it's can be ugly from design patterns
Can anyone give me direction for deciding my problem...
thank you P.S. I use python, not java how you can suppose cause syntax of my examples. But I use this syntax for clear explaining my problem..
Aucun commentaire:
Enregistrer un commentaire