Commit aaf435ff authored by Andy Wilkinson's avatar Andy Wilkinson

Suppress Neo4J-related deprecation warnings

See gh-6976
parent bdc949d1
...@@ -45,6 +45,7 @@ import org.springframework.data.neo4j.template.Neo4jOperations; ...@@ -45,6 +45,7 @@ import org.springframework.data.neo4j.template.Neo4jOperations;
* @author Stephane Nicoll * @author Stephane Nicoll
* @since 1.4.0 * @since 1.4.0
*/ */
@SuppressWarnings("deprecation")
@Configuration @Configuration
@ConditionalOnClass({ Neo4jSession.class, Neo4jOperations.class }) @ConditionalOnClass({ Neo4jSession.class, Neo4jOperations.class })
@ConditionalOnMissingBean(Neo4jOperations.class) @ConditionalOnMissingBean(Neo4jOperations.class)
......
...@@ -52,6 +52,7 @@ import org.springframework.data.neo4j.repository.support.GraphRepositoryFactoryB ...@@ -52,6 +52,7 @@ import org.springframework.data.neo4j.repository.support.GraphRepositoryFactoryB
* @since 1.4.0 * @since 1.4.0
* @see EnableNeo4jRepositories * @see EnableNeo4jRepositories
*/ */
@SuppressWarnings("deprecation")
@Configuration @Configuration
@ConditionalOnClass({ Neo4jSession.class, GraphRepository.class }) @ConditionalOnClass({ Neo4jSession.class, GraphRepository.class })
@ConditionalOnMissingBean({ GraphRepositoryFactoryBean.class, @ConditionalOnMissingBean({ GraphRepositoryFactoryBean.class,
......
...@@ -30,6 +30,7 @@ import org.springframework.data.repository.config.RepositoryConfigurationExtensi ...@@ -30,6 +30,7 @@ import org.springframework.data.repository.config.RepositoryConfigurationExtensi
* *
* @author Michael Hunger * @author Michael Hunger
*/ */
@SuppressWarnings("deprecation")
class Neo4jRepositoriesAutoConfigureRegistrar class Neo4jRepositoriesAutoConfigureRegistrar
extends AbstractRepositoryConfigurationSourceSupport { extends AbstractRepositoryConfigurationSourceSupport {
......
...@@ -19,6 +19,7 @@ package org.springframework.boot.autoconfigure.data.alt.neo4j; ...@@ -19,6 +19,7 @@ package org.springframework.boot.autoconfigure.data.alt.neo4j;
import org.springframework.boot.autoconfigure.data.neo4j.city.City; import org.springframework.boot.autoconfigure.data.neo4j.city.City;
import org.springframework.data.neo4j.repository.GraphRepository; import org.springframework.data.neo4j.repository.GraphRepository;
@SuppressWarnings("deprecation")
public interface CityNeo4jRepository extends GraphRepository<City> { public interface CityNeo4jRepository extends GraphRepository<City> {
} }
...@@ -53,6 +53,7 @@ import static org.assertj.core.api.Assertions.assertThat; ...@@ -53,6 +53,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Vince Bickers * @author Vince Bickers
* @author Stephane Nicoll * @author Stephane Nicoll
*/ */
@SuppressWarnings("deprecation")
public class MixedNeo4jRepositoriesAutoConfigurationTests { public class MixedNeo4jRepositoriesAutoConfigurationTests {
private AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(); private AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext();
......
...@@ -44,6 +44,7 @@ import static org.mockito.Mockito.mock; ...@@ -44,6 +44,7 @@ import static org.mockito.Mockito.mock;
* @author Michael Hunger * @author Michael Hunger
* @author Vince Bickers * @author Vince Bickers
*/ */
@SuppressWarnings("deprecation")
public class Neo4jDataAutoConfigurationTests { public class Neo4jDataAutoConfigurationTests {
private AnnotationConfigApplicationContext context; private AnnotationConfigApplicationContext context;
......
...@@ -44,6 +44,7 @@ import static org.assertj.core.api.Assertions.assertThat; ...@@ -44,6 +44,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* @author Vince Bickers * @author Vince Bickers
* @author Stephane Nicoll * @author Stephane Nicoll
*/ */
@SuppressWarnings("deprecation")
public class Neo4jRepositoriesAutoConfigurationTests { public class Neo4jRepositoriesAutoConfigurationTests {
private AnnotationConfigApplicationContext context; private AnnotationConfigApplicationContext context;
......
...@@ -20,8 +20,10 @@ import org.springframework.data.domain.Page; ...@@ -20,8 +20,10 @@ import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Pageable;
import org.springframework.data.neo4j.repository.GraphRepository; import org.springframework.data.neo4j.repository.GraphRepository;
@SuppressWarnings("deprecation")
public interface CityRepository extends GraphRepository<City> { public interface CityRepository extends GraphRepository<City> {
@Override
Page<City> findAll(Pageable pageable); Page<City> findAll(Pageable pageable);
} }
...@@ -18,6 +18,7 @@ package org.springframework.boot.autoconfigure.data.neo4j.country; ...@@ -18,6 +18,7 @@ package org.springframework.boot.autoconfigure.data.neo4j.country;
import org.springframework.data.neo4j.repository.GraphRepository; import org.springframework.data.neo4j.repository.GraphRepository;
@SuppressWarnings("deprecation")
public interface CountryRepository extends GraphRepository<Country> { public interface CountryRepository extends GraphRepository<Country> {
} }
...@@ -20,6 +20,7 @@ import java.util.List; ...@@ -20,6 +20,7 @@ import java.util.List;
import org.springframework.data.neo4j.repository.GraphRepository; import org.springframework.data.neo4j.repository.GraphRepository;
@SuppressWarnings("deprecation")
public interface CustomerRepository extends GraphRepository<Customer> { public interface CustomerRepository extends GraphRepository<Customer> {
public Customer findByFirstName(String firstName); public Customer findByFirstName(String firstName);
......
...@@ -27,6 +27,7 @@ public class SampleNeo4jApplication implements CommandLineRunner { ...@@ -27,6 +27,7 @@ public class SampleNeo4jApplication implements CommandLineRunner {
@Autowired @Autowired
private CustomerRepository repository; private CustomerRepository repository;
@SuppressWarnings("deprecation")
@Override @Override
public void run(String... args) throws Exception { public void run(String... args) throws Exception {
this.repository.deleteAll(); this.repository.deleteAll();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment