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
Transcript
25 slides
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
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
高橋メソッドでCVE解説シリーズ 〜CVE-2026-112816〜
hakkadaikon
0
280
[DroidKnights 2026] Workflow AX 적용기 — 자동 정책 정리부터 E2E까지
dayeon
0
120
Rails初心者がパスキーを実装してみて大変だったこと
ktombow
0
240
社内AIエージェント「Askワンバン」における コストチューニングの取り組み
t0yohei
0
180
joyful-journey-spring-boot.pdf
hollycummins
0
120
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
160
[Kotlin Fest 2026] eBPF Tracing for Kotlin
takehaya
1
410
protojson における文字化けの扱い
kazuki1023
0
470
ruby/uri meets WHATWG
jinroq
0
150
疎結合とは何か?ソフトウェア設計における結合バランスについて考える #phpcon_niigata
kajitack
2
430
AIコーディングをセッションで終わらせない: PHPライブラリ開発におけるコンテキスト承継設計
ickx
0
110
AppFunctionsの内部実装を紐解く
hiroaki404
1
120
Featured
See All Featured
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
380
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
2
1.7k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Scaling GitHub
holman
464
140k
Testing 201, or: Great Expectations
jmmastey
46
8.4k
How to make the Groovebox
asonas
2
2.6k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
1.1k
Crafting Experiences
bethany
1
460
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
620
Claude Code のすすめ
schroneko
67
230k
Max Prin - Stacking Signals: How International SEO Comes Together (And Falls Apart)
techseoconnect
PRO
0
540
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
33
5.9k