Skip to content

Commit

Permalink
Merge 80a0288 into 989b5c5
Browse files Browse the repository at this point in the history
  • Loading branch information
anelson committed Jun 6, 2016
2 parents 989b5c5 + 80a0288 commit ec40520
Showing 1 changed file with 44 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,47 @@ object `AWS::Lambda::EventSourceMapping` extends DefaultJsonProtocol {
implicit val format: JsonFormat[`AWS::Lambda::EventSourceMapping`] = jsonFormat7(`AWS::Lambda::EventSourceMapping`.apply)
}

case class `AWS::Lambda::Version`(name: String,
FunctionName: Token[ResourceRef[`AWS::Lambda::Function`]],
Description: Option[String] = None,
CodeSha256: Option[Token[String]] = None,
override val Condition: Option[ConditionRef] = None)
extends Resource[`AWS::Lambda::Version`]
with HasArn {

override def arn = `Fn::GetAtt`(Seq(name, "Arn"))

def version = `Fn::GetAtt`(Seq(name, "Version"))

def when(newCondition: Option[ConditionRef] = Condition) = copy(Condition = newCondition)
}

object `AWS::Lambda::Version` extends DefaultJsonProtocol {
implicit val format: JsonFormat[`AWS::Lambda::Version`] = jsonFormat5(
`AWS::Lambda::Version`.apply)
}

case class `AWS::Lambda::Alias`(name: String,
AliasName: Token[String],
FunctionName: Token[ResourceRef[`AWS::Lambda::Function`]],
FunctionVersion: Token[String],
Description: Option[Token[String]] = None,
override val Condition: Option[ConditionRef] = None)
extends Resource[`AWS::Lambda::Alias`]
with HasArn {

override def arn = `Fn::GetAtt`(Seq(name, "Arn"))

def when(newCondition: Option[ConditionRef] = Condition) = copy(Condition = newCondition)
}

object `AWS::Lambda::Alias` extends DefaultJsonProtocol {
//implicit val format: JsonFormat[`AWS::Lambda::Alias`] = jsonFormat6(`AWS::Lambda::Alias`.apply)
implicit val format: JsonFormat[`AWS::Lambda::Alias`] = jsonFormat(`AWS::Lambda::Alias`.apply,
"name",
"Name",
"FunctionName",
"FunctionVersion",
"Description",
"Condition")
}

0 comments on commit ec40520

Please sign in to comment.