Ruby, Part 5 of 6: Procs and Metaprogramming
Interactive

Ruby, Part 5 of 6: Procs and Metaprogramming

LearnNow Online
Updated Aug 23, 2018

Course description

Join Ruby expert Jordan Hudgens as he takes a look at two advanced topics in Ruby development: Procs and Metaprogramming. In addition to building your own procs and lambdas, the sister class of procs, Hudgens will also review a production Ruby on Rails application using lambdas to create custom database query scopes. Hudgens will walk through a practical understanding of metaprogramming and building out a full Ruby program, as well as cover the define_method process which allows classes to be written more efficiently.

Each LearnNowOnline training course is made up of Modules (typically an hour in length). Within each module there are Topics (typically 15-30 minutes each) and Subtopics (typically 2-5 minutes each). There is a Post Exam for each Module that must be passed with a score of 70% or higher to successfully and fully complete the course.


Prerequisites

You should be familiar with basic text editing in a Windows or Linux environment. No prior knowledge of programming is assumed. This course builds on the previous ruby courses: Ruby: Introduction and Classes, Ruby: Variables and Data Structures, Ruby: Input/Output and Gems.


Meet the expert

Jordan Hudgens

Jordan Hudgens has certifications for Ruby on Rails, Thinkful; Ruby on Rails, Bloc.io; Front End Development, Thinkful; and AngularJS, Thinkful. He is currently vice president of engineering for TRACKR in Midland, Texas and is working on his PhD in Computer Science from Texas Tech. In addition to Ruby, Jordan works with PHP, JavaScript, MySQL, Postgres, CSS3, C, C++, C#, Objective-C, and Python. He also works with the frameworks Rails (Ruby), Zend (PHP), and Django (Python), plus the libraries AngularJS, jQuery, and Backbone.js.

Video Runtime

80 Minutes

Time to complete

300 Minutes

Course Outline

Metaprogramming

Proc (11:27)

  • Introduction (00:19)
  • Procs (04:21)
  • Demo: Proc (02:42)
  • Demo: Complex Proc (03:49)
  • Summary (00:15)

Lambda (07:20)

  • Introduction (00:24)
  • Lambdas (02:57)
  • Demo: Lambda (02:54)
  • Summary (01:05)

Proc vs. Lambda (06:52)

  • Introduction (00:22)
  • Proc vs. Lambda (03:08)
  • Demo: Proc vs. Lambda (03:08)
  • Summary (00:14)

Lambdas in Rails (06:09)

  • Introduction (00:21)
  • Lambdas in Rails (02:20)
  • Demo: Lambdas in Rails (03:00)
  • Summary (00:27)

Metaprogramming (06:28)

  • Introduction (00:22)
  • What Is Metaprogramming? (03:09)
  • Metaprogramming vs. AI (02:41)
  • Summary (00:14)

Open Class (10:37)

  • Introduction (00:19)
  • Opening Classes (03:51)
  • Demo: Opening Classes (06:06)
  • Summary (00:19)

Method Missing (15:41)

  • Introduction (00:17)
  • Method Missing (05:38)
  • Demo: Method Missing (05:04)
  • Demo: Using Method Missing (04:16)
  • Summary (00:23)

Define Method (10:47)

  • Introduction (00:17)
  • Define Method (04:24)
  • Demo: Define Method (05:45)
  • Summary (00:21)

Rails Metaprogramming (04:53)

  • Introduction (00:21)
  • Usage in Rails (01:30)
  • Demo: Metaprogramming in Rails (02:43)
  • Summary (00:18)
;