我已经将log4j放到我的buildpath中,但是当我运行我的应用程序时收到以下消息:
log4j:WARN No appenders could be found for logger (dao.hsqlmanager).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Run Code Online (Sandbox Code Playgroud)
这些警告意味着什么?什么是appender在这里?
我想在我的*.xhtml页面上放一个打包游戏.(我使用的是jsf 2和primefaces 3.5)
然而,
当我在xhtml中"翻译"html页面时,我在此脚本中收到错误:
<script>
var el = document.getElementById("pacman");
if (Modernizr.canvas && Modernizr.localstorage &&
Modernizr.audio && (Modernizr.audio.ogg || Modernizr.audio.mp3)) {
window.setTimeout(function () { PACMAN.init(el, "./"); }, 0);
} else {
el.innerHTML = "Sorry, needs a decent browser<br /><small>" +
"(firefox 3.6+, Chrome 4+, Opera 10+ and Safari 4+)</small>";
}
</script>
Run Code Online (Sandbox Code Playgroud)
在线:
if (Modernizr.canvas && Modernizr.localstorage &&
Run Code Online (Sandbox Code Playgroud)
我得到:
实体名称必须紧跟实体引用中的"&".
知道怎么解决这个问题吗?
我看了一下:Eclipse-Shortcuts,但是我找不到生成构造函数的东西.
什么是生成标准构造函数的捷径?
我读了一些XSLT示例,发现代码:
<xsl:apply-template select="@*|node()"/>
Run Code Online (Sandbox Code Playgroud)
那是什么意思?
我目前尝试实施亚马逊ec2,我读了一年后他们收取你的费用.之前我使用谷歌应用引擎(使用java),你可以启用/禁用充电功能.我只想尝试免费的ec2实例,所以这是我的问题:
是否可以在Eclipse(Indigo)的一个类中为每个方法自动生成Javadoc注释?
我想进行Shapiro-Wilk常态测试.我的数据是csv
格式.它看起来像这样:
heisenberg
HWWIchg
1 -15.60
2 -21.60
3 -19.50
4 -19.10
5 -20.90
6 -20.70
7 -19.30
8 -18.30
9 -15.10
Run Code Online (Sandbox Code Playgroud)
但是,当我进行测试时,我得到:
shapiro.test(heisenberg)
Run Code Online (Sandbox Code Playgroud)
为什么不选择正确的列以及如何做到这一点?谢谢你的回复!!!
我此刻有点困惑.我试过了:
String test = "KP 175.105";
test.replace("KP", "");
System.out.println(test);
Run Code Online (Sandbox Code Playgroud)
得到了:
KP 175.105
Run Code Online (Sandbox Code Playgroud)
但是,我想:
175.105
Run Code Online (Sandbox Code Playgroud)
我的代码出了什么问题?
我试图在我的线程池中关闭所有线程.
通常我会尝试:
while(!Thread.currentThread().isInterrupted()) {...
Run Code Online (Sandbox Code Playgroud)
关闭while循环...
但我有一个仅包含的线程
while(!Thread.currentThread().isInterrupted()) {//which is true
Run Code Online (Sandbox Code Playgroud)
这是我关闭线程的方式:
pool.shutdownNow();
Run Code Online (Sandbox Code Playgroud)
那你怎么关闭这样一个线程呢?
我在我的程序中使用hsqldb作为db.我想在spring上注入构造函数值.
这是我的豆子:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="ConnectionManager" class="at.tuwien.group2.vpm.persistence.ConnectionManager"
scope="singleton">
<constructor-arg name="url" value="jdbc:hsqldb:file:vpmDatabasetest" />
<constructor-arg name="user" value="sa" />
<constructor-arg name="password" value="" />
</bean>
Run Code Online (Sandbox Code Playgroud)
我的构造函数看起来像这样:
public ConnectionManager(String url, String user, String password) {
if(url == null || user == null || password == null) {
throw new NullPointerException("Paramaeter cannot be null!");
}
this.url = url;
this.user = user;
this.password = password;
}
Run Code Online (Sandbox Code Playgroud)
但是,当我想执行代码时,我得到:
属性'name'不允许出现在元素'constructor-arg'中
属性'name'不允许出现在元素'constructor-arg'中
我应该用什么呢?
java ×6
eclipse ×4
xml ×2
amazon-ec2 ×1
automation ×1
facelets ×1
javascript ×1
jsf ×1
log4j ×1
maven ×1
r ×1
replace ×1
spring ×1
statistics ×1
string ×1
threadpool ×1
xhtml ×1
xslt ×1