package Ġcom . mk ob it . jenkins . pipelines Ċ Ċ import Ġorg . gradle . api . model . ObjectFactory Ċ import Ġorg . gradle . api . provider . List Property Ċ import Ġorg . gradle . api . provider . Property Ċ import Ġorg . gradle . api . provider . Provider Ċ import Ġorg . gradle . kotlin . dsl . list Property Ċ import Ġjavax . inject . Inject Ċ Ċ /** Ċ Ġ* ĠSpecifies Ġthe ĠJenkins Ġplugin Ġdependencies Ġto Ġinclude . Ċ Ġ* Ġ@ property Ġworkflow Api Plugin Version Ġ[ Pipeline : ĠAPI ]( https :// plugins . jenkins . io / workflow - api ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Basic Steps Plugin Version Ġ[ Pipeline : ĠBasic ĠSteps ]( https :// plugins . jenkins . io / workflow - basic - steps ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow C ps Plugin Version Ġ[ Pipeline : ĠGro ovy ]( https :// plugins . jenkins . io / workflow - cps ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Dur able Task Step Plugin Version Ġ[ Dur able ĠTask ]( https :// plugins . jenkins . io / dur able - task ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow C ps Global Library Plugin Version Ġ[ Pipeline : ĠShared ĠGro ovy ĠLibraries ]( https :// plugins . jenkins . io / workflow - cps - global - lib ) Ċ Ġ* Ġ@ property Ġworkflow Job Plugin Version Ġ[ Pipeline : ĠJob ]( https :// plugins . jenkins . io / workflow - job ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Multi branch Plugin Version Ġ[ Pipeline : ĠMulti branch ]( https :// plugins . jenkins . io / workflow - multi branch ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Sc m Step Plugin Version Ġ[ Pipeline : ĠS CM ĠStep ]( https :// plugins . jenkins . io / workflow - scm - step ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Step Api Plugin Version Ġ[ Pipeline : ĠStep ĠAPI ]( https :// plugins . jenkins . io / workflow - step - api ) Ġplugin Ġversion Ċ Ġ* Ġ@ property Ġworkflow Support Plugin Version Ġ[ Pipeline : ĠSupport ing ĠAPIs ]( https :// plugins . jenkins . io / workflow - support ) Ġplugin Ġversion Ċ Ġ*/ Ċ open Ġclass ĠPlugin Dependency Spec Ġ@ Inject Ġconstructor ( ĊĠ Ġval Ġworkflow Api Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Basic Steps Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow C ps Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Dur able Task Step Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow C ps Global Library Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Job Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Multi branch Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Sc m Step Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Step Api Plugin Version : ĠProperty < String >, ĊĠ Ġval Ġworkflow Support Plugin Version : ĠProperty < String >, ĊĠ Ġprivate Ġval Ġobject Factory : ĠObject Factory Ċ ) Ġ{ ĊĠ Ġ// Ġ. empty () Ġneeded Ġdue Ġto Ġhttps :// github . com / gradle / gradle / issues / 7 4 8 5 ĊĠ Ġprivate Ġval Ġadditional Dependencies : ĠList Property < Plugin Dependency > Ġ= Ġobject Factory . list Property < Plugin Dependency >(). empty () ĊĊĠ Ġ/** ĊĠĠ Ġ* ĠAdds Ġa Ġdependency Ġwith Ġthe Ġprovided Ġcoordinates . ĊĠĠ Ġ* Ġ@ param Ġgroup Ġthe Ġgroup Ġof Ġthe Ġplugin Ġartifact ĊĠĠ Ġ* Ġ@ param Ġname Ġthe Ġname Ġof Ġthe Ġplugin Ġartifact ĊĠĠ Ġ* Ġ@ param Ġversion Ġthe Ġversion Ġof Ġthe Ġplugin Ġto Ġuse ĊĠĠ Ġ*/ ĊĠ Ġfun Ġdependency ( group : ĠString , Ġname : ĠString , Ġversion : ĠString ) Ġ{ ĊĠĠĠ Ġadditional Dependencies . add ( Plugin Dependency ( group , Ġname , Ġversion )) ĊĠ Ġ} ĊĊĠ Ġprivate Ġfun Ġworkflow Api Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Api Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - api :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Basic Steps Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Basic Steps Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - basic - steps :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow C ps Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow C ps Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - cps :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Dur able Task Step Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Dur able Task Step Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - dur able - task - step :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Global C ps Library Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow C ps Global Library Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - cps - global - lib :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Job Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Job Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - job :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Multi branch Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Multi branch Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - multi branch :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Sc m Step Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Sc m Step Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - scm - step :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Step Api Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Step Api Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - step - api :$ it " Ġ} ĊĠ Ġprivate Ġfun Ġworkflow Support Plugin Dependency (): ĠProvider < String > Ġ= ĊĠĠĠ Ġworkflow Support Plugin Version . map Ġ{ Ġ" org . jenkins - ci . plugins . workflow : workflow - support :$ it " Ġ} ĊĊĠ Ġfun Ġplugin Dependencies (): ĠList Property < Plugin Dependency > Ġ{ ĊĠĠĠ Ġ// Ġ. empty () Ġneeded Ġdue Ġto Ġhttps :// github . com / gradle / gradle / issues / 7 4 8 5 ĊĠĠĠ Ġval Ġdependencies : ĠList Property < Plugin Dependency > Ġ= Ġobject Factory . list Property < Plugin Dependency >(). empty () ĊĠĠĠ Ġdependencies . addAll ( additional Dependencies ) ĊĠĠĠ ĠlistOf ( ĊĠĠĠĠĠ Ġworkflow Api Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Basic Steps Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow C ps Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Dur able Task Step Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Global C ps Library Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Job Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Multi branch Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Sc m Step Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Step Api Plugin Dependency (), ĊĠĠĠĠĠ Ġworkflow Support Plugin Dependency () ĊĠĠĠ Ġ). map Ġ{ Ġprovider Ġ-> ĊĠĠĠĠĠ Ġprovider . map Ġ{ ĠPlugin Dependency . fromString ( it ) Ġ} ĊĠĠĠ Ġ}. forEach Ġ{ Ġdependencies . add ( it ) Ġ} ĊĊĠĠĠ Ġreturn Ġdependencies ĊĠ Ġ} Ċ } Ċ