// Path: src/test/java/org/apache/flink/embedded/neo4j/Neo4JBaseEmbeddedConfig.java
// public class Neo4JBaseEmbeddedConfig {
// 
// 	public static final String DEFAULT_URL = "bolt://localhost:7687";
// 
// 	public static final String DEFAULT_USERNAME = "neo4j";
// 
// 	public static final String DEFAULT_PASSWORD = "password";
// 	
// 	@ClassRule
// 	public static Neo4jRule neo4jRule;
// 	
// 	public static Neo4JDriverWrapper driverWrapper;
// 	
// 	public static Map<String, String> neo4JConfig;
// 
// 	static {
// 		neo4jRule = new Neo4jRule().withFixture("create (i:Item {description:'an item'})");
// 	}
// 
// 	@Before
// 	public void init() {
// 		neo4JConfig = new HashMap<String, String>();
// 		neo4JConfig.put(Neo4JDriverWrapper.URL, neo4jRule.boltURI().toString());
// 		neo4JConfig.put(Neo4JDriverWrapper.USERNAME_PARAM, "neo4j");
// 		neo4JConfig.put(Neo4JDriverWrapper.PASSWORD_PARAM, "password");
// 		neo4JConfig.put(Neo4JDriverWrapper.SESSION_LIVENESS_TIMEOUT, "4000");
// 		
// 		driverWrapper = new Neo4JDriverWrapper(neo4JConfig);
// 	}
// }
// 
// Path: src/main/java/org/apache/flink/mapping/neo4j/Neo4JSerializationMappingStrategy.java
// public class Neo4JSerializationMappingStrategy<T, M extends SerializationMapper<T>> implements Serializable {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	/**
// 	 * The templated cypher query that will be executed on Neo4J
// 	 */
// 	private String templateStatement;
// 
// 	/**
// 	 * 
// 	 */
// 	private M mapper;
// 
// 	/**
// 	 * 
// 	 * @param templateStatement the cypher statement template
// 	 * @param mapper an actual SerializationMapper implementation
// 	 */
// 	public Neo4JSerializationMappingStrategy(final String templateStatement, M mapper) {
// 		this.templateStatement = templateStatement;
// 		this.mapper = mapper;
// 	}
// 
// 	/**
// 	 * 
// 	 * @return the cypher statement template
// 	 */
// 	public Statement getStatement() {
// 		return new Statement(templateStatement);
// 	}
// 
// 	/**
// 	 * Maps a single result record into a T object
// 	 * 
// 	 * @param record a record that will be returned by the cypher query
// 	 * @return an object of type T
// 	 */
// 	public T map(Record record) {
// 		return this.mapper.serialize(record.asMap());
// 	}
// }
// 
// Path: src/test/java/org/apache/flink/mapping/neo4j/Neo4JSourceMappingStrategyString.java
// public class Neo4JSourceMappingStrategyString extends Neo4JSerializationMappingStrategy<String, SerializationMapper<String>> {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	public Neo4JSourceMappingStrategyString(String templateStatement, SerializationMapper<String> mapper) {
// 		super(templateStatement, mapper);
// 	}
// }
// 
// Path: src/main/java/org/apache/flink/mapping/neo4j/SerializationMapper.java
// @FunctionalInterface
// public interface SerializationMapper<T> extends Mapper {
// 
// 	/**
// 	 * Convert a record (that is returned by the cypher query) into an object of
// 	 * type T.
// 	 * 
// 	 * Tips: Maybe record should be of type org.neo4j.driver.v1.Record
// 	 * 
// 	 * @param record
// 	 *            a record (as a Map) that will be returned by the cypher query
// 	 * @return an item of type T that is a transformation of a record into an
// 	 *         item T
// 	 */
// 	public T serialize(Map<String, Object> record);
// }
// 
// Path: src/test/java/org/apache/flink/mapping/neo4j/StringSerializationMapper.java
// public class StringSerializationMapper implements SerializationMapper<String> {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	@Override
// 	public String serialize(Map<String, Object> record) {
// 		return record.get("i.description").toString();
// 	}
// }


import java.util.List;
import org.apache.flink.api.common.typeinfo.BasicTypeInfo;
import org.apache.flink.api.java.io.LocalCollectionOutputFormat;
import org.apache.flink.embedded.neo4j.Neo4JBaseEmbeddedConfig;
import org.apache.flink.hadoop.shaded.com.google.common.collect.Lists;
import org.apache.flink.mapping.neo4j.Neo4JSerializationMappingStrategy;
import org.apache.flink.mapping.neo4j.Neo4JSourceMappingStrategyString;
import org.apache.flink.mapping.neo4j.SerializationMapper;
import org.apache.flink.mapping.neo4j.StringSerializationMapper;
import org.apache.flink.streaming.api.datastream.DataStreamSource;
import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment;
import org.junit.Assert;
import org.junit.Test;
package org.apache.flink.streaming.connectors.neo4j;



public class Neo4JSourceTest extends Neo4JBaseEmbeddedConfig {

