Strangler fig pattern: Difference between revisions

Content deleted Content added
Undid revision 1238143264 by Roki68199 (talk) spam
top: Fowler coined the name, but did not invent the technique
Tags: Mobile edit Mobile app edit Android app edit App full source
 
Line 1:
{{Short description|Computer science architectural pattern}}
In programming, the '''strangler fig pattern''' or '''strangler pattern''' is an [[architectural pattern]] that involves wrapping old code, with the intent of redirecting it to newer code or to log uses of the old code. CreatedCoined by [[Martin Fowler (software engineer)|Martin Fowler]],<ref name=":0" /> its name derives from the [[strangler fig]] plant, which tends to grow on trees and eventually kill them. It has also been called '''Ship of Theseus''' pattern, named after [[Ship of Theseus|a philosophical paradox]].<ref>{{ cite web |website=Understand Legacy Code |title=The Ship of Theseus to NOT rewrite a legacy system from scratch |first=Nicolas |last=Carlo |url=https://understandlegacycode.com/blog/ship-of-theseus-avoid-rewrite-legacy-system/}} </ref>
 
The pattern can be used at the [[Method (computer programming)|method]] level or the [[Class (computer programming)|class]] level.<ref>{{Cite book |last=Seemann |first=Mark |title=Code That Fits in Your Head: Heuristics for Software Engineering |publisher=[[Addison-Wesley]] |year=2022 |isbn=978-0-13-746440-1 |pages=228–237}}</ref>