collection lambdas added

This commit is contained in:
Kroczek Christoph (TT-RHC/ESC6)
2019-07-15 10:56:22 +02:00
parent d8791e7fc8
commit ca8950238d
6 changed files with 96 additions and 1 deletions

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>001_sequential_migration</name>
<name>sequential_migration</name>
<comment>Project 001_sequential_migration created by Buildship.</comment>
<projects>
</projects>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>collections</name>
<comment>Project collections created by Buildship.</comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.buildship.core.gradleprojectbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.buildship.core.gradleprojectnature</nature>
</natures>
</projectDescription>

View File

@@ -0,0 +1,33 @@
/*
* This file was generated by the Gradle 'init' task.
*
* This generated file contains a sample Java project to get you started.
* For more details take a look at the Java Quickstart chapter in the Gradle
* user guide available at https://docs.gradle.org/4.9/userguide/tutorial_java_projects.html
*/
plugins {
// Apply the java plugin to add support for Java
id 'java'
// Apply the application plugin to add support for building an application
id 'application'
}
// Define the main class for the application
mainClassName = 'App'
dependencies {
// This dependency is found on compile classpath of this component and consumers.
// compile 'com.google.guava:guava:23.0'
// Use JUnit test framework
testCompile 'junit:junit:4.12'
}
// In this section you declare where to find the dependencies of your project
repositories {
// Use jcenter for resolving your dependencies.
// You can declare any Maven/Ivy/file repository here.
jcenter()
}

View File

@@ -0,0 +1,10 @@
/*
* This file was generated by the Gradle 'init' task.
*
* The settings file is used to specify which projects to include in your build.
*
* Detailed information about configuring a multi-project build in Gradle can be found
* in the user guide at https://docs.gradle.org/4.9/userguide/multi_project_builds.html
*/
rootProject.name = 'collections'

View File

@@ -0,0 +1,17 @@
import java.util.HashMap;
import java.util.Map;
/*
* This Java source file was generated by the Gradle 'init' task.
*/
public class App {
public static void main(String[] args) {
Map<String, Integer> testlist = new HashMap<String, Integer>();
testlist.put("one", 1);
testlist.put("two", 2);
testlist.put("three", 3);
testlist.forEach((k, v) -> System.out.println(k + ":" + v));
}
}

View File

@@ -0,0 +1,12 @@
/*
* This Java source file was generated by the Gradle 'init' task.
*/
import org.junit.Test;
import static org.junit.Assert.*;
public class AppTest {
@Test public void testAppHasAGreeting() {
App classUnderTest = new App();
assertNotNull("app should have a greeting", classUnderTest.getGreeting());
}
}