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
Design pattern Adapter
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Lucas Hiago de Moura Vilela
September 02, 2019
Programming
0
35
Design pattern Adapter
This is a little talk about the design pattern Adapter
Lucas Hiago de Moura Vilela
September 02, 2019
Tweet
Share
More Decks by Lucas Hiago de Moura Vilela
See All by Lucas Hiago de Moura Vilela
SQL com Arel no Rails
luchiago
0
27
Brown Bag - Aplicação mobile de vídeo-chamadas
luchiago
0
48
Gitpod
luchiago
1
70
Introduction to Scrapy
luchiago
0
36
Other Decks in Programming
See All in Programming
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
220
2026年 エンジニアリング自己学習法
yumechi
0
130
プロダクトオーナーから見たSOC2 _SOC2ゆるミートアップ#2
kekekenta
0
200
Rust 製のコードエディタ “Zed” を使ってみた
nearme_tech
PRO
0
150
AIによる高速開発をどう制御するか? ガードレール設置で開発速度と品質を両立させたチームの事例
tonkotsuboy_com
7
2.1k
AgentCoreとHuman in the Loop
har1101
5
230
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
130
インターン生でもAuth0で認証基盤刷新が出来るのか
taku271
0
190
Fragmented Architectures
denyspoltorak
0
150
コントリビューターによるDenoのすゝめ / Deno Recommendations by a Contributor
petamoriken
0
200
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
6k
「ブロックテーマでは再現できない」は本当か?
inc2734
0
810
Featured
See All Featured
Music & Morning Musume
bryan
47
7.1k
Navigating Weather and Climate Data
rabernat
0
100
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
72
HDC tutorial
michielstock
1
360
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.4k
Building AI with AI
inesmontani
PRO
1
690
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.3k
A Soul's Torment
seathinner
5
2.2k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
196
71k
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
55
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
63
Transcript
Adapter Padrão de Projeto Estrutural
Padrão de Projeto Estrutural • Definição ◦ Preocupação com a
forma • De classe ◦ Utilização da herança • De objetos ◦ Descrever maneiras de compor novos objetos DASDSDSA
Adapter • Também conhecido como Wrapper • Padrão de projeto
de Classe • Motivação: reaproveitar uma classe
Objetivo • Converter interface • “Traduzir” solicitações • Permitir comunicação
entre interfaces incompatíveis
Aplicação • Utilizado quando: ◦ Se deseja utilizar uma classe
existente ◦ Criar classes reutilizáveis ◦ Para adaptar interface da classe mãe de subclasses
Diagrama UML • Client: Colabora com os objetos em conformidade
com a interface Target • Target: Define a interface do domínio específico que o cliente utiliza • Adapter: Adapta a interface Adaptee para a interface da classe Target • Adaptee: Define uma interface existente que necessita ser adaptada
Consequências • Adapter concreto e as classes e subclasses adaptadas
• Substituição de algum comportamento da classe adaptada • Complexidade
Código