- 论坛徽章:
- 0
|
ContentFileDecoratorBo.java:
import org.apache.commons.io.FileUtils;
...
try {
FileUtils.write(
new File(ConfigUtil.getConfig().getString(
ConfigUtil.CNT_SVR_RS)
+ cnt.getContent()), vo.getContent(),
Constant.UTF8_ENCODING);
} catch (IOException e) {
import org.apache.commons.io.FileUtils;
...
try {
FileUtils.write(
new File(ConfigUtil.getConfig().getString(
ConfigUtil.CNT_SVR_RS)
+ cnt.getContent()), vo.getContent(),
Constant.UTF8_ENCODING);
} catch (IOException e) {pom.xml:
源码copy to clipboard打印?
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>6</source>
<target>6</target>
<encoding>UTF-8</encoding>
<SPAN style="WHITE-SPACE: pre" minmax_bound="true"> </SPAN></configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>6</source>
<target>6</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
其中,
apache的Fileutils的定义是
public static void write(File file, CharSequence data, String encoding) throws IOException
本代码的调用是
write(File, String, String)
结果
在eclipse下编译通过,在使用maven编译时报如下错误
impl\ContentFileDecoratorBo.java:[36,13] 找不到符号
符号: 方法 write(java.io.File,java.lang.String,java.lang.String)
位置: 类 org.apache.commons.io.FileUtils
有人遇到过这个问题吗 |
|