diff options
author | Vitaly Takmazov | 2017-03-04 07:31:18 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2017-03-04 07:31:18 +0300 |
commit | 1a31521dd4e1f7ef96c9d82d69b3d7aa42282eeb (patch) | |
tree | 69d935e3ca7036a8df769cbdf94f9decf65d1b62 /juick-server/src/main | |
parent | c2d7eadf75c27854f8ad12a6dfce82fa900b0f3e (diff) |
cleanup deprecation warnings
Diffstat (limited to 'juick-server/src/main')
7 files changed, 14 insertions, 14 deletions
diff --git a/juick-server/src/main/java/com/juick/database/MySqlUpdater.java b/juick-server/src/main/java/com/juick/database/MySqlUpdater.java index c087ee29..2027d9f1 100644 --- a/juick-server/src/main/java/com/juick/database/MySqlUpdater.java +++ b/juick-server/src/main/java/com/juick/database/MySqlUpdater.java @@ -36,9 +36,9 @@ public class MySqlUpdater { public MySqlUpdater(JdbcTemplate jdbcTemplate, PlatformTransactionManager transactionManager, String updateSqlResource) { - Assert.notNull(jdbcTemplate); - Assert.notNull(transactionManager); - Assert.notNull(updateSqlResource); + Assert.notNull(jdbcTemplate, "JdbcTemplate must be initialized"); + Assert.notNull(transactionManager, "PlatformTransactionManager must be initialized"); + Assert.notNull(updateSqlResource, "sqlResource must be initialized"); this.jdbcTemplate = jdbcTemplate; this.transactionTemplate = new TransactionTemplate(transactionManager); diff --git a/juick-server/src/main/java/com/juick/service/BaseJdbcService.java b/juick-server/src/main/java/com/juick/service/BaseJdbcService.java index fe544efe..e3784345 100644 --- a/juick-server/src/main/java/com/juick/service/BaseJdbcService.java +++ b/juick-server/src/main/java/com/juick/service/BaseJdbcService.java @@ -22,7 +22,7 @@ public abstract class BaseJdbcService { protected BaseJdbcService(JdbcTemplate jdbcTemplate, PlatformTransactionManager transactionManager) { - Assert.notNull(jdbcTemplate); + Assert.notNull(jdbcTemplate, "JdbcTemplate must be initialized"); this.jdbcTemplate = jdbcTemplate; this.namedParameterJdbcTemplate = new NamedParameterJdbcTemplate(jdbcTemplate); @@ -32,7 +32,7 @@ public abstract class BaseJdbcService { } protected BaseJdbcService(DataSource dataSource, PlatformTransactionManager transactionManager) { - Assert.notNull(dataSource); + Assert.notNull(dataSource, "DataSource must be initialized"); this.jdbcTemplate = new JdbcTemplate(dataSource); this.namedParameterJdbcTemplate = new NamedParameterJdbcTemplate(jdbcTemplate); diff --git a/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java b/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java index a19878d9..495940f6 100644 --- a/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java +++ b/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java @@ -37,10 +37,10 @@ public class MessagesServiceImpl extends BaseJdbcService implements MessagesServ public MessagesServiceImpl(JdbcTemplate jdbcTemplate, UserService userService, SearchService searchService) { super(jdbcTemplate, null); - Assert.notNull(userService); + Assert.notNull(userService, "UserService must be initialized"); this.userService = userService; - Assert.notNull(searchService); + Assert.notNull(searchService, "SearchService must be initialized"); this.searchService = searchService; } diff --git a/juick-server/src/main/java/com/juick/service/SubscriptionServiceImpl.java b/juick-server/src/main/java/com/juick/service/SubscriptionServiceImpl.java index ae4af9df..d1eef338 100644 --- a/juick-server/src/main/java/com/juick/service/SubscriptionServiceImpl.java +++ b/juick-server/src/main/java/com/juick/service/SubscriptionServiceImpl.java @@ -31,13 +31,13 @@ public class SubscriptionServiceImpl extends BaseJdbcService implements Subscrip MessagesService messagesService, TagService tagService) { super(jdbcTemplate, null); - Assert.notNull(userService); + Assert.notNull(userService, "UserService must be initialized"); this.userService = userService; - Assert.notNull(messagesService); + Assert.notNull(messagesService,"MessagesService must be initialized"); this.messagesService = messagesService; - Assert.notNull(tagService); + Assert.notNull(tagService, "TagService must be initialized"); this.tagService = tagService; } diff --git a/juick-server/src/main/java/com/juick/service/TagServiceImpl.java b/juick-server/src/main/java/com/juick/service/TagServiceImpl.java index cb345ceb..b5bd0ae8 100644 --- a/juick-server/src/main/java/com/juick/service/TagServiceImpl.java +++ b/juick-server/src/main/java/com/juick/service/TagServiceImpl.java @@ -41,7 +41,7 @@ public class TagServiceImpl extends BaseJdbcService implements TagService { @Inject public TagServiceImpl(JdbcTemplate jdbcTemplate, MessagesService messagesService) { super(jdbcTemplate, null); - Assert.notNull(messagesService); + Assert.notNull(messagesService, "MessagesService must be initialized"); this.messagesService = messagesService; } diff --git a/juick-server/src/main/java/com/juick/service/search/SphinxSearchServiceImpl.java b/juick-server/src/main/java/com/juick/service/search/SphinxSearchServiceImpl.java index 161e0fb2..aa903545 100644 --- a/juick-server/src/main/java/com/juick/service/search/SphinxSearchServiceImpl.java +++ b/juick-server/src/main/java/com/juick/service/search/SphinxSearchServiceImpl.java @@ -27,12 +27,12 @@ public class SphinxSearchServiceImpl implements SearchService { public SphinxSearchServiceImpl(JdbcTemplate searchJdbcTemplate) { - Assert.notNull(searchJdbcTemplate); + Assert.notNull(searchJdbcTemplate, "JdbcTemplate must be initialized"); this.namedParameterSearchJdbcTemplate = new NamedParameterJdbcTemplate(searchJdbcTemplate); } public SphinxSearchServiceImpl(DataSource searchDataSource) { - Assert.notNull(searchDataSource); + Assert.notNull(searchDataSource, "DataSource must be initialized"); this.namedParameterSearchJdbcTemplate = new NamedParameterJdbcTemplate(searchDataSource); } diff --git a/juick-server/src/main/java/com/juick/service/security/JuickUserDetailsService.java b/juick-server/src/main/java/com/juick/service/security/JuickUserDetailsService.java index d1fd9345..6f9ece7e 100644 --- a/juick-server/src/main/java/com/juick/service/security/JuickUserDetailsService.java +++ b/juick-server/src/main/java/com/juick/service/security/JuickUserDetailsService.java @@ -15,7 +15,7 @@ public class JuickUserDetailsService implements UserDetailsService { private final UserService userService; public JuickUserDetailsService(final UserService userService) { - Assert.notNull(userService); + Assert.notNull(userService, "UserService must be initialized"); this.userService = userService; } |