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
アスペクト指向プログラミング
Search
ToruTakagi
May 16, 2018
Programming
260
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
アスペクト指向プログラミング
研修先で5分間のLTをする際に作りました
ToruTakagi
May 16, 2018
More Decks by ToruTakagi
See All by ToruTakagi
Webフロントの変化 ~時代はPWAへ?~
torutakagi
0
98
Vue.js
torutakagi
0
160
Other Decks in Programming
See All in Programming
複数ドメインを一つのアプリに統合するFlutterの設計と運用_FlutterKaigi2026登壇資料(須永高弘)
takahirosunaga
0
160
baseline으로 마이그레이션, 리팩토링 안전하게 맡기기
fornewid
1
960
オーケストレーション記述言語 Katari
yukikurage
0
240
あなたの await、OS まで届いてる? strace で覗く JavaScript の非同期
hasutosasaki
1
2.3k
地方こそサーバーレス — 10年続けた、顔が見えるチームで確かな基盤を / Serverless Matters Most in Regional Areas — 10 Years of Building Reliable Foundations with Close-Knit Teams
seike460
PRO
1
330
AI時代のTerminal環境を UNIX哲学で設計・運用する
yasunori0418
1
350
PumaからFalconに移行したRailsアプリケーションでの実践
falcon8823
0
370
Herb in Rails 8.2: Your ERB views, now HTML-aware @ Kaigi on Rails 2026, Tokyo, Japan
marcoroth
2
420
3回つくってわかった、 定期実行ジョブ基盤の本質情報
takai
4
3.8k
エージェントを使い続けるためのメタワーク / Meta-work for keeping using the agent
rkaga
6
2.2k
高橋メソッドでCVE解説シリーズ 〜CVE-2026-112816〜
hakkadaikon
0
230
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
200
Featured
See All Featured
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
510
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
1.1k
Six Lessons from altMBA
skipperchong
29
4.6k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
470
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
590
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
8.4k
Between Models and Reality
mayunak
4
570
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
750
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2.6k
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
2
1.6k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
70
68k
Transcript
Aspect Oriented Programming
注意点 言葉の定義を変えてる 2 2018/05/18
What is AOP OOPを倒すもの VS 3 2018/05/18
What is AOP OOPの弱点を補う 4 2018/05/18
AOPって何ができる? 5 2018/05/18
出力結果は? public class Main { public static void main(省略) {
} } 6 2018/05/18
出力結果 C:¥>java Main Hello World!! 7 2018/05/18
Aspectって何ができる? 既存のシステムをいじらず ・変数の値を変更 ・メソッドの中身を書き換え ・特定のタイミングで処理を行う 8 2018/05/18
AOPが生まれた背景 ✔ ソフトウェア工学の視点 ✔ OOPの視点 9 2018/05/18
✔凝集度 クラスに無駄な機能が入ってないか ✔結合度 クラスの関係性 What is Cohesion and Coupling 10
2018/05/18
凝集度 高い 結合度 低い 一般的 11 2018/05/18
1つの関数に全部書けば 結合度低くね? 極論 12 2018/05/18
13 図1. アスペクト指向の考え方の原点[1] [1]Kurowasi, “時代が来るかも?アスペクト指向プログラミング,AspcetJ言語とは何か,” 2018/05/18
AOPが生まれた背景 ✔ ソフトウェア工学の視点 ✔ OOPの視点 14 2018/05/18
グループ分けの単位 What is Concern(関心事) 15 2018/05/18
ブログシステム 16 2018/05/18
OOPの限界 ログイン機能 ページを返す機能 記事登録機能 ユーザ情報取得 一致するか判定 欲しいページ取得 記事をDBに登録 ログを登録 17
図2. ブログシステム 2018/05/18
OOPの限界 ログイン機能 ページを返す機能 記事登録機能 ユーザ情報取得 一致するか判定 欲しいページ取得 記事をDBに登録 ログを登録 18
図3. OOPでの関心事の分離 2018/05/18
Crosscutting Concern ログイン機能 ページを返す機能 記事登録機能 ユーザ情報取得 一致するか判定 欲しいページ取得 記事をDBに登録 ログを登録
19 図4. 横断的関心事 2018/05/18
Aspect ログイン機能 ページを返す機能 記事登録機能 ユーザ情報取得 一致するか判定 欲しいページ取得 記事をDBに登録 ログを登録 アスペクト
20 図5. アスペクトによる横断的関心事の解決 2018/05/18
OOP 21 図6. オブジェクト指向の目線 2018/05/18
AOP 22 図7. アスペクト指向の目線 2018/05/18
複数の視点から 関心事の分離が可能 AOPにって限界突破 23 2018/05/18
✔OOPの問題点 ◆結合の問題 ◆横断的関心事の問題 ✔AOPによる解決 ◆コンパイラが結合 ◆複数の視点で見れる まとめ 24 2018/05/18
Yes Silver Bullet 25 2018/05/18