
Index.Jsp
<jsp:forward page="main.jsf"/>
Main.Jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<link rel="stylesheet" type="text/css" href="styles.css">
<title>Лабораторная работа №3</title>
</head>
<body>
<h2>Вариант 317, Голубцов Евгений, Пермяков Валерий гр.4103 </h2>
<f:view>
<h:form>
<h:messages errorClass="errorMessage"
globalOnly="true"/>
<h:inputText id="coordY" label="y"
value="#{lCController.locationChecker.coordY}"
binding="#{lCController.coordYInput}"
styleClass="textboxY"
required="true">
<f:validateDoubleRange minimum="-5" maximum="5"/>
</h:inputText>
<h:message for="coordY" errorClass="errorMessage"/>
<h:outputLabel for="coordY" value="Введите y(-5;5)" styleClass="labelY"/>
<ul class="buttonListX">Выберите x:<br>
<h:commandButton value="x=-4" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="-4"/>
</h:commandButton><br>
<h:commandButton value="x=-3" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="-3"/>
</h:commandButton><br>
<h:commandButton value="x=-2" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="-2"/>
</h:commandButton><br>
<h:commandButton value="x=-1" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="-1"/>
</h:commandButton><br>
<h:commandButton value="x=0" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="0"/>
</h:commandButton><br>
<h:commandButton value="x=1" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="1"/>
</h:commandButton><br>
<h:commandButton value="x=2" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="2"/>
</h:commandButton><br>
<h:commandButton value="x=3" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="3"/>
</h:commandButton><br>
<h:commandButton value="x=4" styleClass="buttonX">
<f:setPropertyActionListener target="#{lCController.locationChecker.coordX}"
value="4"/>
</h:commandButton>
</ul>
<ul class="linkListR">Выберите R:<br>
<h:commandLink value="R=1" styleClass="linkR">
<f:setPropertyActionListener target="#{lCController.locationChecker.radius}"
value="1"/>
</h:commandLink><br>
<h:commandLink value="R=1,5" styleClass="linkR">
<f:setPropertyActionListener target="#{lCController.locationChecker.radius}"
value="1.5"/>
</h:commandLink><br>
<h:commandLink value="R=2" styleClass="linkR">
<f:setPropertyActionListener target="#{lCController.locationChecker.radius}"
value="2"/>
</h:commandLink><br>
<h:commandLink value="R=2,5" styleClass="linkR">
<f:setPropertyActionListener target="#{lCController.locationChecker.radius}"
value="2.5"/>
</h:commandLink><br>
<h:commandLink value="R=3" styleClass="linkR">
<f:setPropertyActionListener target="#{lCController.locationChecker.radius}"
value="3"/>
</h:commandLink><br>
</ul>
<h:dataTable id="dt1" value="#{lCController.results}"
var="item"
styleClass="resultsTable"
cellspacing="0"
headerClass="resultsHeader"
columnClasses="resultsColumnNumber,resultsColumnNumber,resultsColumnNumber,resultsColumnResult"
border="1"
rendered="#{lCController.results[0] != null}">
<h:column>
<f:facet name="header">
<h:outputText value="x"/>
</f:facet>
<h:outputText value="#{item.x}"></h:outputText>
</h:column>
<h:column>
<f:facet name="header">
<h:outputText value="y"/>
</f:facet>
<h:outputText value="#{item.y}"></h:outputText>
</h:column>
<h:column>
<f:facet name="header">
<h:outputText value="R"/>
</f:facet>
<h:outputText value="#{item.radius}"></h:outputText>
</h:column>
<h:column>
<f:facet name="header">
<h:outputText value="результат"/>
</f:facet>
<h:outputText value="#{item.result}"></h:outputText>
</h:column>
</h:dataTable>
<h:commandButton action="#{lCController.Check}"
value="Проверить"
styleClass="buttonCheck"/>
<h:graphicImage id="gi" alt="Изображение не найдено"
value= "#{lCController.imgFileName}"
width="450" height="450"
styleClass="areaImage"/>
</h:form>
</f:view>
</body>
</html>