1) Download iTunes from http://www.apple.com/itunes/download/ and subscribe to the “Leraning Rails” Podcasts from http://www.buildingwebapps.com/podcasts
First of all, when you click first link to download iTunes, you will see above web page. Then, click the "Download Now" button and click "Run" button. After that, iTunes will be downloaded to your computer and setup progress will be started automatically.


Next step is subscription to the “Leraning Rails” Podcasts from. To do this click on second link above. Then, follow the instructions to subscribe online Ruby on Rails courses.

2) Install Ruby on Rails on your computer by using the material and downloads from http://rubyonrails.org/download
When you click this link, you will see "Windows Installer" button under the Ruby part, and to get ruby, please click on it. Besides that, there are also other versions for other operating systems. But in this workshop, I am going to use 1.8.6-26 Final Release for windows vista operating system.


After download progress, you can use One-Click Ruby Installer property to install it on your computer. It does a lot of work for you by installing Ruby, Ruby Gems Package Manager, Rake, all of the other standard Ruby tools, and even the open source SciTE programmer’s editor. Additionally, the installer configures the command line interface path information, so the Ruby tools are ready to use in the Command Prompt program.

3) Rather than get Ruby on Rails running manually, you use the pre-packaged solutions. These include everything in one bundle: Web server, database, Ruby, Rails, the works.
a. For OS X, there's Locomotive.
b. For Windows, there's Instant Rails.
As it can be understood from third step, for windows operating systems Instant Rails application provides all you needs and it is easy to use.In other words, you do not need to install Ruby as shown in second step. In order to download Instant Rails visit http://rubyforge.org/frs/?group_id=904 web page. Then, download latest version which is "InstantRails-2.0-win.zip".
There are some easy steps which you have to complete before start your first Ruby application.
1. First of all, you have to extract InstantRails-2.0-win.zip file into your computer's C:/ drive. After extraction process, you should able to see content of the Instant Rails like this;

2. Next step is starting Instant Rails application, to run it just click on "InstantRails.exe". Then you will see a small Instant Rails window like shown below. When it appears, click on "I" button and you will see main menu. Then click "Rails Application --> ManageRails Applications", as it is shown below.


3. Another step is managing your Rails applications or creating a new one. In this part, I am going to show you how can you start an existing application.
3.1 As shown in below window, choose an aplication on your Rails Application list. Then click on "Start with Mongrel" button.

3.2 After that you will see start processes of the web server and your application's port number as well, on a black screen.

3.3 Finally, you can start your sample Rails application on your Web browser. Just, open a web browser and type http://localhost:3001/.

CHALLENGE PROBLEMS
Question 1 : Make a list of all programming languages and Web development tools used by you in prior experiences. Describe what you know about Web application frameworks before we begin.
During my universtiy education and work experience, I am familiar with some programming languages such as, C, C++, C#, ASSEMBLY, SHELL SCRIPT, JAVA, PL/SQL, HTML, PHP, OpenGL, VRML and NesC. Besides these programming languages, I have some experiences with Dreamweaver web development tool.
In order to describe Web application frameworks, first of all meaning of web application should be clearly defined. According to resources, web application can be simplified as "a structured set of objects that may be navigated and processed, in order to achieve one or more tasks". Therefore, a web application framework can be defined as " a generic definition of the possible application objects, together with a generic definition". In other words, setting possible objects to be navigated and structiring their navigation architecture. (Murugesan & Deshpande, 2001, p. 338) The main target of frameworks is providing separation between data model and user interface using with business rules.
References
Murugesan S., & Deshpande Y. (2001). Web engineering: managing diversity and complexity of Web application development. Springer Press.
Question 2 : Ruby is defined as “an interpreted scripting language” for quick and easy object-oriented programming”. Find out about the Ruby language and discover what this means.
Ruby is "a completely object-oriented language. Every value is an object, even simple numeric literals and the values true, false, nil". (Flanagan & Matsumoto, 2008, p. 2) It provides programmers easily developing techniques and performing system management tasks.
References
Flanagan D., & Matsumoto Y. (2008). The Ruby Programming Language. O'Reilly Press.
Question 3: What is Rails and how does it work with Ruby?
Rails is "the web application framework that will put everything online." (Holzner, 2006, p. 1) It is written in the Ruby language and designed to the Model View Controller (MVC) pattern. MVC is used for seperating an application's data model, user interface and control logic. This process is formed by three separate layers with minimal dependencies on each other. When a request comes from a browser the Ruby on Rails stores all MVC related files in the app directory, which is located in the application root directory. (Hellsten & Laine, 2006 , p.20)
References
Hellsten C., & Laine J. (2006). Beginning Ruby on Rails e-commerce. Apress Press
Holzner S. (2006). Beginning Ruby on Rails. John Wiley and Sons
Question 4: What is meant by “convention over configuration” in regards to the use of Rails in Web application development?
Convention over configuration is a simple concept. Systems, libraries. and frameworks should assume reasonable defaults without requiring that unnecessary configuration. Therefore this aproach provides systems just work. (Zyl, 2008, p. 3) In conventional approach, things are named consistently and are stored in standardized place. Rails uses a simple convention for URL routing: the names of a controller (a class name), action (a method name), and primary key (ID) are used in a consistent manner in the URL, so they don't need to be supplied through some other mechanism. By the way, this convention can be overridden. (Hardy, Carneiro, & Catlin, 2007, p. 7)
References
Hardy, J. A., Carneiro, C., & Catlin H. (2007). Beginning Rails: from novice to professional. Apress press
Zyl, J.V. (2008). Maven: The Definitive Guide. O'Reilly Press.
Question 5: When did Model-View-Controller begin and where is it used?
MVC was designed by Trygve Reenskaug in 1979. Then it was firstly implemented on Smalltalk at Xerox PARC. It aimed the development and maintainability of Smalltalk GUI applications by a clear division of business logic. Thirty years later, the same architecture is widely adopted for Web development. (Arking & Cangiano, 2009, p. 36)
The MVC is commonly used as architectural pattern for frameworks, which can be used to very rapidly produce a full-featured MVC Web application. (Moore, Budd & Benson, 2007, p. 176) In other words, MVC approach is largely based on an event-driven environment where the user drives the flow of application by using the interface. (Chopra, Eaves, Jones, Li & Bell, 2005, p. 534)
References
Arking, J., & Cangiano, A. (2009). Ruby on Rails for Microsoft Developers. John Wiley and Sons Press
Chopra, V., Eaves, J., Jones, R., Li, S., & Bell, J.T. (2005). Beginning JavaServer pages. John Wiley and Sons Press
Moore, D., Budd, R., & Benson, E. (2007). Professional Rich Internet Applications. John Wiley and Sons Press
Question 6: Describe the steps involved with the MVC design approach.
MVC design approach attempts to seperate an application into three parts. These parts can be described as MODEL, VIEW and CONTROLLER.
MODEL: It does the work and models the real world problem that application attempts to solve.
VIEW: It is the representation of the Model that user can see and interact with.
CONTROLLER: It is the part of the application that responds to commands from the user, deciding how model should be changed or retrieved and which view should be displayed. (Chopra, Eaves, Jones, Li & Bell, 2005, p. 534)
References
Chopra, V., Eaves, J., Jones, R., Li, S., & Bell, J.T. (2005). Beginning JavaServer pages. John Wiley and Sons Press
No comments:
Post a Comment