Fix several miscellaneous compiler/Eclipse warnings
- Suppress an (intentional) AspectJ warning - Remove unused imports - Suppress a [hiding] warning - Fix a generics warning related to extension of final types Issue: SPR-9431
This commit is contained in:
parent
15e9fe638c
commit
662a02b952
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2002-2012 the original author or authors.
|
* Copyright 2002-2013 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,6 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.aop.aspectj.autoproxy;
|
package org.springframework.aop.aspectj.autoproxy;
|
||||||
|
|
||||||
|
import org.aspectj.lang.annotation.SuppressAjWarnings;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Adrian Colyer
|
* @author Adrian Colyer
|
||||||
*/
|
*/
|
||||||
|
@ -25,6 +27,7 @@ public aspect CodeStyleAspect {
|
||||||
|
|
||||||
pointcut somePC() : call(* someMethod());
|
pointcut somePC() : call(* someMethod());
|
||||||
|
|
||||||
|
@SuppressAjWarnings("adviceDidNotMatch")
|
||||||
before() : somePC() {
|
before() : somePC() {
|
||||||
System.out.println("match");
|
System.out.println("match");
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
package org.springframework.context.annotation;
|
package org.springframework.context.annotation;
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
import static org.junit.Assert.*;
|
||||||
import static org.junit.Assume.assumeFalse;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
/*
|
||||||
|
* Copyright 2002-2013 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.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
package org.springframework.context.annotation;
|
package org.springframework.context.annotation;
|
||||||
|
|
||||||
import static org.hamcrest.CoreMatchers.equalTo;
|
import static org.hamcrest.CoreMatchers.equalTo;
|
||||||
|
@ -31,7 +47,7 @@ public class BeanMethodPolymorphismTests {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void beanMethodOverloadingWithoutInheritance() {
|
public void beanMethodOverloadingWithoutInheritance() {
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings({ "unused", "hiding" })
|
||||||
@Configuration class Config {
|
@Configuration class Config {
|
||||||
@Bean String aString() { return "na"; }
|
@Bean String aString() { return "na"; }
|
||||||
@Bean String aString(Integer dependency) { return "na"; }
|
@Bean String aString(Integer dependency) { return "na"; }
|
||||||
|
|
|
@ -28,7 +28,6 @@ import org.springframework.tests.TestGroup;
|
||||||
|
|
||||||
import static org.junit.Assert.*;
|
import static org.junit.Assert.*;
|
||||||
import static org.mockito.BDDMockito.*;
|
import static org.mockito.BDDMockito.*;
|
||||||
import static org.mockito.Mockito.*;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Rick Evans
|
* @author Rick Evans
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2002-2012 the original author or authors.
|
* Copyright 2002-2013 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -1048,7 +1048,7 @@ public class BridgeMethodResolverTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public class GenericSqlMapIntegerDao<T extends Integer> extends GenericSqlMapDao<T> {
|
public class GenericSqlMapIntegerDao<T extends Number> extends GenericSqlMapDao<T> {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void saveOrUpdate(T t) {
|
public void saveOrUpdate(T t) {
|
||||||
|
|
Loading…
Reference in New Issue