<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>ActiveSpark</title>
	<atom:link href="http://activespark.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://activespark.wordpress.com</link>
	<description>python runserver</description>
	<lastBuildDate>Wed, 24 Mar 2010 07:18:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='activespark.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/554df7afea3018cc237493a2cb629592?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>ActiveSpark</title>
		<link>http://activespark.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://activespark.wordpress.com/osd.xml" title="ActiveSpark" />
	<atom:link rel='hub' href='http://activespark.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Blog moved to pixelsspace.com</title>
		<link>http://activespark.wordpress.com/2010/01/30/blog-moved-to-pixelsspace/</link>
		<comments>http://activespark.wordpress.com/2010/01/30/blog-moved-to-pixelsspace/#comments</comments>
		<pubDate>Sat, 30 Jan 2010 00:44:36 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[post]]></category>
		<category><![CDATA[activespark]]></category>
		<category><![CDATA[activespark.info]]></category>
		<category><![CDATA[blog]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=492</guid>
		<description><![CDATA[Dear Visitors, The Blog has been moved to http://pixelsspace.com/. I have started my own Blog You can find the latest posts, and updates on my blog at pixelsspace.com. Thank you Suhail Tagged: activespark, activespark.info, blog<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=492&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face="verdana"><br />
Dear Visitors, The Blog has been moved to <a href="http://pixelsspace.com/">http://pixelsspace.com/</a>. I have started my own Blog <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />    You can find the latest posts, and updates on my blog at pixelsspace.com.<br />
</font></p>
<p><font face="verdana"><br />
Thank you<br />
Suhail<br />
</font></p>
<br /> Tagged: <a href='http://activespark.wordpress.com/tag/activespark/'>activespark</a>, <a href='http://activespark.wordpress.com/tag/activespark-info/'>activespark.info</a>, <a href='http://activespark.wordpress.com/tag/blog/'>blog</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/492/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/492/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/492/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=492&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2010/01/30/blog-moved-to-pixelsspace/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>
	</item>
		<item>
		<title>Python &amp; The Editors</title>
		<link>http://activespark.wordpress.com/2009/12/31/python-editors/</link>
		<comments>http://activespark.wordpress.com/2009/12/31/python-editors/#comments</comments>
		<pubDate>Thu, 31 Dec 2009 13:28:56 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[editors]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[activestate]]></category>
		<category><![CDATA[geany]]></category>
		<category><![CDATA[gedit]]></category>
		<category><![CDATA[komodo]]></category>
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=457</guid>
		<description><![CDATA[To tell about python editor&#8217;s there are many editors available for python, like activetstate&#8217;s komodo, python wingware, Stani&#8217;s etc. The choice of text editor to choose depends upon you, the operating system you use, the number of features your require from your text editor, etc. Here I am writing my own list of text editors, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=457&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face='verdana'><br />
<a href="http://activespark.files.wordpress.com/2009/12/editor-3.png"><img src="http://activespark.files.wordpress.com/2009/12/editor-3.png?w=600" alt="" title="editor-3"   class="alignleft size-full wp-image-462" /></a>To tell about python editor&#8217;s there are many editors available for python, like activetstate&#8217;s komodo, python wingware, Stani&#8217;s etc. The choice of text editor to choose depends upon you, the operating system you use, the number of features your require from your text editor, etc. Here I am writing my own list of text editors, that i have used. Theres also this good little article i found on about.com on &#8220;Choosing a Text Editor for Python Programming&#8221; http://python.about.com/od/gettingstarted/ss/text_editors.htm.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://www.geany.org/Main/About"><img src="http://activespark.files.wordpress.com/2009/12/geany.png?w=600" alt="" title="geany"   class="alignleft size-full wp-image-463" /></a><strong><u><a href="http://www.geany.org/Main/HomePage">Geany</a></u></strong>: Geany is that little editor, i keep at hand for any purpose, whether i wanna write an article or do some coding stuff, i prefer to use geany most of the time, its simple and lightweight, to be honest, the main thing i started using geany is, it opens with all pages and tabs from where you had left, if you have shut down your computer and when you come back and start your computer, you start geany, and it will open up with all the tabs that you had left open to work upon. i couldn&#8217;t find this feature in any other editors i have used so far. And it also has lots of other features, to view the different features of Geany, you can visit this link <a href="http://www.geany.org/Main/About">Here</a>.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://www.vim.org/about.php"><img src="http://activespark.files.wordpress.com/2009/12/vim1.png?w=600" alt="" title="vim"   class="alignleft size-full wp-image-465" /></a><strong><u><a href="http://www.vim.org/">Vim</a></u></strong>: vim for sysadmins they call it as vi, this is also one powerful editor, its a unix editor, it also has this plugin feature, you can configure to act as a python editor, and being a unix editor, comparatively its the most light-weight and has a lot of features that can configured as required. And if you want to get a good hands on vim and want to have a good knowledge about the editor, i suggest you read swaroopch&#8217;s &#8220;A Byte of Vim&#8221;, you will learn about the different features of vim and how it can be used and also how you can configure vim to be the editor of your choice. And you can also visit this link http://0xbabaf000l.blogspot.com/ it has lot of comic strips about vim, gnu and other stuff.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://projects.gnome.org/gedit/"><img src="http://activespark.files.wordpress.com/2009/12/gedit.png?w=600" alt="" title="gedit"   class="alignleft size-full wp-image-466" /></a><strong><u><a href="http://projects.gnome.org/gedit/">gedit</a></u></strong>: its the is the official text editor of the GNOME desktop environment. sure it is again a light-weight editor but, i won&#8217;t call it powerful and neither it has that many features, all i would say its a simple little editor that can get your work done, it sure has the plugins feature, for a list of its features visit the Gedits official website page here: http://projects.gnome.org/gedit/index.html<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://www.activestate.com/"><img src="http://activespark.files.wordpress.com/2009/12/activestate-logo.gif?w=600" alt="" title="activestate-logo"   class="alignleft size-full wp-image-469" /></a><br />
</font><br />
<font face='verdana'><br />
<a href="http://www.activestate.com/komodo_edit/"><img src="http://activespark.files.wordpress.com/2009/12/komodo.jpg?w=600" alt="" title="komodo"   class="alignleft size-full wp-image-470" /></a><a href="http://www.activestate.com/komodo_edit/"><strong><u>ActiveState Komodo Edit</u></strong></a>: Now here we come to the hard core editor, Komodo Edit supports PHP, Python, Ruby, Perl and Tcl, plus JavaScript, CSS, HTML and template languages like RHTML, Template-Toolkit, HTML-Smarty and Django.  This is again one of my favorite editors after Geany, its not light-weight as the other editors i have mentioned till now, you can&#8217;t expect it to be a light-weight, as it has lots of features, Multi-language support, Project management, toolbox, Extensions, plugins, code snippets, html preview, etc.  read the complete list of features here: http://www.activestate.com/komodo_edit/features/<br />
And its available for linux as well as windows and Mac.<br />
</font></p>
<p><font face='verdana'><br />
These are some of the editors that i have used so far for coding in python, these editors are free, there are other editors too like <a href="http://sourceforge.net/projects/spe/">Stani&#8217;s python editor</a>, <a href="http://pydev.org/">pydev</a>, <a href="http://boa-constructor.sourceforge.net/">Boa constructor</a>, <a href="http://bluefish.openoffice.nl/">bluefish</a> (never tried those) but i will still stick to <a href="http://www.geany.org">Geany</a>, as i have got used to it, and it has that one feature that i always wanted, of opening up with all the tabs from where you had left.<br />
</font></p>
<br /> Tagged: activestate, editors, geany, gedit, komodo, Python, vim <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/457/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=457&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/12/31/python-editors/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/editor-3.png" medium="image">
			<media:title type="html">editor-3</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/geany.png" medium="image">
			<media:title type="html">geany</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/vim1.png" medium="image">
			<media:title type="html">vim</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/gedit.png" medium="image">
			<media:title type="html">gedit</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/activestate-logo.gif" medium="image">
			<media:title type="html">activestate-logo</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/komodo.jpg" medium="image">
			<media:title type="html">komodo</media:title>
		</media:content>
	</item>
		<item>
		<title>stepup2: Python</title>
		<link>http://activespark.wordpress.com/2009/12/29/stepup2-python/</link>
		<comments>http://activespark.wordpress.com/2009/12/29/stepup2-python/#comments</comments>
		<pubDate>Tue, 29 Dec 2009 12:11:24 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[jeremy jones]]></category>
		<category><![CDATA[noah gift]]></category>
		<category><![CDATA[python for linux]]></category>
		<category><![CDATA[python for unix]]></category>
		<category><![CDATA[sysadmins]]></category>
		<category><![CDATA[system administration]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=411</guid>
		<description><![CDATA[posting after a long time, its been over 2 months since the last post. can&#8217;t help it, that&#8217;s the life of a sysadmin. ok, moving on to this post, as i have decided that i would be writing on mostly python, as that has become my favourite programming language. now after a long break, continuing [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=411&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face='verdana'><br />
<a href="http://activespark.files.wordpress.com/2009/12/stepup2streets.jpg"><img src="http://activespark.files.wordpress.com/2009/12/stepup2streets.jpg?w=100&#038;h=100" alt="" title="stepup2streets" width="100" height="100" class="alignleft size-thumbnail wp-image-417" /></a> <a href="http://www.amazon.com/Python-Unix-Linux-System-Administration/dp/0596515820/ref=sr_1_1?ie=UTF8&amp;s=books&amp;qid=1262089591&amp;sr=1-1-spell"><img src="http://activespark.files.wordpress.com/2009/12/python-for-unix-linux.gif?w=600" alt="" title="python-for-unix-linux"   class="alignleft size-full wp-image-418" /></a>posting after a long time, its been over 2 months since the last post. can&#8217;t help it, that&#8217;s the life of a sysadmin. ok, moving on to this post, as i have decided that i would be writing on mostly python, as that has become my favourite programming language. now after a long break, continuing back on my learning python journey, I have picked up this Book: Python for Unix and Linux system administration By Noah Gift and Jeremy Jones. I have still not completed the book, just reached the 4th chapter, but I am seriously liking it, After recommending Magnus Lie Hetland&#8217;s &#8220;Beginning python from novice to professional&#8221;, this is one another book that i would recommend for beginners as well as for any person wanting to learn python, its very well and clearly explained, and the one good thing, i liked is, lot of practical examples.<br />
</font></p>
<p><font face='verdana'><br />
Please don&#8217;t be bored, To start with, Authors Acknowledgement, Yes!, I am mentioning this part, it might sound boring, why need to start with Acknowlegdement, If you look at Noah&#8217;s acknowledgement, its a very very long Thank&#8217;s giving list, But!, I liked it, that was something really humble, he has thanked each and every freind and mentor he has met, even his teachers at school, its really quite interesting.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://www.flickr.com/photos/activespark/4223156432/"><img src="http://activespark.files.wordpress.com/2009/12/green-tea.jpg?w=600" alt="" title="green-tea"   class="alignleft size-full wp-image-451" /></a>Moving onto the next best part Chapter 1, &#8220;Introduction&#8221;, the question, Why Python?, I clearly agree to what the Author&#8217;s have explained about why to use python. Some reasons from the book that i would mention, Yes, Python is easy to learn. If a language can’t help you become productive pretty quickly, the lure of that language is severely diminished. Why would you want to spend weeks or months studying a language before you are able to write a program that does something useful? This is especially the case for sysadmins. If you can’t learn a language quickly enough to start writing scripts with it almost immediately, you should strongly question whether you should be learning it. However, a language that is easy to learn but doesn’t allow you to do fairly complex tasks isn’t worth much either. So the second reason to consider Python to be an<br />
excellent programming language is that, while it lets you start simply, it also allows you to perform tasks that are as complex as you can imagine.<br />
</font></p>
<p><font face='verdana'><br />
In this introduction part they have also taken some little examples and compared doing the same task in python and then doing the same thing in Perl and Bash and the difference between them. And there&#8217;s this little article called &#8220;Motivation&#8221;, this is a really good little article for people who are new to programming and are learning programming for the first time.<br />
</font></p>
<p><font face='verdana'><br />
Then they move on to &#8220;The Basics&#8221;, here you will get to know about ipython, its features, benefits and how to use it, even i never knew there was something like ipython and really useful. along with ipython the chapter takes you further on functions in python and import statements in python and other basics.<br />
</font><br />
<span id="more-411"></span><br />
<font face='verdana'><br />
<a href="http://activespark.files.wordpress.com/2009/12/2-ipython.png"><img src="http://activespark.files.wordpress.com/2009/12/2-ipython.png?w=600" alt="" title="2-IPython"   class="alignleft size-full wp-image-437" /></a>Moving on to Chapter 2, It is all about Ipython, ipython is a python shell, and it has lot more features than the standard python shell, In this chapter, you will get to know, its features, how to install it, how to use it, how to use the import functions, configuring it, using the Magic functions of ipython.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 3, &#8220;Text&#8221;, yes, this chapter is about string and text processing, Python&#8217;s Built-ins and modules, Unicode srings, regular expressions, working with files, ElementTree.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 4, &#8220;Documentation and Reporting&#8221;, this chapter is about gathering, formatting and prcessing data. you&#8217;ll learn about Automated Information Gathering, sending and receiving emails, Information Formatting, generating graphs, PDFs and csv excel files.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 5, &#8220;Networking&#8221;, this chapter is about creating sockets, testing the connections, protocols: http, ftp, RPC, ssh, Pyro framework, Twisted the network framework, Scapy.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 6, &#8220;Data&#8221;, This chapter is about moving of data from one location to another, sysadmins do these sruff using tools like scp, cp, mv or rsync, in this chapter you will learn about doing these tasks by scripting in python and also doing some more useful stuff. working with paths, directories, files, comparing the data, archiving, compressing and restoring the data.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 7, &#8220;SNMP&#8221;, this chapter covers the aspects of SNMP: autodiscovery, polling/monitoring, writing agents, device control, and finally enterprise SNMP integration. all of these things are going to be done with Python.<br />
SNMP installation and configuration, IPython and Net-SNMP, Discovering a Data Center, Creating Hybrid SNMP Tools.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://activespark.files.wordpress.com/2009/12/apple-logo.png"><img src="http://activespark.files.wordpress.com/2009/12/apple-logo.png?w=600" alt="" title="Apple-logo"   class="alignleft size-full wp-image-448" /></a>Chapter 8, &#8220;OS Soup&#8221;, this chpater is about using python across different OS distributions, From Linux, to Solaris, to OS X, to FreeBSD, it needs to be in your toolbelt. here you&#8217;ll learn Cross-Platform Unix Programming in Python, Creating a Cross-Platform, Systems Management Tool, Creating a Cross-Platform Build Network, Amazon Web Services with Boto, Google App Engine.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 9, &#8220;Package Management&#8221;, this chapter is about packaging and managing Python code and your Python environment. Setuptools and Python Eggs, easy_install, Authenticating to a Password Protected Site, Using Configuration Files, Creating Eggs and lots more.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 10, &#8220;Processes and Concurrency&#8221;, this chapter is about processes, using the subprocess module, its features, threads, creating and managing threads, scheduling the process.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 11, &#8220;Building GUIs&#8221;, this chapter is about PyGTK, curses, and the Django web framework. Building a Simple PyGTK App, Building an Apache Log Viewer Using PyGTK, Building an Apache Log Viewer Using Curses. After the GUI part come the Web applications part, its taking your python applications to web, for me this was the part i needed, because as a sysadmin i nevert make or was never required to make GUI tools. using the Django framework.<br />
</font></p>
<p><font face='verdana'><br />
<a href="http://activespark.files.wordpress.com/2009/12/12-dell-servers.jpg"><img src="http://activespark.files.wordpress.com/2009/12/12-dell-servers.jpg?w=150&#038;h=93" alt="" title="12-dell-servers" width="150" height="93" class="alignleft size-thumbnail wp-image-442" /></a>Chapter 12, &#8220;Data Persistence&#8221;, this chapter is about storing the data for its later use, Simple Serialization, Pickle, Cpickle, shelve, YAML, ZODB, Relational Serialization, SQLAlchemy ORM.<br />
</font></p>
<p><font face='verdana'><br />
</font><br />
<font face='verdana'><br />
Chapter 13, &#8220;Command Line&#8221;, this chapter is on creating command line tools, Integrating Shell Commands into Python<br />
Command-Line Tools, Integrating Configuration Files.<br />
</font></p>
<p><font face='verdana'><br />
Chapter 14, &#8220;Pragmatic Examples&#8221;, In this final chapter you&#8217;ll learn, Managing DNS with Python, Using LDAP with OpenLDAP, Active Directory, and More with Python.<br />
</font></p>
<p><font face='verdana'><br />
This was just a little overview and my personal review about the book, as i liked it, and personally i would recommend this book to any guy wanting to learn programming, especially as the name of the book specifies its book for the sysadmins, yes, its one great book for the sysadmins. the explanations have been made very clear. If there are any corrections or suggestions or feedback, Please feel free to comment, Also if there are any books related to python, that you may have read, i would be happy if you could share your views with us. you can also mailme at: activespark.info{AT}gmail{DOT}com.<br />
</font></p>
<br /> Tagged: jeremy jones, noah gift, Python, python for linux, python for unix, sysadmins, system administration <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/411/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/411/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/411/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=411&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/12/29/stepup2-python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/stepup2streets.jpg?w=150" medium="image">
			<media:title type="html">stepup2streets</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/python-for-unix-linux.gif" medium="image">
			<media:title type="html">python-for-unix-linux</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/green-tea.jpg" medium="image">
			<media:title type="html">green-tea</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/2-ipython.png" medium="image">
			<media:title type="html">2-IPython</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/apple-logo.png" medium="image">
			<media:title type="html">Apple-logo</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/12-dell-servers.jpg?w=120" medium="image">
			<media:title type="html">12-dell-servers</media:title>
		</media:content>
	</item>
		<item>
		<title>Django and The MVC pattern in web development</title>
		<link>http://activespark.wordpress.com/2009/10/18/django-and-the-mvc-pattern-in-web-development/</link>
		<comments>http://activespark.wordpress.com/2009/10/18/django-and-the-mvc-pattern-in-web-development/#comments</comments>
		<pubDate>Sun, 18 Oct 2009 14:00:54 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[django]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[django advantages]]></category>
		<category><![CDATA[model view controller]]></category>
		<category><![CDATA[MVC]]></category>
		<category><![CDATA[python advantages]]></category>
		<category><![CDATA[web development]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=381</guid>
		<description><![CDATA[Django is a web framework built in python, it enables you to build clean, feature-rich application in less amount of time. Web development has made a lot of progress during the last few years. It began as a tedious task that involved CGI interfacing external programs with the web server. CGI applications used the standard [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=381&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><span style="font-family:verdana;"><br />
<a href="http://djangoproject.com"><img class="alignleft size-thumbnail wp-image-382" title="django_logo1" src="http://activespark.files.wordpress.com/2009/10/django_logo1.jpg?w=393&#038;h=88" alt="django_logo1" width="393" height="88" /></a><br />
</span></p>
<p><span style="font-family:verdana;"><br />
</span></p>
<p><span style="font-family:verdana;"><br />
Django is a web framework built in python, it enables you to build clean, feature-rich application in less amount of time.<br />
</span></p>
<p><span style="font-family:verdana;"><br />
Web development has made a lot of progress during the last few years. It began as a tedious task that involved CGI interfacing external programs with the web server. CGI applications used the standard I/O facilities available to the C programming language in order to get user input and produce the required page output. In addition to being difficult to work with, CGI required a seperate copy of the program to be launched for each requests , which quickly overloaded the servers.<br />
</span></p>
<p><span style="font-family:verdana;"><br />
Then, new scripting languages were introduced to the web development, and this inspired developers tocreate more efficient technologies. Languages such as Perl and PHP quickly made their way into the world of web development, and as a result common web tasks such as cooking handing, session management and text processing became easier. Although these scripting languages had the libraries, to deal with the day to day web tasks, they lacked unified frameworks, as libraries were fundamentally different in design, usage and conventions. Therefore, the need for cohesive frameworks arose.<br />
</span></p>
<p><span style="font-family:verdana;"><br />
Few Years Ago, The <strong>MVC (Model View Controller)</strong> was introduced to the world of web development for building of web based applications. This software engineering pattern seperates data(Model), user interface(View), and data handling logic(Controller), so that one can be changed without affecting the other. The Benefits are that designers can work on the interface without worrying about data storage and Management. And Developers can think and code on the logic of Data Handling without worrying about the presentation.<br />
</span></p>
<p><span style="font-family:verdana;"><img style="max-width:800px;" src="http://activespark.files.wordpress.com/2009/12/dexter-1.jpg?w=74&#038;h=78" alt="" width="74" height="78" />Now how does <a href="http://python.org">Python </a>come into play ? Although python is used for build wide variety of applications, it is also very suited for web applications. It has a clean and elegant syntax and is supported by large library of modules which covers everything , from multi-threading to the zipping of files. Python laguage&#8217;s Object Oriented model is very well suited for the MVC style of web development.<br />
</span></p>
<p><span style="font-family:verdana;"><br />
As you can see performance is a very big concern with many of the web projects and it will always be with any of the new coming web projects. And in such situations, Python&#8217;s runtime environment does a very good job. as it is known to be fats and stable. Python supports wide range of web servers which include famous names like Apache, nginx, IIS, lighttpd, etc. Python also supports a wide range of Database servers, whch also includes some famous names like <a href="http://mysql.com">MySQL</a>, <a href="//www.postgresql.org">PostGreSQL</a>, etc. And if you are using Django framework, you don&#8217;t need to deal with the databases directly, Django provides a unified layer of access to all database engines.<br />
</span></p>
<p><span style="font-family:verdana;"><br />
<strong><span style="text-decoration:underline;">Advantages of Python</span></strong> :-<br />
</span><br />
<span id="more-381"></span><br />
<span style="font-family:verdana;"> </span></p>
<p><span style="font-family:verdana;">1) Clean and elegant syntax.</span></p>
<p><span style="font-family:verdana;">2) Large standard library of modules that covers a wide range of tasks.</span></p>
<p><span style="font-family:verdana;">3) Extensive documentation.</span></p>
<p><span style="font-family:verdana;">4) Mature runtime environment.</span></p>
<p><span style="font-family:verdana;">5) Support for standard and proven technologies such as Linux, Apache, MySQL and also other famousweb servers and database servers.</span></p>
<p><span style="font-family:verdana;"><strong>Django</strong> ?</span></p>
<p><span style="font-family:verdana;">There are so many frameworks in python such as <a href="http://cherrypy.org">cherrypy</a>, <a href="http://webpy.org">web.py</a>, <a href="http://object-craft.com.au/projects/albatross">Albatross</a>, <a href="http://quixote.ca">Quixote</a>, <a href="http://spyce.sf.net">Spyce</a>, <a href="http://webwareforpython.org">Webware</a>, <a href="http://pylonshq.com">pylons</a>, <a href="http://grok.zope.org/">grok</a>, <a href="http://zope.org">zope</a>, <a href="http://turbogears.com/">turbogears</a>, so, what sets <a href="http://www.djangoproject.com/">Django</a> apart from these ?</span></p>
<p><span style="font-family:verdana;">Tight integration between components:- Django provides a set of tightly integrated components; all of these components have been developed by the Django team themselves. Django&#8217;s components were designed for integration, reusability and speed from the start.</span></p>
<p><span style="font-family:verdana;">Object-Relational Mapper:- Django&#8217;s database component, the Object-Relational Mapper (ORM), provides a bridge between the data model and the database engine. It supports a large set of database systems, and switching from one engine to another is a matter of changing a configuration file. This gives the developer great flexibility if a decision is made to change from one database engine to another.</span></p>
<p><span style="font-family:verdana;">Clean URL Design:- The URL system in Django is very flexible and powerful; it lets you define patterns for the URLs in your application, and define Python functions to handle each pattern. This enables developers to create URLs that are both user and search engine friendly.</span></p>
<p><span style="font-family:verdana;">Automatic Administration Interface:- Django comes with an administration interface that is ready to be used. This interface makes the management of your application&#8217;s data a breeze. It is also highly flexible and customizable.</span></p>
<p><span style="font-family:verdana;">Advanced Development Environment:- Django provides a very nice development environment. It comes with a lightweight web server for development and testing. When the debugging mode is enabled, Django provides very thorough and detailed error messages with a lot of debugging information. All of this makes isolating and fixing bugs very easy.</span></p>
<p><span style="font-family:verdana;">Multi-Lingual Support:- Django supports multi-lingual websites through its built-in internationalization system. This can be very valuable for those working on websites with more than one language. The system makes translating the interface a very simple task.</span></p>
<p><span style="font-family:verdana;"><span style="font-family:verdana;"><br />
</span></span></p>
<p><span style="font-family:verdana;"><span style="font-family:verdana;"><br />
<a href="http://code.djangoproject.com/wiki/SprintDCAugust2008"><img class="alignleft size-thumbnail wp-image-384" title="GR_Logo_w_Tag" src="http://activespark.files.wordpress.com/2009/10/gr_logo_w_tag.gif?w=250&#038;h=76" alt="GR_Logo_w_Tag" width="250" height="76" /></a><br />
</span></span></p>
<div class="zemanta-pixie"><img class="zemanta-pixie-img" src="http://img.zemanta.com/pixy.gif?x-id=48180793-2da0-8e1d-9fa0-c8128bc5a06c" alt="" /></div>
<br /> Tagged: django, django advantages, model view controller, MVC, Python, python advantages, web development <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/381/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/381/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/381/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=381&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/18/django-and-the-mvc-pattern-in-web-development/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/10/django_logo1.jpg?w=150" medium="image">
			<media:title type="html">django_logo1</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/12/dexter-1.jpg" medium="image" />

		<media:content url="http://activespark.files.wordpress.com/2009/10/gr_logo_w_tag.gif?w=150" medium="image">
			<media:title type="html">GR_Logo_w_Tag</media:title>
		</media:content>

		<media:content url="http://img.zemanta.com/pixy.gif?x-id=48180793-2da0-8e1d-9fa0-c8128bc5a06c" medium="image" />
	</item>
		<item>
		<title>Apache: mod_python</title>
		<link>http://activespark.wordpress.com/2009/10/18/apache-mod_python/</link>
		<comments>http://activespark.wordpress.com/2009/10/18/apache-mod_python/#comments</comments>
		<pubDate>Sun, 18 Oct 2009 07:10:32 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[apache]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[apache module]]></category>
		<category><![CDATA[mod_python]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=375</guid>
		<description><![CDATA[One of the most interesting ways to use python is the Apache&#8217;s mod_python module. The mod_python module actually embeds a fully functional python intrepreter inside the apache web server. This is most frequently used as powerful means to generate dynamic web pages. The most common method of generating dynamic web pages is the CGI script. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=375&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face="verdana"><br />
<a href="http://www.apache.org"><img src="http://activespark.files.wordpress.com/2009/10/apache_logo.jpg?w=150&#038;h=112" alt="apache_logo" title="apache_logo" width="150" height="112" class="alignleft size-thumbnail wp-image-376" /></a></p>
<p><font face="verdana"><br />
</font></p>
<p><font face="verdana"><br />
One of the most interesting ways to use python is the Apache&#8217;s mod_python module. The mod_python module actually embeds a fully functional python intrepreter inside the apache web server.<br />
This is most frequently used as powerful means to generate dynamic web pages.<br />
</font></p>
<p><font face="verdana"><br />
The most common method of generating dynamic web pages is the CGI script. A CGI page is invoked each time a given page is requested. It reads the request, generates a reply and then terminates. This mimics the operation of HTTP, which at its core, works with a single request at a time. The next time a request is received, the CGI script is again invoked from scratch. This design enables the CGI script to be both language and server neutral. indeed all popular web servers and programming languages support them.<br />
</font></p>
<p><font face="verdana"><br />
However this compatibility comes at a price &amp; performance, Starting up a CGI script is slow. There&#8217;s operating system overhead involved while creating a new process. There&#8217;s overhead from the python interpreter when initializing and loading the script. CGI script that connect to databases hit especially hard, since they must establish new database connection each time a page is displayed. For these reasons CGI scripts are not suitable for high traffic sites.<br />
</font></p>
<p><font face="verdana"><br />
<a href="http://modpython.org/"><img src="http://activespark.files.wordpress.com/2009/10/mod_python.gif?w=150&#038;h=91" alt="mod_python" title="mod_python" width="150" height="91" class="alignleft size-thumbnail wp-image-377" /></a><br />
</font><br />
<font face="verdana"><br />
The <a href="http://modpython.org/"><strong>mod_python</strong></a> module is one answer to these problems. It actually embeds a full python interpreter inside the apache web server. your scripts are loaded only once per server process and only initialized then. Database connections can be established at the time of initialization and can be kept open throughout the life of web server process. whenever a page needs to be generated, a particular function is called, all data about the request is passed to it. This function has access to the environment created at the initialization time. so, for instance it can reuse the existing database connection.<br />
</font><br />
<font face="verdana"><br />
while this scheme forces the use of apache web server, its advantage often outweigh its disadvantages, <span id="more-375"></span>especially when designing a complete web application from the ground up. Python can alternative to special purpose web languages like PHP.<br />
</font><br />
<font face="verdana"><br />
The <a href="http://modpython.org"><strong>mod_python</strong></a> can do more than just serving up the web pages. It can also interact with the apache system in various different ways. For example apache provides various authentication handlers that let you authenticate users against a text file or <a href="http://tldp.org/HOWTO/LDAP-HOWTO/whatisldap.html">LDAP</a> database that contains usernames and passwords. You can write your own authentication handler in mod_python and use the handler anywhere in apache &#8211; even if the pages being used aren&#8217;t generated by Python code.<br />
</font></p>
<br /> Tagged: apache, apache module, mod_python, Python <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/375/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/375/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/375/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=375&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/18/apache-mod_python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/10/apache_logo.jpg?w=150" medium="image">
			<media:title type="html">apache_logo</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/10/mod_python.gif?w=150" medium="image">
			<media:title type="html">mod_python</media:title>
		</media:content>
	</item>
		<item>
		<title>python script: to change all the files extensions in a Directory</title>
		<link>http://activespark.wordpress.com/2009/10/15/python-script-to-change-all-the-files-extensions-in-a-directory/</link>
		<comments>http://activespark.wordpress.com/2009/10/15/python-script-to-change-all-the-files-extensions-in-a-directory/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 12:55:31 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[change all the files extensions in a Directory]]></category>
		<category><![CDATA[scripts]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=370</guid>
		<description><![CDATA[a python script to change file extensions of all the files in a directory: _____________________________________________________________________________________________ #!/usr/bin/env python import os import string my_directory=&#8217;/home/ross&#8217; for object in os.listdir(my_directory): &#160; &#160; &#160; if os.path.isfile(os.path.join(my_directory, object)): &#160; &#160; &#160; &#160; &#160; &#160; &#160; req_file=object &#160; &#160; &#160; &#160; &#160; &#160; &#160; if &#8216;.py&#8217; in req_file: &#160; &#160; &#160; &#160; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=370&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face='verdana'><br />
a python script to change file extensions of all the files in a directory:<br />
</font></p>
<p><font face='verdana'><br />
_____________________________________________________________________________________________<br />
</font><br />
<font face='verdana'><br />
#!/usr/bin/env python<br />
import os<br />
import string</p>
<p>my_directory=&#8217;/home/ross&#8217;</p>
<p>for object in os.listdir(my_directory):<br />
	&nbsp; &nbsp; &nbsp; if os.path.isfile(os.path.join(my_directory, object)):<br />
		&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; req_file=object<br />
		&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if &#8216;.py&#8217; in req_file:<br />
			&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ren_file=req_file.replace(&#8216;.mp3&#8242;, &#8216;.mp4&#8242;)<br />
			&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; old_file=os.path.join(my_directory, req_file)<br />
			&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; new_file=os.path.join(my_directory, ren_file)<br />
			&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; os.rename(old_file, new_file)<br />
</font><br />
<font face='verdana'><br />
_____________________________________________________________________________________________<br />
</font></p>
<p><font face='verdana'><br />
(Note:- Please take care of indentaion whenever writing a python script, The script posted above, may not be properly indented)<br />
</font></p>
<br /> Tagged: change all the files extensions in a Directory, Python, scripts <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/370/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/370/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/370/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=370&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/15/python-script-to-change-all-the-files-extensions-in-a-directory/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>
	</item>
		<item>
		<title>python script: to count the no. of lines in a file</title>
		<link>http://activespark.wordpress.com/2009/10/15/python-script-to-count-the-no-of-lines-in-a-file/</link>
		<comments>http://activespark.wordpress.com/2009/10/15/python-script-to-count-the-no-of-lines-in-a-file/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 12:38:48 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[count lines]]></category>
		<category><![CDATA[scripts]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=367</guid>
		<description><![CDATA[a simple script to count the no. of lines in a file:- ____________________________________________________________________________________________ #!/usr/bin/env python read_file=open(&#8216;/testfile.txt&#8217;, &#8216;rb&#8217;) count_file=len(read_file.readlines()) print count_file ____________________________________________________________________________________________ (Note:- Please take care of indentaion whenever writing a python script, The script posted above, may not be properly indented) Tagged: count lines, Python, scripts<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=367&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face='verdana'><br />
a simple script to count the no. of lines in a file:-<br />
</font><br />
<font face='verdana'><br />
____________________________________________________________________________________________<br />
</font><br />
<font face='verdana'><br />
#!/usr/bin/env python</p>
<p>read_file=open(&#8216;/testfile.txt&#8217;, &#8216;rb&#8217;)</p>
<p>count_file=len(read_file.readlines())</p>
<p>print count_file<br />
</font><br />
<font face='verdana'><br />
____________________________________________________________________________________________<br />
</font><br />
<font face='verdana'><br />
(Note:- Please take care of indentaion whenever writing a python script, The script posted above, may not be properly indented)<br />
</font></p>
<br /> Tagged: count lines, Python, scripts <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/367/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=367&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/15/python-script-to-count-the-no-of-lines-in-a-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>
	</item>
		<item>
		<title>python script: copy contents and replace a word</title>
		<link>http://activespark.wordpress.com/2009/10/15/python-script-copy-contents-and-replace-a-word/</link>
		<comments>http://activespark.wordpress.com/2009/10/15/python-script-copy-contents-and-replace-a-word/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 10:39:34 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[.py]]></category>
		<category><![CDATA[copy contents]]></category>
		<category><![CDATA[script]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=360</guid>
		<description><![CDATA[a script that will copy the contents from one file to another and also replace the requested word with the other one. _________________________________________________________________________________________________ #!/usr/bin/env python the_word=raw_input(&#8216;enter the word to replace &#8211;&#62; &#8216;) replace_word=raw_input(&#8216;enter the word to replace with &#8211;&#62; &#8216;) to_file=open(&#8216;/testfile.txt2&#8242;, &#8216;a&#8217;) try: &#160; &#160; &#160; read_file=open(&#8216;/testfile.txt&#8217;) &#160; &#160; &#160; for searches in read_file: &#160; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=360&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><font face='verdana'><br />
a script  that will copy the contents from one file to another and also replace the requested word with the other one.<br />
</font><br />
<font face='verdana'><br />
_________________________________________________________________________________________________<br />
</font><br />
<font face='verdana'><br />
#!/usr/bin/env python</p>
<p>the_word=raw_input(&#8216;enter the word to replace &#8211;&gt; &#8216;)<br />
replace_word=raw_input(&#8216;enter the word to replace with &#8211;&gt; &#8216;)</p>
<p>to_file=open(&#8216;/testfile.txt2&#8242;, &#8216;a&#8217;)</p>
<p>try:<br />
&nbsp; &nbsp; &nbsp; read_file=open(&#8216;/testfile.txt&#8217;)</p>
<p>&nbsp; &nbsp; &nbsp; for searches in read_file:<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; searches=searches.replace(the_word, replace_word)</p>
<p>&nbsp; &nbsp; &nbsp; to_file.write(searches)<br />
finally:<br />
&nbsp; &nbsp; &nbsp; to_file.close()<br />
</font><br />
<font face='verdana'><br />
_________________________________________________________________________________________________<br />
</font></p>
<p>(Note:- Please take care of indentaion whenever writing a python script, The script posted above, may not be properly indented)</p>
<br /> Tagged: .py, copy contents, Python, script <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/360/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=360&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/15/python-script-copy-contents-and-replace-a-word/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>
	</item>
		<item>
		<title>python script: to copy from one file to another</title>
		<link>http://activespark.wordpress.com/2009/10/15/python-script-to-copy-from-one-file-to-another/</link>
		<comments>http://activespark.wordpress.com/2009/10/15/python-script-to-copy-from-one-file-to-another/#comments</comments>
		<pubDate>Thu, 15 Oct 2009 09:06:00 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[.py]]></category>
		<category><![CDATA[copy one file to another]]></category>
		<category><![CDATA[scripts]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=341</guid>
		<description><![CDATA[A simple python script to copy a content of one file to another. ________________________________________________________________________________________________________ #!/usr/bin/env python to_readfile=open(&#8216;/testfile.txt&#8217;, &#8216;r&#8217;) try: &#160; &#160; &#160; reading_file=to_readfile.read() &#160; &#160; &#160; writefile=open(&#8216;/testfile2.txt&#8217;, &#8216;w&#8217;) &#160; &#160; &#160; try: &#160; &#160;&#160; &#160; &#160; &#160; writefile.write(reading_file) &#160; &#160; &#160; finally: &#160; &#160;&#160; &#160; &#160; &#160; writefile.close() finally: &#160; &#160; &#160; to_readfile.close() ________________________________________________________________________________________________________ (Note:- [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=341&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><span style="font-family:verdana;"><br />
A simple python script to copy a content of one file to another.<br />
</span><br />
<span style="font-family:verdana;"><br />
________________________________________________________________________________________________________<br />
</span><br />
<span style="font-family:verdana;"><br />
#!/usr/bin/env python</span></p>
<p><span style="font-family:verdana;">to_readfile=open(&#8216;/testfile.txt&#8217;, &#8216;r&#8217;)<br />
try:<br />
&nbsp; &nbsp; &nbsp; reading_file=to_readfile.read()</span></p>
<p><span style="font-family:verdana;"> &nbsp; &nbsp; &nbsp; writefile=open(&#8216;/testfile2.txt&#8217;, &#8216;w&#8217;)<br />
&nbsp; &nbsp; &nbsp; try:<br />
&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; writefile.write(reading_file)<br />
&nbsp; &nbsp; &nbsp; finally:<br />
&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; writefile.close()</span></p>
<p><span style="font-family:verdana;">finally:<br />
&nbsp; &nbsp; &nbsp; to_readfile.close()<br />
</span><br />
<span style="font-family:verdana;"><br />
</span><br />
<span style="font-family:verdana;"><br />
________________________________________________________________________________________________________<br />
</span></p>
<p><span style="font-family:verdana;"><br />
(Note:- Please take care of indentaion whenever writing a python script, The script posted above, may not be properly indented)<br />
</span></p>
<br /> Tagged: .py, copy one file to another, Python, scripts <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/341/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/341/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/341/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=341&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/15/python-script-to-copy-from-one-file-to-another/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>
	</item>
		<item>
		<title>Tips for Object Oriented Design</title>
		<link>http://activespark.wordpress.com/2009/10/01/tips-for-object-orientated-design/</link>
		<comments>http://activespark.wordpress.com/2009/10/01/tips-for-object-orientated-design/#comments</comments>
		<pubDate>Thu, 01 Oct 2009 10:33:18 +0000</pubDate>
		<dc:creator>activespark</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[apress]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[magnus lie hetland]]></category>
		<category><![CDATA[object]]></category>
		<category><![CDATA[object orient]]></category>
		<category><![CDATA[oops]]></category>
		<category><![CDATA[oriented]]></category>

		<guid isPermaLink="false">http://activespark.wordpress.com/?p=328</guid>
		<description><![CDATA[While going through Magnus&#8216;s book &#8220;Begining python from novice to professional&#8220;, I was on chapter 11, and being a system admin, mostly sys ads don&#8217;t care whether the scripts written are object oriented or procedural, we njust need the script to be working, as most the time the requirements are urgent. The chapter 11in Magnus&#8217;s [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=328&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://activespark.files.wordpress.com/2009/10/bp2_cover_small.gif"><img class="alignleft size-full wp-image-329" title="bp2_cover_small" src="http://activespark.files.wordpress.com/2009/10/bp2_cover_small.gif?w=600" alt="bp2_cover_small"   /></a></p>
<p><span style="font-family:verdana;"><br />
While going through <a href="http://hetland.org">Magnus</a>&#8216;s book <a href="http://hetland.org/writing/beginning-python-2/">&#8220;Begining python from novice to professional</a>&#8220;, I was on chapter 11, and being a system admin, mostly sys ads don&#8217;t care whether the scripts written are object oriented or procedural, we njust need the script to be working, as most the time the requirements are urgent.<br />
</span></p>
<p><span style="font-family:verdana;">The </span><span style="font-family:verdana;"><u>chapter 11</u></span><span style="font-family:verdana;">in Magnus&#8217;s Book is well explained, its excellent, specially the polymorphism part, its beautifully explained. At the end of the chapter Magnus has written &#8220;Some thoughts on Object Oriented Design&#8221;, which i think are really practical and should be followed while writing the code. I am posting some of the tips here. Hope you find it useful.</span></p>
<p><span style="font-family:verdana;"><br />
</span></p>
<p><span style="font-family:verdana;"> </span></p>
<ul><span style="font-family:verdana;"><strong><u>Tips for Objet Orientation</u> :-</strong> </span></ul>
<p><span style="font-family:verdana;">• Gather what belongs together. If a function manipulates a global variable, the two of them might be better off in a class, as an attribute and a method. </span></p>
<p><span style="font-family:verdana;">• Don’t let objects become too intimate. Methods should mainly be concerned with the attributes of their own instance. Let other instances manage their own state.</span></p>
<p><span id="more-328"></span><br />
<span style="font-family:verdana;">• Go easy on the inheritance, especially multiple inheritance. Inheritance is useful at times, but can make things unnecessarily complex in some cases. And multiple inheritance can be very difficult to get right and even harder to debug.</span></p>
<p><span style="font-family:verdana;"> • Keep it simple. Keep your methods small. As a rule of thumb, it should be possible to read (and understand) most of your methods in, say, 30 seconds. For the rest, try to keep them shorter than one page or screen.</span></p>
<p><span style="font-family:verdana;"> </span><span style="font-family:verdana;"><strong><u> When determining which classes you need and which methods they should have, you may try something like this</u> :-</strong></span></p>
<p><span style="font-family:verdana;">1. Write down a description of your problem (what should the program do?). Underline all the nouns, verbs, and adjectives.</span></p>
<p><span style="font-family:verdana;">2. Go through the nouns, looking for potential classes.</span></p>
<p><span style="font-family:verdana;">3. Go through the verbs, looking for potential methods.</span></p>
<p><span style="font-family:verdana;">4. Go through the adjectives, looking for potential attributes.</span></p>
<p><span style="font-family:verdana;">5. Allocate methods and attributes to your classes.</span></p>
<p><span style="font-family:verdana;">Now you have a first sketch of an object-oriented model. You may also want to think about what responsibilities and relationships (such as inheritance or cooperation) the classes and objects will have.</span><span style="font-family:verdana;"><strong> </strong></span></p>
<p><span style="font-family:verdana;"><strong> </strong></span></p>
<p><span style="font-family:verdana;"><strong> <u>To refine your model, you can do the following</u> :-</strong></span></p>
<p><span style="font-family:verdana;">1. Write down (or dream up) a set of use cases—scenarios of how your program may be used. Try to cover all the functionality.</span></p>
<p><span style="font-family:verdana;">2. Think through every use case step by step, making sure that everything you need is covered by your model. If something is missing, add it. If something isn’t quite right,   change it. Continue until you are satisfied.</span></p>
<p><span style="font-family:verdana;">When you have a model you think will work, you can start hacking away. Chances are you’ll need to revise your model or revise parts of your program. Luckily, that’s easy in Python, so don’t worry about it. Just dive in.<br />
</span></p>
<br /> Tagged: apress, design, magnus lie hetland, object, object orient, oops, oriented, Python <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/activespark.wordpress.com/328/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/activespark.wordpress.com/328/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/activespark.wordpress.com/328/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=activespark.wordpress.com&amp;blog=8097552&amp;post=328&amp;subd=activespark&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://activespark.wordpress.com/2009/10/01/tips-for-object-orientated-design/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cee2e8176e6112c7cdb9de425274fe59?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">activespark</media:title>
		</media:content>

		<media:content url="http://activespark.files.wordpress.com/2009/10/bp2_cover_small.gif" medium="image">
			<media:title type="html">bp2_cover_small</media:title>
		</media:content>
	</item>
	</channel>
</rss>
