0 0

maven导入包后出现Cannot find class [xxxx] for bean with name 'com.jcloud.survey.Consta5

最近做一个android项目的登陆功能,导入第三方的引用包后,出现Bean property 'loginUrl' is not writable or has an invalid setter method这个错误。
我的类是这样定义的
public class Constants {

//	public final static String defautLoginUrl = "http://m.jd.com/union/sid.action";

	/** 会话过期时间-单位为秒 */
	public static int SESSION_TIMEOUT = 3600;

	public static String REWARD = "reward";

	public static final String USER_INFO_KEY = "USER_INFO";

	public static final String SID = "sid";

	public static String loginurl  =   "http://m.xx.com/union/sid.action";

	public static String getloginurl() {
		return loginurl;
	}

	public static void setloginurl(String loginURL) {
		loginurl = loginURL;
	}

	public static final String E_SURVEY_ID = "eSurveyId";

	public static final String PROJECT = "survey";

	
}


我的spring配置是这样的
	<bean class="com.jcloud.survey.Constants">
	<property name="loginurl" value="${survey.login.url}" />
	</bean>


这两段代码不在一个工程中,其实是前一段代码类被maven制作成jar包,引入到web工程里面,然后由web工程在启动时通过spring初始化loginurl变量。
很奇怪的一个问题,试了很多办法都没有效果,求解惑
2015年1月12日 17:13

1个答案 按时间排序 按投票排序

0 0

是因为被static修饰的原因吗?

2015年1月14日 16:47

相关推荐

    Maven更新失败,Cannot resolve plugin org.apache.maven.plugins:maven-compiler-plugin:3.1

    Maven更新问题 今天Maven在更新的时候发现... http://maven.aliyun.com/nexus/content/repositories/central/ central junit junit Address/ http://jcenter.bintray.com/ central alimaven aliyun maven htt

    maven-shade-plugin-3.1.0.jar

    &lt;groupId&gt;org.apache.maven.plugins &lt;artifactId&gt;maven-shade-plugin &lt;version&gt;3.1.0 &lt;phase&gt;package &lt;goal&gt;shade implementation="org.apache.maven.plugins.shade.resource....

    htmlparser

    org.htmlparser.beans.FilterBean.class org.htmlparser.beans.HTMLLinkBean.class org.htmlparser.beans.HTMLTextBean.class org.htmlparser.beans.LinkBean.class org.htmlparser.beans.StringBean.class org....

    maven 手动导入qrcode.jar包.zip

    maven工程下qrcode jar包下载失败,提供两个qrcode.jar QRCode_swetake-3.0.0.jar 包,cmd命令行安装方法,maven手动添加jar包 qrcode.jar QRCode_swetake-3.0.0.jar

    maven 3.5.0 Cannot assign configuration entry 'pluginArtifacts' with value '${pl

    Cannot assign configuration entry 'pluginArtifacts' with value '${plugin.artifacts}' of type java.ut

    java读写注册表jar包,com.ice.jni.registry

    META-INF/MANIFEST.MF com.ice.jni.registry.HexNumberFormat.class com.ice.jni.registry.NoSuchKeyException.class com.ice.jni.registry.NoSuchValueException.class com.ice.jni.registry.RegBinaryValue.class ...

    javax.ejb.rar

    javax.ejb.EnterpriseBean.class javax.ejb.EntityBean.class javax.ejb.EntityContext.class javax.ejb.FinderException.class javax.ejb.Handle.class javax.ejb.HomeHandle.class javax.ejb....

    jodconverter2.2.2.jar的Maven依赖包

    直接解压到Maven仓库的"com\artofsolving\jodconverter"这个目录下; 如有不明,访问这篇我写的博客; https://blog.csdn.net/qq_39403734/article/details/82020309 物超所值;

    批量导入maven本地jar包

    批量导入maven本地jar包

    org.apache.commons.lang jar包下载(commons-lang3-3.1.jar)

    必须使用的jar包。为JRE5.0+的更好的版本所提供 Jar文件包含的类: META-INF/MANIFEST.MFMETA-INF/LICENSE.txtMETA-INF/NOTICE.txtorg.apache.commons.lang.ArrayUtils.class org.apache.commons.lang.BitField....

    Android.Application.Development.with.Maven

    It would be helpful, but not necessary, if you have some previous experience with Maven. Table of Contents Chapter 1. Beginning With The Basics Chapter 2. Starting The Development Phase Chapter 3. ...

    Apache.Maven.Cookbook.1785286129

    If you are a Java developer or a manager who has experience with Apache Maven and want to extend your knowledge, then this is the ideal book for you. Apache Maven Cookbook is for those who want to ...

    Maven拆分代码.zip

    &lt;property name="url" value="jdbc:mysql:///maven"/&gt; &lt;property name="username" value="root"/&gt; &lt;property name="password" value="root"/&gt; &lt;/bean&gt; &lt;!--配置生产SqlSession对象的工厂--&gt; &lt;bean id=...

    Android.Application.Development.with.Maven.17

    It would be helpful, but not necessary, if you have some previous experience with Maven. Table of Contents Chapter 1. Beginning With The Basics Chapter 2. Starting The Development Phase Chapter 3. ...

    Impala的JDBC编程驱动

    impala的驱动下载,com.cloudera.impala.jdbc41.Driver

    nineoldandroids-2.1.1.jar

    备用资源META-INF/MANIFEST.MF META-INF/maven/com.nineoldandroids/library/pom.properties META-INF/maven/com.nineoldandroids/library/pom.xml com.nineoldandroids.animation.Animator.class ...

    maven批量导入第三方jar包至本地库工具

    借此项目,可将下载的maven的jar包按指定格式修改后,maven批量导入第三方jar包至maven本地库,实现快速的maven自动导入maven本地库(建议需要导入的jar包较多时使用)

    maven批量导入jar包的工具类

    在 maven项目中批量导入jar包,使用的是python代码工具类,自己编写的,其中只需要把这个py文件放到jar包的同一个目录下,双击这个py文件即可批量安装,并且生成一个out.xml文件,这个文件复制到pom.xml中即可

    maven导入错误源头.png

    maven项目导入依赖失败的一种解决方法

Global site tag (gtag.js) - Google Analytics