Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
CW 31: Ruby - Filipe Giusti
Search
hackthursday
August 02, 2012
Programming
56
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
CW 31: Ruby - Filipe Giusti
hackthursday
August 02, 2012
Transcript
14 slides
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
More Decks by hackthursday
See All by hackthursday
CW 36: Joomla! for dummies - Jerônimo Medina Madruga
hackthursday
1
72
CW 35: Node.JS - Guilherme Quental
hackthursday
1
57
CW 34: Bus1.me - Rafael Silva
hackthursday
2
63
CW 33: Pathfinding - Vinicius Maciel
hackthursday
1
48
CW 26: Computação Gráfica - Lucas Texeira
hackthursday
1
64
CW 25: Object Calisthenics - Vinícius Krolow
hackthursday
1
120
Other Decks in Programming
See All in Programming
Lambda durable functionsでHuman in the Loopを楽に…楽に……
har1101
2
320
조합이폭발하는디자인시스템이걸눈으로도테스트하라고요
giljongyu
0
750
クラウドエージェントは、 何がそんなに便利なのか / what makes cloud agents so useful
rkaga
5
880
TS 7.0 で baseUrl が使えなくなった今、パスエイリアスをどうするか
bicstone
2
660
Kawaiicon: Kubernetes, it's no longer cool, but let's secure it anyway!
barnbarn
0
130
Vapor Mode でアクセシビリティは 壊れないか検証した話
fuqda
1
350
止まらない比較を止める — 余帰納法で無限ストリームを比べる
tarao
0
170
flutter_test のその先へ — Flutter アプリの LLM 機能に「評価」という品質保証を
kosukesaigusa
0
200
React Native에 현대적인 빌드 도구 더하기: Rollipop 구현기
leegeunhyeok
0
180
AIで開発が速くなった先で、開発チームは何を目指すか
shihochan
1
2.1k
はじめてのPLATEAU
nokonoko1203
1
650
Distance field of Julia set
kinakomoti321
0
320
Featured
See All Featured
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
540
Highjacked: Video Game Concept Design
rkendrick25
PRO
2
570
Statistics for Hackers
jakevdp
799
230k
Deep Space Network (abreviated)
tonyrice
0
420
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
610
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
Site-Speed That Sticks
csswizardry
13
1.6k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
460
Faster Mobile Websites
deanohume
310
32k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
The untapped power of vector embeddings
frankvandijk
2
2k
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k