	@Test
	public void testSource() throws Exception {
		StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();

// Path: src/test/java/org/apache/flink/embedded/neo4j/Neo4JBaseEmbeddedConfig.java
// public class Neo4JBaseEmbeddedConfig {
// 
// 	public static final String DEFAULT_URL = "bolt://localhost:7687";
// 
// 	public static final String DEFAULT_USERNAME = "neo4j";
// 
// 	public static final String DEFAULT_PASSWORD = "password";
// 	
// 	@ClassRule
// 	public static Neo4jRule neo4jRule;
// 	
// 	public static Neo4JDriverWrapper driverWrapper;
// 	
// 	public static Map<String, String> neo4JConfig;
// 
// 	static {
// 		neo4jRule = new Neo4jRule().withFixture("create (i:Item {description:'an item'})");
// 	}
// 
// 	@Before
// 	public void init() {
// 		neo4JConfig = new HashMap<String, String>();
// 		neo4JConfig.put(Neo4JDriverWrapper.URL, neo4jRule.boltURI().toString());
// 		neo4JConfig.put(Neo4JDriverWrapper.USERNAME_PARAM, "neo4j");
// 		neo4JConfig.put(Neo4JDriverWrapper.PASSWORD_PARAM, "password");
// 		neo4JConfig.put(Neo4JDriverWrapper.SESSION_LIVENESS_TIMEOUT, "4000");
// 		
// 		driverWrapper = new Neo4JDriverWrapper(neo4JConfig);
// 	}
// }
// 
// Path: src/main/java/org/apache/flink/mapping/neo4j/Neo4JSerializationMappingStrategy.java
// public class Neo4JSerializationMappingStrategy<T, M extends SerializationMapper<T>> implements Serializable {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	/**
// 	 * The templated cypher query that will be executed on Neo4J
// 	 */
// 	private String templateStatement;
// 
// 	/**
// 	 * 
// 	 */
// 	private M mapper;
// 
// 	/**
// 	 * 
// 	 * @param templateStatement the cypher statement template
// 	 * @param mapper an actual SerializationMapper implementation
// 	 */
// 	public Neo4JSerializationMappingStrategy(final String templateStatement, M mapper) {
// 		this.templateStatement = templateStatement;
// 		this.mapper = mapper;
// 	}
// 
// 	/**
// 	 * 
// 	 * @return the cypher statement template
// 	 */
// 	public Statement getStatement() {
// 		return new Statement(templateStatement);
// 	}
// 
// 	/**
// 	 * Maps a single result record into a T object
// 	 * 
// 	 * @param record a record that will be returned by the cypher query
// 	 * @return an object of type T
// 	 */
// 	public T map(Record record) {
// 		return this.mapper.serialize(record.asMap());
// 	}
// }
// 
// Path: src/test/java/org/apache/flink/mapping/neo4j/Neo4JSourceMappingStrategyString.java
// public class Neo4JSourceMappingStrategyString extends Neo4JSerializationMappingStrategy<String, SerializationMapper<String>> {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	public Neo4JSourceMappingStrategyString(String templateStatement, SerializationMapper<String> mapper) {
// 		super(templateStatement, mapper);
// 	}
// }
// 
// Path: src/main/java/org/apache/flink/mapping/neo4j/SerializationMapper.java
// @FunctionalInterface
// public interface SerializationMapper<T> extends Mapper {
// 
// 	/**
// 	 * Convert a record (that is returned by the cypher query) into an object of
// 	 * type T.
// 	 * 
// 	 * Tips: Maybe record should be of type org.neo4j.driver.v1.Record
// 	 * 
// 	 * @param record
// 	 *            a record (as a Map) that will be returned by the cypher query
// 	 * @return an item of type T that is a transformation of a record into an
// 	 *         item T
// 	 */
// 	public T serialize(Map<String, Object> record);
// }
// 
// Path: src/test/java/org/apache/flink/mapping/neo4j/StringSerializationMapper.java
// public class StringSerializationMapper implements SerializationMapper<String> {
// 
// 	private static final long serialVersionUID = 1L;
// 
// 	@Override
// 	public String serialize(Map<String, Object> record) {
// 		return record.get("i.description").toString();
// 	}
// }


// Path: src/test/java/org/apache/flink/streaming/connectors/neo4j/Neo4JSourceTest.java
import java.util.List;
import org.apache.flink.api.common.typeinfo.BasicTypeInfo;
import org.apache.flink.api.java.io.LocalCollectionOutputFormat;
import org.apache.flink.embedded.neo4j.Neo4JBaseEmbeddedConfig;
import org.apache.flink.hadoop.shaded.com.google.common.collect.Lists;
import org.apache.flink.mapping.neo4j.Neo4JSerializationMappingStrategy;
import org.apache.flink.mapping.neo4j.Neo4JSourceMappingStrategyString;
import org.apache.flink.mapping.neo4j.SerializationMapper;
import org.apache.flink.mapping.neo4j.StringSerializationMapper;
import org.apache.flink.streaming.api.datastream.DataStreamSource;
import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment;
import org.junit.Assert;
import org.junit.Test;

package org.apache.flink.streaming.connectors.neo4j;



public class Neo4JSourceTest extends Neo4JBaseEmbeddedConfig {

	@Test
	public void testSource() throws Exception {
		StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();

		SerializationMapper<String> serializationMapper = new StringSerializationMapper();