Scala is a general purpose programming language principally targeting the Java Virtual Machine. Designed to express common programming patterns in a concise, elegant, and type-safe way, it fuses both imperative and functional programming styles. Its key features are: statically typed; advanced ...

learn more… | top users | synonyms

0
votes
2answers
31 views

Is it possible to do that in Scala (no mutating the internal state of a class)?

Let's say, there is a class called RemoteIdGetter. It returns a key from a server. But it only makes a request to the server if the key is not "fresh" enough, meaning the last time it's been ...
0
votes
0answers
35 views

Play framework if else case Not working

Play framework if else case is not working here If userprofile.useraccountid, useraccount.id have the same value then not views that id user on view page my code in the view.. @(userprofiles: ...
0
votes
1answer
38 views

How to convert String to date time in Scala?

I am new to Scala and I've learned it for the last few days. I have a doubt about Scala's date converting from string. How to convert String to Date and time using Scala ? Does it work the same way ...
0
votes
0answers
17 views

in play framework how to display image in image path from database

i know how to display images in view page on static, but i am really confused about, display image in view page by image path from database.. the image path is saved in the database using the ...
0
votes
1answer
26 views

Can't get the id in play framework scala program

Here is my view page and here not get the id.. @(userprofiles: List[UserProfile], myFriend: models.MyFriend, userprofile: models.UserProfile) @helper.form(action = routes.Application.listMyFriend) ...
0
votes
0answers
23 views

IntelliJ Idea 12 worksheet + sbt + Scala — error

When I run a worksheet in IntelliJ Idea 12 (sbt plugin, Scala project), I've got an error of: > Failed to initialize compiler: class scala.reflect.BeanInfo not found. ** Note that as of 2.8 ...
1
vote
1answer
65 views

Is there a way I can write this Haskell code in Scala?

I'm going through a few functional programming languages, learning things of interest, and I'm looking at Scala now. What I'm trying to do is figure out the simplest way to write a function called ...
0
votes
1answer
52 views

Scala List performance

Does anyone know of a source for performance characteristics on the "contains" method within the different flavors of Scala Lists? The scala language docs cover the primary operations like head, tail, ...
1
vote
1answer
32 views

Dynamic HTML ID with Bootstrap, Play framework and Scala templates

I'm working on an application with Bootstrap and Play 2 using Scala templates. I want to enumerate the ID of every row of jobs so that each row will map to a corresponding collapsed row that show more ...
1
vote
0answers
12 views

How to update a mongo record using Rogue with MongoCaseClassField when case class contains a scala Enumeration

I am upgrading existing code from Rogue 1.1.8 to 2.0.0 and lift-mongodb-record from 2.4-M5 to 2.5. I'm having difficulty writing MongoCaseClassField that contains a scala enum, that I really could ...
0
votes
1answer
39 views

my combinations function returns an empty list

I am working on S-99: Ninety-Nine Scala Problems and already stuck at question 26. Generate the combinations of K distinct objects chosen from the N elements of a list. After wasting a couple hours, I ...
1
vote
1answer
35 views

Abstract reflection API in Scala 2.10

Scala 2.10 comes with a great reflection API. There are two entry points to it, however: runtime universe and macro context universe. When using runtime reflection, you should import ...
1
vote
3answers
64 views

Main method is not called in Scala script

I am brand new to Scala, and I was wondering why the main method is not running in this script? class Word { } object HelloWorld { def main(args: Array[String]) { println("Hello, world!") } ...
2
votes
1answer
41 views

Infer generic types on scala shell

Is it possible to use the scala shell to infer the type of a generic function? I was trying to undestand the type of the function Future.traverse (scala 2.10). The complete generic type is def ...
0
votes
2answers
42 views

Scala - No TypeTag Available Exception when using case class to try to get TypeTag?

I'm looking at the scala reflect API and I'm getting lots of exceptions. Doc reference: http://docs.scala-lang.org/overviews/reflection/environment-universes-mirrors.html How do I get the typetag ...

1 2 3 4 5 1083
15 30 50 per page