-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Expand file tree
/
Copy pathSoftInterventionDisplayTypeMarshaller.scala
More file actions
24 lines (21 loc) · 1.24 KB
/
Copy pathSoftInterventionDisplayTypeMarshaller.scala
File metadata and controls
24 lines (21 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package com.twitter.product_mixer.core.functional_component.marshaller.response.urt.item.forward_pivot
import com.twitter.product_mixer.core.model.marshalling.response.urt.item.forward_pivot.GetTheLatest
import com.twitter.product_mixer.core.model.marshalling.response.urt.item.forward_pivot.GovernmentRequested
import com.twitter.product_mixer.core.model.marshalling.response.urt.item.forward_pivot.Misleading
import com.twitter.product_mixer.core.model.marshalling.response.urt.item.forward_pivot.SoftInterventionDisplayType
import com.twitter.product_mixer.core.model.marshalling.response.urt.item.forward_pivot.StayInformed
import com.twitter.timelines.render.{thriftscala => urt}
import javax.inject.Inject
import javax.inject.Singleton
@Singleton
class SoftInterventionDisplayTypeMarshaller @Inject() () {
def apply(
softInterventionDisplayType: SoftInterventionDisplayType
): urt.SoftInterventionDisplayType =
softInterventionDisplayType match {
case GetTheLatest => urt.SoftInterventionDisplayType.GetTheLatest
case StayInformed => urt.SoftInterventionDisplayType.StayInformed
case Misleading => urt.SoftInterventionDisplayType.Misleading
case GovernmentRequested => urt.SoftInterventionDisplayType.GovernmentRequested
}
}