Reusable Injection code

Hi,

I am trying to write a reusable Inject function with scenario and Injection steps as arguments. Below is the sample code:

def Inject(scn: ScenarioBuilder, injectionSteps: Map[String, FiniteDuration]): PopulationBuilder ={
// var injectStepList = new ArrayOpenInjectionStep
scn.inject(
for ((k,v) ← injectionSteps) {
k match{
case “nothingFor” => nothingFor(injectionSteps.get(k).asInstanceOf[FiniteDuration])
}

}

I am not sure how to acheive this. Need help.

Thanks,
Girish
//rampUsers(10) during (60 seconds)

)

}