本文介绍了我怎样才能燮有关Sun专有的API preSS java编译器警告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是EN code()从sun.misc.BASE64En codeR封装方法。我如何燮preSS它生成的编译器警告?

I'm using the encode() method from the sun.misc.BASE64Encoder package. How do I suppress the compiler warnings that it generates?

sun.misc.BASE64En codeR是Sun的专有API,并可能

和作为后续,为什么不让我看到在Eclipse这样的警告?

And as a followup, why don't I see this warning in Eclipse?

推荐答案

您可以切换到不同的Base64编码实现,例如,<一个href=\"http://commons.apache.org/$c$cc/apidocs/org/apache/commons/$c$cc/binary/Base64.html\">http://commons.apache.org/$c$cc/apidocs/org/apache/commons/$c$cc/binary/Base64.html它是Apache公地的包,你可能已经包含在你的classpath的一部分,或者http://iharder.sourceforge.net/current/java/base64/你可能只是把实现和坚守在你的源代码树,如果你不想要的路径上的另一个罐子。

You could switch to a different Base64 implementation, e.g., http://commons.apache.org/codec/apidocs/org/apache/commons/codec/binary/Base64.html which is part of the Apache commons packages, which you might already have included in your classpath, or http://iharder.sourceforge.net/current/java/base64/ which you could just take the implementation and stick in your source tree if you don't want another Jar on the path.

这篇关于我怎样才能燮有关Sun专有的API preSS java编译器警告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-03 05:43