Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mirrors
biopet.biopet
Commits
7d6eb6fb
Commit
7d6eb6fb
authored
Sep 09, 2015
by
Peter van 't Hof
Browse files
Adding more AnyVal for better support for other types
parent
ed7e9588
Changes
1
Hide whitespace changes
Inline
Side-by-side
public/biopet-framework/src/main/scala/nl/lumc/sasc/biopet/utils/VcfUtils.scala
View file @
7d6eb6fb
...
...
@@ -47,7 +47,6 @@ object VcfUtils {
}
/**
* HACK!!
* Stands for scalaListToJavaObjectArrayList
* Convert a scala List[Any] to a java ArrayList[Object]. This is necessary for BCF conversions
* As scala ints and floats cannot be directly cast to java objects (they aren't objects),
...
...
@@ -60,8 +59,13 @@ object VcfUtils {
val
out
=
new
util
.
ArrayList
[
Object
]()
array
.
foreach
{
case
x
:
Long
=>
out
.
add
(
Long
.
box
(
x
))
case
x
:
Int
=>
out
.
add
(
Int
.
box
(
x
))
case
x
:
Char
=>
out
.
add
(
Char
.
box
(
x
))
case
x
:
Byte
=>
out
.
add
(
Byte
.
box
(
x
))
case
x
:
Double
=>
out
.
add
(
Double
.
box
(
x
))
case
x
:
Float
=>
out
.
add
(
Float
.
box
(
x
))
case
x
:
Boolean
=>
out
.
add
(
Boolean
.
box
(
x
))
case
x
:
String
=>
out
.
add
(
x
)
case
x
:
Object
=>
out
.
add
(
x
)
case
x
=>
out
.
add
(
x
.
toString
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment