paymenthighway / sbt-cxf   1.7

Apache License 2.0 GitHub

Yet another sbt-cxf plugin for SBT

Scala versions: 2.12 2.10
sbt plugins: 1.0 0.13

sbt-cxf

sbt-cxf is a plugin for SBT that will generate java-classes for web-service WSDLs using Apache CXF. Find out more about Apache CXF.

How to use

Add the plugin in project/plugins.sbt:

resolvers ++= Seq(
  "Sonatype OSS Releases" at "http://oss.sonatype.org/content/repositories/releases/",
  "Sonatype OSS Snapshots" at "http://oss.sonatype.org/content/repositories/snapshots/"
)

addSbtPlugin("io.paymenthighway.sbt" % "sbt-cxf" % "1.6")

Add WSDL file (example HelloWorld.wsdl) to wsdl subdirectory under resources directory

Add the plugin configuration in build.sbt:

enablePlugins(CxfPlugin)

val CxfVersion = "3.3.3"

version in CXF := CxfVersion

cxfDefaultArgs := Seq("-exsh", "true", "-validate") // If this is acceptable, this can be omitted

cxfWSDLs := Seq(
  Wsdl("HelloWorld", (resourceDirectory in Compile).value / "wsdl/HelloWorld.wsdl", Nil)
)