Archive for the ‘Technical’ Category

What Is Parsing?

Author: mprokes

Alpha Edition!, e-mail spelling/grammer/topic suggestions to mattprokes@gmail.com

next1previous1The Professional Developer Series
Volume 2, Web Development

Chapter 1.3 Web Development Today

Page: #13


What does it mean to parse something?

The term parse will be used frequently throughout this book. So lets just give a quick run through of parsing, and why it is necessary in web development today. As wikipedia states, parsing is the action of analysis.

We as humans parse things every day, for instance you as a reader are able to parse (or read) the english language. As a result, a reader is able to store data, and learn things from reading. Computers are no different, they are also able to read as well (in this case xml) through their programming, and then take that data that has been processed, and do something useful with it (what ever that may be).

The action of processing and understanding data which a computer receives, and doing something useful with it is the definition of parsing. The XML language is already parsed by many many languages, so the hard part is done. Once xml is parsed though, the computer still does need instructions on what to do with that data.  So even though xml date may have been parsed and is readily available, that doesn’t mean that the computer knows what to do with that data yet.

The action of reading data is part of the parsing process called “processing data”, or “analyzing data”; and since most of today’s applications are driven by data, they do a ton of this. During the processing stage of parsing the computer may build a “representation” of the data in its own language, this is called a “data model”.

The computer may also decide to take action or “execute” on some of the data it finds while processing. All this is determined by the programmer, and many programmers make a good career out of just writing parsers to help computers understand all the different languages out there.

There are several different ways of parsing data; summarizing, there are techniques like pattern matching (Regular Expressions) as well as more recently matching hierarchical features (XPath), and many of the API’s out there designed to parse things like XML. Some are a combination of both (Antlr), regardless parsing will be a fundamental part of your career. You need it for things like validating data, and reading data which you receive; so if you have a bit of time, I suggest learning Regular Expressions or XPath.

  • Reddit
  • StumbleUpon
  • Bebo
  • Yahoo Buzz
  • Delicious
  • Twitter
  • LiveJournal
  • Netlog
  • HelloTxt
  • Share/Bookmark

Calling all editors

Author: mprokes

Hello, I am currently attempting to publicly write a series of programming books, and I am looking for a few good people that would review my work as I publish it and offer an editorial review of said work. In return (for frequent editors) I will post your name as the works’ editor on the front cover of the particular series of which you are editing :-) . Anyone interested please e-mail me at mattprokes@gmail.com . Thankx for your help.

Your Friendly Developer

~Matt Prokes

  • Reddit
  • StumbleUpon
  • Bebo
  • Yahoo Buzz
  • Delicious
  • Twitter
  • LiveJournal
  • Netlog
  • HelloTxt
  • Share/Bookmark

Alpha Edition!, e-mail spelling/grammer/topic suggestions to mattprokes@gmail.com

next1previous1The Professional Developer Series
Volume 2, Web Development

Chapter 1.3 Web Development Today

Page: #10


Todays’ modern web development is a complicated, and intertwined with several complexities; make no mistake developing software is hard. My goal in this book is to take you down the most probable path of web development success. You may be asking yourself though, what are the possible paths one may take to deliver a web based product? Well it depends on the product, most modern web development is split between some common technologies of today.

Modern Web Development Technologies:

  • Syndicated Data (RSS,ATOM,Webservices):Allows people to subscribe to a data feed about a particular topic, and receive updates on that topic when ever the feed is updated. This technology is useful if a person wishes to get up-to-date information about the subject, similar to a mailing list only the subscription is maintained by your users rather then an organization. Some organizations syndicate data as a service, or more commonly known and delivered as webservices, essentially providing data/algorithmic processing for a fee.
  • Mobile WAP (WML): Allows people to view internet content via mobile devices. WAP, or the wireless access protocol is used among many of todays’ common cellphones. Mobile technology is continuing to be of growing importance as the internet moves beyond the desktop computer and leveraged through the mobile devices of tomorrow.
  • Rich Browser Applications: Most people call these (RIA’s), but I am going to be a bit more general about these. We are seeing more growth in browser based applications, some of these browser applications are internet based (RIA’s) meaning they require the internet to exist. Yet another group of applications (google gears, others) do not so much require the internet to exist, but rather a browser environment. Both sets of applications leverage html, javascript, xslt, css, and other browser technologies, and may periodically require internet connections, but in general they are applications that operate from a browser environment. Many modern rich browser applications have replaced, or will replace most desktop applications in the future. With the upcoming 3D standards coming out, it most likely that even common 3d games will be distributed via the internet.
  • Web Pages: have been around forever, and are the most common form of media on the internet. They often leverage html, css, and other technologies to display easy to read content to internet users.
  • Flash, Applets, and Plugins: This technology represents a set of media which can be embedded into internet content to dynamically interact with web content, and extend its functionality often for multi-media purposes.

This is a very shallow list of technologies keep in mind; the ways in which they are used is very diverse, and sometimes even overlaps. The purpose of a technology isn’t necessarily what it is always used for, and it is often left to the architect to engineer what solution is best for them.

  • Reddit
  • StumbleUpon
  • Bebo
  • Yahoo Buzz
  • Delicious
  • Twitter
  • LiveJournal
  • Netlog
  • HelloTxt
  • Share/Bookmark

I have been toying with a seemingly tidy distro recently called OpenGEU; and I have to admit, its one of the best distributions I have ever seen. Luna Crescente is a mix of ubuntu, enlightenment 17, and gtk based apps, it also uses stalone tray. The seemingly simplistic combination is one of the most beautiful lightweight linux desktops that I have seen in recent times (and i have tried them all!). It has the speed that enlightenment brings to the table, as well as the hardware/packaging support that makes ubuntu so great. Toss in a very tidy, and fresh looking orange gtk+ theme, and I would say that OpenGEU is by far the most beautiful distribution I have seen thus far out of the box.

In conjunction with its beauty, is the awesome firing squad of lightweight apps that I have come to appreciate. Among these are thunar (though I am usually a rox-filer fan I gave it a try and actually like it more!), many lightweight enlightenment based apps including pdf readers, music players, etc.. One of the great things about this distribution is that it actually believes in including not just the enlightenment desktop, but also the modules, which alone run very very fast! Other applications that I know and log in gnome are also included such as nm-applet, update managers, and synaptic to finish things off. Everything ran out of the box, and I specifically liked the live cd/install it try it before you buy it feature that is now very common in linux distributions. So I would suggest to all of you reading to go check it out! Download the live cd, and give it a spin I have had a very positive experience thus far.

  • Reddit
  • StumbleUpon
  • Bebo
  • Yahoo Buzz
  • Delicious
  • Twitter
  • LiveJournal
  • Netlog
  • HelloTxt
  • Share/Bookmark

Testing Code

Author: mprokes

Commenting Your Code
Comments will always be an important part of programming; they are often used to describe whats going on in your code, and even for automatically generating documentation.

There are two styles of comments:

  • //Single Line

  • /*
    Multi
    Line
    */

Some issues with multi-line comments:

Since multi-line comments end with *\ this means that you may never include a *\ within the body of the comment.

ex:

	/*
 		An error is caused when I use a */ as you can see.
	*/
	

  • Reddit
  • StumbleUpon
  • Bebo
  • Yahoo Buzz
  • Delicious
  • Twitter
  • LiveJournal
  • Netlog
  • HelloTxt
  • Share/Bookmark