Linked Questions
17 questions linked to/from Java "lambda expressions not supported at this language level"
1
vote
1
answer
14k
views
Lambda expressions are not supported at this language level [duplicate]
I have a Java class that uses Spark. I need to filter out the header from JavaRDD. This is how I want to do this.
String first = data.first();
JavaRDD<String> filteredData = data.filter((String ...
-1
votes
1
answer
55
views
Created app using GridView with ViewPager error: lambda expressions are not supported in -source 1.7(use -source 8 or higher [duplicate]
I have created android app using GridView with ViewPager for images like gallery or small book which have 14 images
in my main activity showing error :- error: lambda expressions are not supported in ...
254
votes
8
answers
244k
views
Use URI builder in Android or create URL with variables
I'm developing an Android app. I need to build a URI for my app to make an API request. Unless there's another way to put a variable in a URI, this is the easiest way I've found. I found that you need ...
264
votes
5
answers
346k
views
How do you specify the Java compiler version in a pom.xml file?
I wrote some Maven code in Netbeans that has approximately more than 2000 lines. When I compile it on Netbeans, everything is fine, but if I want to run it on command line, I will get these errors:
...
MTT's user avatar
- 5,303
4
votes
3
answers
6k
views
intellij with Android SDK : lambda expressions are not supported in -source 1.7
Good day all
I know there are various questions on this issue, and I have visited quite a number of them, however they do not provide any "solution".
The general answer is to set the Language level ...
2
votes
4
answers
622
views
Trying to do a minor refactor using lambdas in Java
I am working on part of a program (concerning speech recognition and a remote control car), where the code transmit(XXXXX); disableAutoMode(); is repeated many times. For curiosity's sake I would like ...
2
votes
1
answer
637
views
Android Studio doesn't show suggestion for lambda expression
I have added Java 8 compileOptions in app module
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
I also have checked "...
1
vote
1
answer
3k
views
How do I use Java 8 features in Eclipse Luna?
I've installed JDK 8. I set my JAVA_HOME to the JDK 8 directory. I downloaded the latest Eclipse Luna. I checked for updates. I set my default (and only) Installed JRE to the JDK 8 directory.
I ...
0
votes
1
answer
2k
views
How to use a ViewModel to save a bitmap correctly?
In the official android documentation, on how to implement a ViewModel, there is this method:
private void loadUsers() {
// Do an asynchronous operation to fetch users.
}
In my case I don'...
0
votes
1
answer
855
views
Chess Border around Pawns JavaFX
I am creating a chess game and i am stuck at one thing for a couple of days.
So i want to create event when user moves over a figure the image of figure replaces to another image with border and when ...
2
votes
0
answers
663
views
How to set language level for a Cordova plugin in Android Studio?
I have found various questions about language lvl but none resolves my problem.
I am developing a Cordova plugin and I want to use annotation. The project was generated by cordova build, I have never ...
1
vote
1
answer
635
views
LibGDX: Is it possible to draw a BitmapFont and update it?
What I try to make is:
Draw a BitmapFont on the top of the screen and let it go down to the bottom, where it gets deleted.
While that BitmapFont is still making its way down, draw another BitmapFont ...
-1
votes
1
answer
366
views
Why source is 1.6 if I'm using 1.8 [duplicate]
Like in the title, I'm trying to compile lambda, I'm using 1.8 jdk, and have no idea.
Error log here:
Proof that I really got 1.8:
part1:
part2:
Any ideas why I've got problem like this, lambda ...
2
votes
1
answer
482
views
Undefined step reference InteliJ + Cucumber for Java + Maven project
I am having problems with defining the step and mapping it to the scenario.
I have installed maven, set up the dependencies for java, and installed cucumber for java plugin altogether with external ...
0
votes
2
answers
165
views
setDuration not working in Animation class
I'm trying to animate the height of a ConstraintLayout using the Animation class, and the setDuration method doesn't seem to be working. The height is just instantly changed to the desired height ...