- Nitro (web framework)
-
Nitro Developer(s) George Moschovitis Stable release 0.41 / December 12, 2006 Operating system Cross-platform Available in Ruby Type Web application framework License BSD License Website http://www.nitroproject.org Nitro was a Ruby-based web application framework created by George Moschovitis. Nitro featured a powerful template system with a configurable pipeline of transformation steps. It was licensed under a 3-clause BSD license.
A key philosophy of Nitro was that it did not dictate how a web application should be structured. One could use templates with embedded code, as is typical with PHP or ASP, or one could use the model-view-controller approach, as found in for instance Ruby on Rails, or expand even further with a custom architectural pattern.
Nitro featured support for Ajax, XML, web services and syndication while staying standards compliant.
One of its key distinctions from other similar frameworks was its use of "Og" as the object-relational database mapping layer. Og could create database tables based on Ruby classes, or it could be easily adapted to use an existing database schema.
Contents
Og
The persistence framework developed together with Nitro was named Og, short for ObjectGraph. It was an object-relational mapping (ORM) system that allowed for storage and retrieval of Ruby objects from a backend store. This could be an RDBMS, but did not necessarily have to be so. A backend adapter had been developed that stored objects in individual YAML files on the filesystem.
Og would infer the database structure from the definition of classes that were managed by it. Database tables would be created by Og as necessary. This was different from the ActiveRecord approach used in Rails where the developer is responsible for creating the database tables. Og could adapt the database schema to simple changes in the class definition, such as adding or removing attributes. This feature was best turned off in a production environment. More involved changes might have required manual intervention, one could also simply remove the affected tables and let Og recreate them.
Og could be made to work with an existing (legacy) schema, by supplying hints as to which column is used to store a particular property, and which property is considered the primary key.
Examples
Hello world
require "nitro" class MyController def index "Hello from nitro!" end end Nitro.start MyController
Select day
This example demonstrates morphers, one of the available transformations for templates. This would result in a dropdown list containing the numbers 1 to 31, with the current day selected.
<select name="day"> <option for="day in 1..31" selected_if="day == Time.now.day">#{day}</option> </select>
Current status
Currently the development of this framework seems to have been abandoned, and the official website has been taken down. In 2009, it was announced that development of Nitro in the Ruby had been halted, since the primary contributor George Moschovitis had moved to development of Nitro under JavaScript[1]. Enthusiast were pointed to other Ruby framework projects, such as Ramaze[2].
References
External links
Ruby programming language IDE - NetBeans
- RubyForge
- RadRails
- RubyMine
- ActiveState Komodo
Implementations Applications Libraries and frameworks - Adhearsion
- Camping
- eRuby (RHTML)
- Hobo
- Merb
- Nitro
- RubyCocoa
- Ruby on Rails
- Ramaze
- Sinatra
- Padrino
- QtRuby
Server software Other - Category
Web application frameworks ASP.NET ASP.NET MVC · ASP.NET Web Forms · ASP.NET Dynamic Data · BFC · DotNetNuke · MonoRail · OpenRasta · UmbracoColdFusion Common Lisp C++ CppCMS · WtJava Apache Struts · AppFuse · Flexive · GWT · Grails · Vaadin · ItsNat · JavaServer Faces · Jspx · Makumba · OpenXava · Play · Eclipse RAP · Reasonable Server Faces · RIFE · Seam · Spring · Stripes · Tapestry · WebWork · Wicket · ZK · ICEfaces · WaveMakerJavaScript Ample SDK · Prototype JavaScript Framework · Rico · script.aculo.us · SproutCore · jQuery · Dojo ToolkitPerl PHP AppFlower · CakePHP · CodeIgniter · Drupal · e107 · Horde · Joomla! · Lithium · Midgard · MODx · Qcodo · Seagull · SilverStripe · Symfony · TYPO3 · Xaraya · Yii · Zend Framework · Zeta ComponentsPython Ruby Smalltalk Other languages Application Express (PL/SQL) · Fusebox (ColdFusion and PHP) · HAppS (Haskell) · Kepler (Lua) · Lift (Scala) · OpenACS (Tcl) · SproutCore (JavaScript/Ruby) · Yaws (Erlang)Categories:- Web application frameworks
Wikimedia Foundation. 2010.