为什么我的jsp的已编译文件(即java文件n类文件)在工作文件夹中不可见 [英] why my jsp 's compiled files i.e java files n class files are not visible in work folder
问题描述
我知道这可能是一个非常愚蠢的问题,但我真的很期待它的答案. 我正在练习jsp,几天前,当我创建一个jsp文件时,相应的servlet在work/catalina/localhost_ _ _中可见.文件夹 但是现在无论我正在创建什么项目,所有的jsp都可以正常工作,但是我无法在工作文件夹中找到已编译的文件... 现在可能是什么问题..或eclipse可能是问题所在,因为它保留了这些jsp编译文件. 请尽快答复,
i know this may be a very silly questions to ask but i am really looking forward for its answer. i am practicing jsp and few days before when i created one jsp file ,the corresponding servlet was visible in work/catalina/localhost_ _ _. folder but now whatever projects i m creating ,all the jsp's are working fine but i am not able to find the compiled file in the work folder... what can be the problem now.. or eclipse might be the problem as where it is keeping those jsp compiled files.. please reply as soon as possible,,
推荐答案
您可以通过以下方式找到该类所在的位置(在jar或其他容器中):
You can find where the class resides (inside a jar or whatever), via:
<!-- This classes URL:
<%= getClass().getProtectionDomain().getCodeSource()
.getLocation().toExternalForm(); %>
-->
getLocation传递一个URL.
The getLocation delivers an URL.
这篇关于为什么我的jsp的已编译文件(即java文件n类文件)在工作文件夹中不可见的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!