Sure! A lot of what is there is effectively unused code in experimenting with running Python as a Java or Silverlight browser applet. You can ignore that. The important files to start with (probably in this order):
1. metalink.py - This defines the main data structures, based on the Metalink XML format. This also shows how metalink files are read and written. There is some support for similar formats in there too, RSS/Atom and Jigdo. There are clearly commented and can be ignored. This supports both Metalink v3 and Metalink v4, each has its object type and you'll see functions to convert between the two. 2. download.py - This does the heavy lifting and is the primary interface to the various user interfaces and for other developers. You can think of it as a generic Python download library that supports special formats like Metalink, RSS/Atom, and Jidgo. There are two main download engines in it, "NormalManager" which does a typical incremental file download from a single URL. "Segment_Manager" does a lot of fancy things, it opens multiple threads and uses the HTTP Range header to grab parts of a file from multiple URLs (if known). 3. checker.py - File that provides functions to check the URLs in a Metalink file. metalink.py actually parses the metalink files into objects, then we use these functions to help someone publishing metalink files validate their output. This is not required for metalink consumers that only want to download metalink files, for example GGet. 4. console.py - Command line user interface implementation that provides both checking and downloading functions. 5. guitk.py - Tk graphical user interface that provides checking functions only. See GGet for a GUI with download functions. Less interesting, but still used files: 6. GPG.py - GPG system call wrapper to verify signatures, if provided. This is a good exercise in seeing how to make system calls from Python and parsing the output. It is not critical to understanding what is going on as it is not used often. 7. proxy.py - Tries to automatically add proxy support if a proxy is configured on the system. Python doesn't have very good proxy support and this is a generic module to try to fix that, at least for our purposes. It is probably interesting if you want to understand more about how proxies work, but should otherwise be transparent in the rest of the code. That's all. Everything else is support files for converting the Python to .exe or packaging it for release. You can literally copy those seven files to your own directory and all the features should work. Neil On 4/5/2013 5:41 AM, Akshit Agarwal wrote: > Neil Sir or Anthony Sir can you please specify the files in > link http://sourceforge.net/apps/trac/metalinks/browser/checker from > which I should start understanding the code of Metalink Checker. > > -- > You received this message because you are subscribed to the Google > Groups "Metalink Discussion" group. > To unsubscribe from this group and stop receiving emails from it, send > an email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at > http://groups.google.com/group/metalink-discussion?hl=en. > For more options, visit https://groups.google.com/groups/opt_out. > > -- You received this message because you are subscribed to the Google Groups "Metalink Discussion" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/metalink-discussion?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
