11/*
2- * Copyright 2002-2014 the original author or authors.
2+ * Copyright 2002-2016 the original author or authors.
33 *
44 * Licensed under the Apache License, Version 2.0 (the "License");
55 * you may not use this file except in compliance with the License.
@@ -80,8 +80,8 @@ public ResourceDatabasePopulator() {
8080 /**
8181 * Construct a new {@code ResourceDatabasePopulator} with default settings
8282 * for the supplied scripts.
83- * @param scripts the scripts to execute to initialize or clean up the database;
84- * never {@code null}
83+ * @param scripts the scripts to execute to initialize or clean up the database
84+ * ( never {@code null})
8585 * @since 4.0.3
8686 */
8787 public ResourceDatabasePopulator (Resource ... scripts ) {
@@ -97,21 +97,23 @@ public ResourceDatabasePopulator(Resource... scripts) {
9797 * statement can be ignored
9898 * @param sqlScriptEncoding the encoding for the supplied SQL scripts; may
9999 * be {@code null} or <em>empty</em> to indicate platform encoding
100- * @param scripts the scripts to execute to initialize or clean up the database;
101- * never {@code null}
100+ * @param scripts the scripts to execute to initialize or clean up the database
101+ * ( never {@code null})
102102 * @since 4.0.3
103103 */
104- public ResourceDatabasePopulator (boolean continueOnError , boolean ignoreFailedDrops , String sqlScriptEncoding ,
105- Resource ... scripts ) {
104+ public ResourceDatabasePopulator (boolean continueOnError , boolean ignoreFailedDrops ,
105+ String sqlScriptEncoding , Resource ... scripts ) {
106+
106107 this (scripts );
107108 this .continueOnError = continueOnError ;
108109 this .ignoreFailedDrops = ignoreFailedDrops ;
109110 setSqlScriptEncoding (sqlScriptEncoding );
110111 }
111112
113+
112114 /**
113115 * Add a script to execute to initialize or clean up the database.
114- * @param script the path to an SQL script; never {@code null}
116+ * @param script the path to an SQL script ( never {@code null})
115117 */
116118 public void addScript (Resource script ) {
117119 Assert .notNull (script , "Script must not be null" );
@@ -120,7 +122,7 @@ public void addScript(Resource script) {
120122
121123 /**
122124 * Add multiple scripts to execute to initialize or clean up the database.
123- * @param scripts the scripts to execute; never {@code null}
125+ * @param scripts the scripts to execute ( never {@code null})
124126 */
125127 public void addScripts (Resource ... scripts ) {
126128 assertContentsOfScriptArray (scripts );
@@ -130,7 +132,7 @@ public void addScripts(Resource... scripts) {
130132 /**
131133 * Set the scripts to execute to initialize or clean up the database,
132134 * replacing any previously added scripts.
133- * @param scripts the scripts to execute; never {@code null}
135+ * @param scripts the scripts to execute ( never {@code null})
134136 */
135137 public void setScripts (Resource ... scripts ) {
136138 assertContentsOfScriptArray (scripts );
@@ -173,8 +175,8 @@ public void setCommentPrefix(String commentPrefix) {
173175 * Set the start delimiter that identifies block comments within the SQL
174176 * scripts.
175177 * <p>Defaults to {@code "/*"}.
176- * @param blockCommentStartDelimiter the start delimiter for block comments;
177- * never {@code null} or empty
178+ * @param blockCommentStartDelimiter the start delimiter for block comments
179+ * ( never {@code null} or empty)
178180 * @since 4.0.3
179181 * @see #setBlockCommentEndDelimiter
180182 */
@@ -187,8 +189,8 @@ public void setBlockCommentStartDelimiter(String blockCommentStartDelimiter) {
187189 * Set the end delimiter that identifies block comments within the SQL
188190 * scripts.
189191 * <p>Defaults to <code>"*/"</code>.
190- * @param blockCommentEndDelimiter the end delimiter for block comments;
191- * never {@code null} or empty
192+ * @param blockCommentEndDelimiter the end delimiter for block comments
193+ * ( never {@code null} or empty)
192194 * @since 4.0.3
193195 * @see #setBlockCommentStartDelimiter
194196 */
@@ -227,16 +229,16 @@ public void populate(Connection connection) throws ScriptException {
227229 Assert .notNull (connection , "Connection must not be null" );
228230 for (Resource script : getScripts ()) {
229231 ScriptUtils .executeSqlScript (connection , encodeScript (script ), this .continueOnError ,
230- this .ignoreFailedDrops , this .commentPrefix , this .separator , this .blockCommentStartDelimiter ,
231- this .blockCommentEndDelimiter );
232+ this .ignoreFailedDrops , this .commentPrefix , this .separator , this .blockCommentStartDelimiter ,
233+ this .blockCommentEndDelimiter );
232234 }
233235 }
234236
235237 /**
236238 * Execute this {@code ResourceDatabasePopulator} against the given
237239 * {@link DataSource}.
238240 * <p>Delegates to {@link DatabasePopulatorUtils#execute}.
239- * @param dataSource the {@code DataSource} to execute against; never {@code null}
241+ * @param dataSource the {@code DataSource} to execute against ( never {@code null})
240242 * @throws ScriptException if an error occurs
241243 * @since 4.1
242244 * @see #populate(Connection)
@@ -254,7 +256,7 @@ final List<Resource> getScripts() {
254256 * {@link EncodedResource} is not a sub-type of {@link Resource}. Thus we
255257 * always need to wrap each script resource in an {@code EncodedResource}
256258 * using the configured {@linkplain #setSqlScriptEncoding encoding}.
257- * @param script the script to wrap; never {@code null}
259+ * @param script the script to wrap ( never {@code null})
258260 */
259261 private EncodedResource encodeScript (Resource script ) {
260262 Assert .notNull (script , "Script must not be null" );
0 commit comments