jsp中的jena包
我将 Jena 包导入到我的 JSP 页面中。
<%@ page import="com.hp.hpl.jena.datatypes.xsd.XSDDatatype" %>
<%@ page import="com.hp.hpl.jena.ontology.DatatypeProperty" %>
<%@ page import="com.hp.hpl.jena.ontology.Individual" %>
<%@ page import="com.hp.hpl.jena.ontology.OntClass" %>
<%@ page import="com.hp.hpl.jena.ontology.OntModel" %>
<%@ page import="com.hp.hpl.jena.ontology.OntModelSpec" %>
<%@ page import="com.hp.hpl.jena.rdf.model.Literal" %>
<%@ page import="com.hp.hpl.jena.rdf.model.ModelFactory" %>
<%@ page import="com.hp.hpl.jena.rdf.model.Statement" %>
<%@ page import="com.hp.hpl.jena.util.FileManager" %>
当我运行它时,会提示错误:
org.apache.jasper.JasperException: Unable to compile class for JSP: An error occurred at line: 9 in the generated java file Only a type can be imported. com.hp.hpl.jena.datatypes.xsd.XSDDatatype resolves to a package An error occurred at line: 10 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.DatatypeProperty resolves to a package An error occurred at line: 11 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.Individual resolves to a package An error occurred at line: 12 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.OntClass resolves to a package
我该如何纠正这个问题?
i imported Jena packages into my JSP page.
<%@ page import="com.hp.hpl.jena.datatypes.xsd.XSDDatatype" %>
<%@ page import="com.hp.hpl.jena.ontology.DatatypeProperty" %>
<%@ page import="com.hp.hpl.jena.ontology.Individual" %>
<%@ page import="com.hp.hpl.jena.ontology.OntClass" %>
<%@ page import="com.hp.hpl.jena.ontology.OntModel" %>
<%@ page import="com.hp.hpl.jena.ontology.OntModelSpec" %>
<%@ page import="com.hp.hpl.jena.rdf.model.Literal" %>
<%@ page import="com.hp.hpl.jena.rdf.model.ModelFactory" %>
<%@ page import="com.hp.hpl.jena.rdf.model.Statement" %>
<%@ page import="com.hp.hpl.jena.util.FileManager" %>
When I run it, the error will prompt:
org.apache.jasper.JasperException: Unable to compile class for JSP: An error occurred at line: 9 in the generated java file Only a type can be imported. com.hp.hpl.jena.datatypes.xsd.XSDDatatype resolves to a package An error occurred at line: 10 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.DatatypeProperty resolves to a package An error occurred at line: 11 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.Individual resolves to a package An error occurred at line: 12 in the generated java file Only a type can be imported. com.hp.hpl.jena.ontology.OntClass resolves to a package
How can I correct this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论