-
Notifications
You must be signed in to change notification settings - Fork 35
/
Intersect.jsp
61 lines (48 loc) · 1.76 KB
/
Intersect.jsp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<%@ include file="Prelude.jsp" %>
<html>
<head>
<title>Sigma KB Term Intersection</title>
</head>
<body BGCOLOR=#FFFFFF>
<%
/** This code is copyright Teknowledge (c) 2003, Articulate Software (c) 2003-2017,
Infosys (c) 2017-present.
This software is released under the GNU Public License
<http://www.gnu.org/copyleft/gpl.html>.
Please cite the following article in any publication with references:
Pease A., and Benzmüller C. (2013). Sigma: An Integrated Development Environment
for Logical Theories. AI Communications 26, pp79-97. See also
http://github.com/ontologyportal
*/
String term1 = request.getParameter("term1");
if (term1 == null || term1.equals("null"))
term1 = "Object";
String term2 = request.getParameter("term2");
if (term2 == null || term2.equals("null"))
term2 = "subclass";
ArrayList<Formula> forms = KButilities.termIntersection(kb,term1,term2);
%>
<form action="Intersect.jsp">
<%
String pageName = "Intersect";
String pageString = "Term Intersection";
%>
<%@include file="CommonHeader.jsp" %>
<table ALIGN="LEFT" WIDTH=80%><tr><TD BGCOLOR='#AAAAAA'><IMG SRC='pixmaps/1pixel.gif' width=1 height=1 border=0></TD></tr></table><BR>
Term 1: <input type="text" size="30" name="term1" value="<%=term1 %>">
Term 2: <input type="text" size="30" name="term2" value="<%=term2 %>"><p>
<p>
<input type="submit" name="submit" value="submit">
</form>
<table width="95%">
<%
if (forms == null || forms.size() == 0)
out.println("<b>No intersection of terms " + term1 + " and " + term2 + " found.</b><P>");
else
out.println(HTMLformatter.formatFormulaList(forms,"", kb, language, flang, 0, 0, ""));
%>
</table>
<p>
<%@ include file="Postlude.jsp" %>
</body>
</html>