Ruby Fundamentals

This course is designed to give you everything you need to start developing software in Ruby quickly.
Course info
Rating
(534)
Level
Intermediate
Updated
Jun 20, 2013
Duration
3h 42m
Table of contents
An introduction to Ruby
Classes and Objects
Flow Control
Standard Types
Methods in Depth
More Ruby Tools: Blocks, Constants, Modules
Putting Ruby to Work
Description
Course info
Rating
(534)
Level
Intermediate
Updated
Jun 20, 2013
Duration
3h 42m
Description

Ruby is a dynamic, thoroughly object oriented programming language with a focus on developer happiness and productivity. This course is designed to give you everything you need to start developing software in Ruby quickly. You will learn about all of the key features of the language: classes, methods, blocks, modules. You will find out about some of the standard types included in Ruby, such as strings, arrays, hashes and regular expressions. You will also get an introduction to tools and techniques you need to write real world software, including testing, debugging and packaging your code.

About the author
About the author

Alex Korban is an author and consultant with an interest in functional programming, databases and geospatial applications. He co-founded a company to visualize geospatial data and wrote several books.

More from the author
Building Real World Applications with Elm
Intermediate
2h 18m
2 Feb 2018
PostgreSQL: Time and Temporal Data
Intermediate
3h 37m
16 Aug 2017
Section Introduction Transcripts
Section Introduction Transcripts

An introduction to Ruby
Hi this is Alex Korban welcome to the Ruby Fundamentals course. The goal of this course is to be a launch pad for your Ruby development. I'd like you to get a solid foundation for writing Ruby code. I would also like to leave you with an appreciation of Ruby's expressiveness and power. You will learn about setting up your environment to run Ruby programs. You will find out about the tools you can use. I will show you one of the popular Ruby IDE and some its features such as an integrated debugger. And of course you will learn about the features of the language and some of the standard libraries which come with it. In this first module you will find out how to get up and running and start experimenting with some code.

Classes and Objects
Hi this is Alex Korban. In this module you will learn about Classes and Objects in Ruby. You will find out how to create your own classes and how to instantiate objects from those classes. You will learn how to add instance variables and methods to your classes. You will find out how to control the visibility of these variables and methods. I'll show you how to initialize your objects. You will see how to create class variables and methods. You'll also get the hang of leveraging inheritance to re-use functionality. Finally I'll talk about self, which refers to the current context. I'll talk about what it means to have executable class bodies in Ruby and object equality.

Flow Control
Hi this is Alex Korban in this module you will learn about Flow Control in Ruby. I will start with branching via if-else and the case statement. I will then show you the various looping constructs and talk a little bit about blocks. I will tell you about exception handling. Finally you will see what throw and catch do in Ruby, which is probably not quite what you expect.

Standard Types
Hi this is Alex Korban in this module you will learn about some of the types in the Ruby standard library. The Ruby standard library is quite extensive, so this module is only going to scratch the surface of the available functionality. I will tell you about the types you will use in almost any Ruby program you write. Most of these types are also integrated into the language through special syntax _____. I'm going to talk about Booleans, types for representing integer and floating point numbers, regular expressions, strings, symbols, arrays and hashes, and finally ranges. I will also show you how to do parallel assignment.

Methods in Depth
Hi, this is Alex Korban in this module we'll have an in-depth look at writing and using methods in Ruby. You've already seen a lot of methods in the previous modules, however, they are really simple, taking just one or two arguments. Ruby has a lot more method features and in this module I'd like to get into the intricacies of defining and calling methods. I will show you how you can provide default values for method parameters. You will find out how to write methods which take a variable number of arguments. I will explain how you can add named arguments to your methods. I'll talk about creating method aliases and overriding methods. You'll see how operators and operator overload work in Ruby. I'll explain the method calls as messages model Ruby employs. Finally, we'll delve a little bit into metaprogramming when I talk about the method missing method.

More Ruby Tools: Blocks, Constants, Modules
Hi this is Alex Korban in this module I'll go into more detail about some of the language tools I mentioned in the previous modules. There are three more language constructs I need to talk about to give you the full picture of the Ruby language. The first one is blocks along with their cousin's procs and lambdas. I've already introduced blocks, but in this module I'm going to provide you with the details. The second construct is constants. The third thing I want to discuss is modules which are an essential part of the object orientation model and Ruby's answer to the complexities of multiple inheritance.

Putting Ruby to Work
Hi this is Alex Korban, in this module I will talk about some of the tools and techniques you will need to develop software in Ruby. There is a lot more to using the program and language than just learning the features of the language. In order to write maintainable, readable, and bug-free code you need to become familiar with the tools and techniques relevant to the language. This is the focus of this final module. I will talk about organizing the source code across files and directories. Almost any software you create will make use of third party libraries. I will explain Ruby's approach to managing third party code and show you how you can discover and install libraries created by other developers. These libraries are called gems in the Ruby ecosystem. The Ruby community places a strong emphasis on testing software. I will introduce you to some of the test and frameworks available for you to test your code. Even with tests in place you're likely to encounter some stubborn bugs which will require you to break out the debugger. So I will demonstrate how to use the debugger built into RubyMine. Once all the kinks are ironed out and your software is ready, you'll need to package and deploy it. I will discuss some approaches you can use for that. Finally I'll provide you with references to some of the resources you will need as a Ruby developer.