This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package hudson.plugins.scalabuilder; | |
| import hudson.Extension; | |
| import hudson.model.AbstractDescribableImpl; | |
| import hudson.model.Descriptor; | |
| import hudson.tasks.BuildStepDescriptor; | |
| import hudson.tasks.Builder; | |
| import org.kohsuke.stapler.DataBoundConstructor; | |
| /** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def Expr = (GlobalDirectiveExpr*) ~ (ColumnRuleExpr+) ^^ { | |
| case d ~ r => CsvSchema(d, r) | |
| } | |
| def GlobalDirectiveExpr = "@" ~> (SeparatorExpr | QuotedExpr | TotalColumnsExpr | NoHeaderExpr | IgnoreColumnNameCaseExpr) ^^ { | |
| case d => Directive(d) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def withConnection[T](ds: ComboPooledDataSource, fn : Connection => T) : T = { | |
| var optConn : Option[Connection] = Option.empty; | |
| try { | |
| val conn = ds.getConnection | |
| optConn = Some(conn); | |
| fn(conn) | |
| } finally { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| declare function local:_recurse_depth($element, $count) as xs:integer* | |
| { | |
| if($element[child::element()])then | |
| for $child in $element/child::element() return | |
| local:_recurse_depth($child, $count + 1) | |
| else | |
| $count | |
| }; | |
| declare function local:depth($x as node()?) as xs:integer |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package csvvalidator | |
| import scala.util.parsing.combinator.syntactical.StandardTokenParsers | |
| import scala.io.Source; | |
| /** | |
| * Adam Retter | |
| */ | |
| object TestProblemParser extends StandardTokenParsers { |
NewerOlder