Ruby on Rails, often shortened to Rails or RoR, is an open source web application framework for the Ruby programming language. It is intended to be used with an Agile development methodology that is used by web developers for rapid development.
Ruby is a dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write.
Is is popularly known as ROR or Rails for short, Ruby on Rails is a web application framework option that seek to use logical steps to help create workable code for the creation of web sites. As an open source project that is written in Ruby program language, Ruby on Rails uses the Model-View-controller design pattern as the foundation for how the framework functions. Ruby programming language has the advantage of being relatively easy for anyone to learn and also follows a logic sequence that many people find easy to follow.
There are two basic principles that govern the way that Ruby on Rails works. The first is often referred to as DRY, or Don’t Repeat Yourself. The idea is to keep the language as simplistic as possible, so the code remains simple as well. This means that the person writing the programming does not have to specify column names in class definitions. Ruby on Rails will simply pull the information from the database source.
Framework structure
Ruby on Rails is separated into various packages, namely ActiveRecord (an object-relational mapping system for database access), ActiveResource (provides web services), ActionPack, ActiveSupport and ActionMailer. Prior to version 2.0, Rails also included the Action Web Service package that is now replaced by Active Resource. Apart from standard packages, developers can make plugins to extend existing packages.
Ruby on Rails recent developments
Rails version 2.3 was released on March 15, 2009. Major new developments in Rails includes templates, engines, Rack and nested model forms.
- Templates enable the developer to generate a skeleton application with custom gems and configurations.
- Engines let one reuse application pieces complete with routes, view paths and models.
- The Rack web server interface and Metal allow one to write optimized pieces of code that route around ActionController.
Rails in production
Popular websites that use the Ruby on Rails web development framework in production environments which includes: Hulu, Scribd, Whitepages.com, XING, Yellowpages.com and many more.
In Ruby, everything is an object. Every bit of information and code can be given their own properties and actions. Object-oriented programming calls properties by the name instance variables and actions are known as methods. Ruby’s pure object-oriented approach is most commonly demonstrated by a bit of code which applies an action to a number.
Ruby’s Flexibility
Ruby is seen as a flexible language, since it allows its users to freely alter its parts. Essential parts of Ruby can be removed or redefined, at will. Existing parts can be added upon. Ruby tries not to restrict the coder.
Exceptional Features of Ruby
- Ruby has a wealth of other features, among which are the following:
- Ruby has exception handling features, like Java or Python, to make it easy to handle errors.
- Ruby features a true mark-and-sweep garbage collector for all Ruby objects. No need to maintain reference counts in extension libraries. As Matz says, “This is better for your health.”
- Writing C extensions in Ruby is easier than in Perl or Python, with a very elegant API for calling Ruby from C. This includes calls for embedding Ruby in software, for use as a scripting language. A SWIG interface is also available.
- Ruby can load extension libraries dynamically if an OS allows.
- Ruby features OS independent threading. Thus, for all platforms on which Ruby runs, you also have multithreading, regardless of if the OS supports it or not, even on MS-DOS!
- Ruby is highly portable: it is developed mostly on GNU/Linux, but works on many types of UNIX, Mac OS X, Windows 95/98/Me/NT/2000/XP, DOS, BeOS, OS/2, etc.
No comments:
Post a Comment