Remove trailing whitespace in source files

find . -type f -name "*.java" -or -name "*.aj" | \
    xargs perl -p -i -e "s/[ \t]*$//g" {} \;

Issue: SPR-10127
This commit is contained in:
Phillip Webb
2012-12-18 13:45:00 -08:00
committed by Chris Beams
parent 44a474a014
commit 1762157ad1
1400 changed files with 5920 additions and 5923 deletions

View File

@@ -42,5 +42,5 @@ public class DataRetrievalFailureException extends NonTransientDataAccessExcepti
public DataRetrievalFailureException(String msg, Throwable cause) {
super(msg, cause);
}
}

View File

@@ -42,7 +42,7 @@ public class IncorrectUpdateSemanticsDataAccessException extends InvalidDataAcce
public IncorrectUpdateSemanticsDataAccessException(String msg, Throwable cause) {
super(msg, cause);
}
/**
* Return whether data was updated.
* If this method returns false, there's nothing to roll back.

View File

@@ -24,7 +24,7 @@ package org.springframework.dao;
* @author Rod Johnson
*/
public class InvalidDataAccessResourceUsageException extends NonTransientDataAccessException {
/**
* Constructor for InvalidDataAccessResourceUsageException.
* @param msg the detail message
@@ -32,7 +32,7 @@ public class InvalidDataAccessResourceUsageException extends NonTransientDataAcc
public InvalidDataAccessResourceUsageException(String msg) {
super(msg);
}
/**
* Constructor for InvalidDataAccessResourceUsageException.
* @param msg the detail message

View File

@@ -7,10 +7,10 @@
* subclasses), calling code can detect and handle common problems such
* as deadlocks without being tied to a particular data access strategy,
* such as JDBC.
*
*
* <p>All these exceptions are unchecked, meaning that calling code can
* leave them uncaught and treat all data access exceptions as fatal.
*
*
* <p>The classes in this package are discussed in Chapter 9 of
* <a href="http://www.amazon.com/exec/obidos/tg/detail/-/0764543857/">Expert One-On-One J2EE Design and Development</a>
* by Rod Johnson (Wrox, 2002).

View File

@@ -32,7 +32,7 @@ import org.springframework.util.Assert;
* @since 2.0
*/
public class ChainedPersistenceExceptionTranslator implements PersistenceExceptionTranslator {
/** List of PersistenceExceptionTranslators */
private final List<PersistenceExceptionTranslator> delegates = new ArrayList<PersistenceExceptionTranslator>(4);

View File

@@ -196,8 +196,8 @@ public abstract class DataAccessUtils {
return objectResult(results, Number.class).longValue();
}
/**
* Return a translated exception if this is appropriate,
* otherwise return the input exception.

View File

@@ -31,7 +31,7 @@ import org.springframework.dao.DataAccessException;
* @since 2.0
*/
public interface PersistenceExceptionTranslator {
/**
* Translate the given runtime exception thrown by a persistence framework to a
* corresponding exception from Spring's generic DataAccessException hierarchy,

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -32,7 +32,7 @@ import org.springframework.dao.InvalidDataAccessResourceUsageException;
* @see javax.resource.cci.ResultSet
*/
public class InvalidResultSetAccessException extends InvalidDataAccessResourceUsageException {
/**
* Constructor for InvalidResultSetAccessException.
* @param msg message

View File

@@ -28,7 +28,7 @@ import org.springframework.jca.cci.CannotGetCciConnectionException;
import org.springframework.transaction.support.ResourceHolderSynchronization;
import org.springframework.transaction.support.TransactionSynchronizationManager;
import org.springframework.util.Assert;
/**
* Helper class that provides static methods for obtaining CCI Connections
* from a {@link javax.resource.cci.ConnectionFactory}. Includes special

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -28,7 +28,7 @@ import org.springframework.dao.DataAccessException;
* Generic callback interface for code that operates on a CCI Connection.
* Allows to execute any number of operations on a single Connection,
* using any type and number of Interaction.
*
*
* <p>This is particularly useful for delegating to existing data access code
* that expects a Connection to work on and throws ResourceException. For newly
* written code, it is strongly recommended to use CciTemplate's more specific
@@ -47,7 +47,7 @@ public interface ConnectionCallback<T> {
* Gets called by <code>CciTemplate.execute</code> with an active CCI Connection.
* Does not need to care about activating or closing the Connection, or handling
* transactions.
*
*
* <p>If called without a thread-bound CCI transaction (initiated by
* CciLocalTransactionManager), the code will simply get executed on the CCI
* Connection with its transactional semantics. If CciTemplate is configured

View File

@@ -29,7 +29,7 @@ import org.springframework.dao.DataAccessException;
* Allows to execute any number of operations on a single Interaction, for
* example a single execute call or repeated execute calls with varying
* parameters.
*
*
* <p>This is particularly useful for delegating to existing data access code
* that expects an Interaction to work on and throws ResourceException. For newly
* written code, it is strongly recommended to use CciTemplate's more specific
@@ -48,7 +48,7 @@ public interface InteractionCallback<T> {
* Gets called by <code>CciTemplate.execute</code> with an active CCI Interaction.
* Does not need to care about activating or closing the Interaction, or
* handling transactions.
*
*
* <p>If called without a thread-bound CCI transaction (initiated by
* CciLocalTransactionManager), the code will simply get executed on the CCI
* Interaction with its transactional semantics. If CciTemplate is configured

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -23,7 +23,7 @@ import javax.resource.cci.Record;
import org.springframework.dao.DataAccessException;
/**
/**
* Callback interface for extracting a result object from a CCI Record instance.
*
* <p>Used for output object creation in CciTemplate. Alternatively, output
@@ -44,8 +44,8 @@ import org.springframework.dao.DataAccessException;
* @see javax.resource.cci.ResultSet
*/
public interface RecordExtractor<T> {
/**
/**
* Process the data in the given Record, creating a corresponding result object.
* @param record the Record to extract data from
* (possibly a CCI ResultSet)

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2005 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -186,7 +186,7 @@ public interface TransactionDefinition {
/**
* Use the default timeout of the underlying transaction system,
* or none if timeouts are not supported.
* or none if timeouts are not supported.
*/
int TIMEOUT_DEFAULT = -1;
@@ -237,7 +237,7 @@ public interface TransactionDefinition {
* it will <i>not necessarily</i> cause failure of write access attempts.
* A transaction manager which cannot interpret the read-only hint will
* <i>not</i> throw an exception when asked for a read-only transaction.
* @return <code>true</code> if the transaction is to be optimized as read-only
* @return <code>true</code> if the transaction is to be optimized as read-only
* @see org.springframework.transaction.support.TransactionSynchronization#beforeCommit(boolean)
* @see org.springframework.transaction.support.TransactionSynchronizationManager#isCurrentTransactionReadOnly()
*/

View File

@@ -17,7 +17,7 @@
package org.springframework.transaction;
/**
* Superclass for exceptions caused by inappropriate usage of
* Superclass for exceptions caused by inappropriate usage of
* a Spring transaction API.
*
* @author Rod Johnson

View File

@@ -28,7 +28,7 @@ import org.springframework.transaction.TransactionDefinition;
* @since 1.2
*/
public enum Isolation {
/**
* Use the default isolation level of the underlying datastore.
* All other levels correspond to the JDBC isolation levels.
@@ -82,7 +82,7 @@ public enum Isolation {
Isolation(int value) { this.value = value; }
public int value() { return this.value; }
}

View File

@@ -16,7 +16,7 @@
package org.springframework.transaction.annotation;
import org.springframework.transaction.TransactionDefinition;
import org.springframework.transaction.TransactionDefinition;
/**
* Enumeration that represents transaction propagation behaviors for use
@@ -28,7 +28,7 @@ import org.springframework.transaction.TransactionDefinition;
* @since 1.2
*/
public enum Propagation {
/**
* Support a current transaction, create a new one if none exists.
* Analogous to EJB transaction attribute of the same name.
@@ -99,7 +99,7 @@ public enum Propagation {
Propagation(int value) { this.value = value; }
public int value() { return this.value; }
}

View File

@@ -34,7 +34,7 @@ import org.springframework.util.ObjectUtils;
* @see org.springframework.aop.framework.autoproxy.BeanNameAutoProxyCreator
*/
public class MatchAlwaysTransactionAttributeSource implements TransactionAttributeSource, Serializable {
private TransactionAttribute transactionAttribute = new DefaultTransactionAttribute();

View File

@@ -35,7 +35,7 @@ import org.springframework.util.PatternMatchUtils;
/**
* Simple {@link TransactionAttributeSource} implementation that
* allows attributes to be stored per method in a {@link Map}.
*
*
* @author Rod Johnson
* @author Juergen Hoeller
* @since 24.04.2003

View File

@@ -1,12 +1,12 @@
/*
* Copyright 2002-2007 the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

View File

@@ -133,7 +133,7 @@ public class RollbackRuleAttribute implements Serializable{
RollbackRuleAttribute rhs = (RollbackRuleAttribute) other;
return this.exceptionName.equals(rhs.exceptionName);
}
@Override
public int hashCode() {
return this.exceptionName.hashCode();

View File

@@ -152,7 +152,7 @@ public class RuleBasedTransactionAttribute extends DefaultTransactionAttribute i
logger.trace("No relevant rollback rule found: applying default rules");
return super.rollbackOn(ex);
}
return !(winner instanceof NoRollbackRuleAttribute);
}

View File

@@ -44,5 +44,5 @@ public interface TransactionAttribute extends TransactionDefinition {
* @return whether to perform a rollback or not
*/
boolean rollbackOn(Throwable ex);
}

View File

@@ -36,7 +36,7 @@ import org.springframework.aop.support.AbstractPointcutAdvisor;
* @see TransactionProxyFactoryBean
*/
public class TransactionAttributeSourceAdvisor extends AbstractPointcutAdvisor {
private TransactionInterceptor transactionInterceptor;
private final TransactionAttributeSourcePointcut pointcut = new TransactionAttributeSourcePointcut() {

View File

@@ -4,10 +4,10 @@
* AOP-based solution for declarative transaction demarcation.
* Builds on the AOP infrastructure in org.springframework.aop.framework.
* Any POJO can be transactionally advised with Spring.
*
*
* <p>The TransactionFactoryProxyBean can be used to create transactional
* AOP proxies transparently to code that uses them.
*
*
* <p>The TransactionInterceptor is the AOP Alliance MethodInterceptor that
* delivers transactional advice, based on the Spring transaction abstraction.
* This allows declarative transaction management in any environment,

View File

@@ -64,7 +64,7 @@ import org.springframework.transaction.UnexpectedRollbackException;
* transaction for closing at transaction completion time, allowing e.g. for reuse
* of the same Hibernate Session within the transaction. The same mechanism can
* also be leveraged for custom synchronization needs in an application.
*
*
* <p>The state of this class is serializable, to allow for serializing the
* transaction strategy along with proxies that carry a transaction interceptor.
* It is up to subclasses if they wish to make their state to be serializable too.

View File

@@ -19,7 +19,7 @@ package org.springframework.transaction.support;
/**
* A simple {@link org.springframework.transaction.TransactionStatus}
* implementation.
*
*
* <p>Derives from {@link AbstractTransactionStatus} and adds an explicit
* {@link #isNewTransaction() "newTransaction"} flag.
*

View File

@@ -44,7 +44,7 @@ public interface TransactionSynchronization {
/** Completion status in case of heuristic mixed completion or system errors */
int STATUS_UNKNOWN = 2;
/**
* Suspend this synchronization.

View File

@@ -118,7 +118,7 @@ public abstract class TransactionSynchronizationManager {
* Check if there is a resource for the given key bound to the current thread.
* @param key the key to check (usually the resource factory)
* @return if there is a value bound to the current thread
* @see ResourceTransactionManager#getResourceFactory()
* @see ResourceTransactionManager#getResourceFactory()
*/
public static boolean hasResource(Object key) {
Object actualKey = TransactionSynchronizationUtils.unwrapResourceIfNecessary(key);