Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CW 31: Ruby - Filipe Giusti
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
hackthursday
August 02, 2012
Programming
1
42
CW 31: Ruby - Filipe Giusti
hackthursday
August 02, 2012
Tweet
Share
More Decks by hackthursday
See All by hackthursday
CW 36: Joomla! for dummies - Jerônimo Medina Madruga
hackthursday
1
58
CW 35: Node.JS - Guilherme Quental
hackthursday
1
48
CW 34: Bus1.me - Rafael Silva
hackthursday
2
56
CW 33: Pathfinding - Vinicius Maciel
hackthursday
1
36
CW 26: Computação Gráfica - Lucas Texeira
hackthursday
1
51
CW 25: Object Calisthenics - Vinícius Krolow
hackthursday
1
100
Other Decks in Programming
See All in Programming
今こそ知るべき耐量子計算機暗号(PQC)入門 / PQC: What You Need to Know Now
mackey0225
3
340
rack-attack gemによるリクエスト制限の失敗と学び
pndcat
0
240
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.6k
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
170
例外処理とどう使い分ける?Result型を使ったエラー設計 #burikaigi
kajitack
16
5.7k
疑似コードによるプロンプト記述、どのくらい正確に実行される?
kokuyouwind
0
330
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
1.9k
メルカリのリーダビリティチームが取り組む、AI時代のスケーラブルな品質文化
cloverrose
2
490
AI によるインシデント初動調査の自動化を行う AI インシデントコマンダーを作った話
azukiazusa1
1
460
AI Agent Tool のためのバックエンドアーキテクチャを考える #encraft
izumin5210
6
1.7k
それ、本当に安全? ファイルアップロードで見落としがちなセキュリティリスクと対策
penpeen
7
2.3k
Grafana:建立系統全知視角的捷徑
blueswen
0
300
Featured
See All Featured
Being A Developer After 40
akosma
91
590k
Java REST API Framework Comparison - PWX 2021
mraible
34
9.1k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.4k
GraphQLとの向き合い方2022年版
quramy
50
14k
Git: the NoSQL Database
bkeepers
PRO
432
66k
Raft: Consensus for Rubyists
vanstee
141
7.3k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
61
52k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
2
300
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8.6k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
61
Mobile First: as difficult as doing things right
swwweet
225
10k
The Spectacular Lies of Maps
axbom
PRO
1
440
Transcript
Ruby Elegância e expressividade
Ruby • Tipo de linguagem • Interpretadores • Sintaxe •
Objetos & Mensagens • Features • Tools • Rack • Rails • Sinatra
Ruby - Interpretadores • MRI - Matz's Ruby Interpreter •
YARV - Yet Another Ruby VirtualMachine • Jruby - JVM • Rubinius – Ruby em Ruby • IronRuby - .NET • MacRuby – Objective C
Ruby – Tipo de linguagem • Tipagem Dinâmica • OO
• Fortemente tipada • Garbage collection
Ruby - Sintaxe • Constante • ::EscopoGlobal • variavel_local •
@variavel_de_objeto • @@variavel_de_class • 2 • 2.3 • “string #{interpolada}”
Ruby - Sintaxe • :symbol • [1, 2] • {
:ola => 'voce' } ou { ola: 'voce' } • raise HelpError unless world.is_safe? • drink while ! beer.nil? • for nerd in @dj_house; nerd.eat(meat); end • case; when; default; end • 3.times { puts 'Hurra!' }
Ruby - Sintaxe • 3.times do; puts 'Hurra!'; end •
1..10 • Imprimir ímpares de 1 a 20 em ordem inversa
Ruby – Objetos e Mensagens • (Quase) Tudo são objetos.
• (Quase) Todas as interações são feitas com troca de mensagens • 1 + 1 • 1.+(1) • 1.send('+', 1)
Ruby – Objetos e Mensagens
Ruby - features • Suporte a introspecção (respond_to) • Redefinição
de métodos • Classes abertas • method_missing • Sem overload de métodos • Herança múltipla com mixins • const_missing
Ruby - Tools • Gems • bundle • Webservers •
Thin • Passenger • Unicorn • JVM • RVM e rbenv
Ruby - Rack • Ruby Webserver Interface • API minimalista
para os frameworks web • config.ru
Ruby - Rails • MVC • Routing • Middleware •
Migrations • Helpers
Ruby - Sinatra • DSL para aplicações web • Views
• haml :index • Helpers • enable :sessions