Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
No results found
Show changes
Showing
with 956 additions and 0 deletions
package org.informatika.ojek;
import org.informatika.ojek.model.Account;
import java.sql.*;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import static jdk.nashorn.internal.runtime.regexp.joni.Config.log;
/**
* Class DAO merupakan Data Access Object yang digunakan untuk mengakses
* basis data pada identity service
*
* @author fadhilimamk
*/
public class DAO {
private String jdbcURL;
private String jdbcUsername;
private String jdbcPassword;
private Connection jdbcConnection;
public DAO(String jdbcURL, String jdbcUsername, String jdbcPassword) {
this.jdbcURL = jdbcURL;
this.jdbcUsername = jdbcUsername;
this.jdbcPassword = jdbcPassword;
}
private void connect() throws SQLException {
if (jdbcConnection == null || jdbcConnection.isClosed()) {
try {
Class.forName("com.mysql.jdbc.Driver");
} catch (ClassNotFoundException e) {
throw new SQLException(e);
}
jdbcConnection = DriverManager.getConnection(
jdbcURL, jdbcUsername, jdbcPassword);
}
}
private void disconnect() throws SQLException {
if (jdbcConnection != null && !jdbcConnection.isClosed()) {
jdbcConnection.close();
}
}
/**
* Method untuk mendapatkan semua akun dalam basis dataidentity service
*/
public List<Account> listAllAccount() throws SQLException {
List<Account> listAccount = new ArrayList<>();
String sql = "SELECT * FROM account";
connect();
Statement statement = jdbcConnection.createStatement();
ResultSet resultSet = statement.executeQuery(sql);
while (resultSet.next()) {
int id = resultSet.getInt("id");
String name = resultSet.getString("name");
String username = resultSet.getString("username");
String email = resultSet.getString("email");
String phone = resultSet.getString("phone");
String photo = resultSet.getString("photo");
Boolean isDriver = resultSet.getBoolean("is_driver");
Account account = new Account(id, name, username, email, phone, photo, isDriver);
listAccount.add(account);
}
resultSet.close();
statement.close();
disconnect();
return listAccount;
}
/**
* Method checkAvaibility mengembalikan id user dengan username dan password
* yang diberikan. Method ini akan mengembalikan -1 jika user tidak ditemukan
*/
public int checkAvailability(String username, String password) {
String sql = "SELECT id FROM account WHERE username = ? AND password = MD5(?)";
try {
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setString(1, username);
statement.setString(2, password);
ResultSet resultSet = statement.executeQuery();
if (resultSet.next()) {
int id = resultSet.getInt("id");
resultSet.close();
statement.close();
disconnect();
return id;
}
resultSet.close();
statement.close();
disconnect();
} catch (SQLException e) {
e.printStackTrace();
}
return -1;
}
public Account checkAvaibility(String username, String password) {
String sql = "SELECT * FROM account WHERE username = ? AND password = MD5(?)";
try {
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setString(1, username);
statement.setString(2, password);
ResultSet resultSet = statement.executeQuery();
if (resultSet.next()) {
int id = resultSet.getInt("id");
String name = resultSet.getString("name");
String email = resultSet.getString("email");
String phone = resultSet.getString("phone");
String photo = resultSet.getString("photo");
Boolean isDriver = resultSet.getBoolean("is_driver");
Account account = new Account(id, name, username, email, phone, photo, isDriver);
resultSet.close();
statement.close();
disconnect();
return account;
}
resultSet.close();
statement.close();
disconnect();
} catch (SQLException e) {
e.printStackTrace();
}
return null;
}
/**
* Method checkUserAlreadyLogin berfungsi untuk memeriksa apakah user sudah
* login dan memiliki token. Jika user sudah login maka akan dikembalikan tokennya,
* namun jika belum maka akan dikembalikan null.
*/
public String checkUserAlreadyLogin(int idUser) {
String sql = "SELECT * FROM token WHERE id_account = ?";
try {
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setInt(1, idUser);
ResultSet resultSet = statement.executeQuery();
statement.close();
disconnect();
if (resultSet.next()) {
resultSet.close();
return resultSet.getString("token");
}
resultSet.close();
} catch (SQLException e) {
e.printStackTrace();
}
return null;
}
/**
* Method createToken digunakan untuk menyimpan token milik user yang menandakan bahwa
* user tersebut telah login. Waktu expire otomatis diberikan 5 menit.
*/
public void createToken(int idUser, String token) throws SQLException {
String sql = "INSERT INTO token (token, expire_at, id_account) VALUES (?, ?, ?)";
// 5 minute expire
Timestamp expire = new Timestamp(System.currentTimeMillis()+5*60*1000);
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setString(1, token);
statement.setTimestamp(2, expire);
statement.setInt(3, idUser);
int rowCount = statement.executeUpdate();
statement.close();
disconnect();
}
public void updateTokenTimeout(int idUser) throws SQLException {
String sql = "UPDATE token SET expire_at = ? WHERE id_account = ?";
// 5 minute expire
Timestamp expire = new Timestamp(System.currentTimeMillis()+5*60*1000);
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setTimestamp(1, expire);
statement.setInt(2, idUser);
int rowCount = statement.executeUpdate();
statement.close();
disconnect();
}
/**
* Method validateToken mengecek user pemilik suatu token, akan mengembalikan -1
* jika token tidak ditemukan dalam basis data token.
*/
public int validateToken(String token) {
String sql = "SELECT * FROM token WHERE token = ?";
PreparedStatement statement;
try {
connect();
statement = jdbcConnection.prepareStatement(sql);
statement.setString(1, token);
ResultSet resultSet = statement.executeQuery();
resultSet.getFetchSize();
if (resultSet.next()) {
int userId = resultSet.getInt("id_account");
Timestamp timeout = resultSet.getTimestamp("expire_at");
Date now = new Date();
if (timeout.getTime() > now.getTime()) {
statement.close();
resultSet.close();
disconnect();
return userId;
}
// Token is expired
logoutUser(userId);
return -1;
}
statement.close();
resultSet.close();
disconnect();
} catch (Exception e) {
e.printStackTrace();
}
return -1;
}
public Account userInfo(int userId){
String sql = "SELECT * FROM account WHERE id = ?";
try {
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setInt(1, userId);
ResultSet resultSet = statement.executeQuery();
if (resultSet.next()) {
int id = resultSet.getInt("id");
String name = resultSet.getString("name");
String username = resultSet.getString("username");
String email = resultSet.getString("email");
String phone = resultSet.getString("phone");
String photo = resultSet.getString("photo");
Boolean isDriver = resultSet.getBoolean("is_driver");
statement.close();
resultSet.close();
disconnect();
return new Account(id, name, username, email, phone, photo, isDriver);
}
statement.close();
resultSet.close();
disconnect();
} catch (SQLException e) {
e.printStackTrace();
}
return null;
}
/**
* Method logoutUser akan menghapus data token user dengan id = idUser dari basis
* data, user yang tidak memiliki token adalah user yang tidak login
*/
public void logoutUser(int idUser) throws SQLException {
String sql = "DELETE FROM token WHERE id = ?";
connect();
PreparedStatement statement = jdbcConnection.prepareStatement(sql);
statement.setInt(1, idUser);
int rowCount = statement.executeUpdate();
statement.close();
disconnect();
}
}
package org.informatika.ojek;
import com.google.gson.Gson;
import org.informatika.ojek.model.Response;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.PrintWriter;
@WebServlet(name = "Logout", urlPatterns = "/logout")
public class Logout extends HttpServlet {
private DAO DAO;
private Gson gson;
public void init() {
String jdbcURL = getServletContext().getInitParameter("jdbcURL");
String jdbcUsername = getServletContext().getInitParameter("jdbcUsername");
String jdbcPassword = getServletContext().getInitParameter("jdbcPassword");
DAO = new DAO(jdbcURL, jdbcUsername, jdbcPassword);
gson = new Gson();
}
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
response.setContentType("text/html;charset=UTF-8");
response.setStatus(500);
PrintWriter out = response.getWriter();
Response data;
String token = request.getParameter("token");
if (token == null) {
data = new Response(Response.STATUS_ERROR, null, null, "Wrong parameter!");
out.print(gson.toJson(data));
return;
}
int userId = DAO.validateToken(token);
if (userId == -1) {
data = new Response(Response.STATUS_ERROR, null, null, "User already logout!");
out.println(gson.toJson(data));
return;
}
response.setStatus(200);
data = new Response(Response.STATUS_ERROR, null, null, "Logout successfull");
out.println(gson.toJson(data));
}
}
package org.informatika.ojek;
import com.google.gson.Gson;
import org.informatika.ojek.model.Account;
import org.informatika.ojek.model.Response;
import java.io.IOException;
import java.io.PrintWriter;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
/**
*
* @author fadhilimamk
*/
@WebServlet(name = "Main", urlPatterns = {"/Main"})
public class Main extends HttpServlet {
private DAO DAO;
private Gson gson;
public void init() {
String jdbcURL = getServletContext().getInitParameter("jdbcURL");
String jdbcUsername = getServletContext().getInitParameter("jdbcUsername");
String jdbcPassword = getServletContext().getInitParameter("jdbcPassword");
DAO = new DAO(jdbcURL, jdbcUsername, jdbcPassword);
gson = new Gson();
}
protected void processRequest(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
response.setContentType("text/html;charset=UTF-8");
try (PrintWriter out = response.getWriter()) {
List<Account> data = new ArrayList<>();
String dataString = null;
try {
data = DAO.listAllAccount();
Gson gson = new Gson();
dataString = gson.toJson(data);
} catch (SQLException ex) {
out.println(ex);
throw new ServletException(ex);
}
out.println(dataString);
}
}
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
PrintWriter out = response.getWriter();
Response data;
response.setStatus(500);
String token = request.getParameter("token");
// Check token in post body
if (token == null) {
response.setStatus(500);
data = new Response(Response.STATUS_ERROR, null, null, "Wrong parameter!");
out.print(gson.toJson(data));
return;
}
// Check if token valid
int userId = DAO.validateToken(token);
if (userId == -1) {
data = new Response(Response.STATUS_ERROR, null, null, "Token is expired!");
out.print(gson.toJson(data));
return;
}
// Get user info
Account account = DAO.userInfo(userId);
response.setStatus(200);
data = new Response(Response.STATUS_SUCCESS, null, account, null);
out.print(gson.toJson(data));
}
}
package org.informatika.ojek;
import com.google.gson.Gson;
import org.informatika.ojek.model.Response;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.PrintWriter;
import java.sql.SQLException;
@WebServlet(name = "Validate")
public class Validate extends HttpServlet {
private DAO DAO;
private Gson gson;
public void init() {
String jdbcURL = getServletContext().getInitParameter("jdbcURL");
String jdbcUsername = getServletContext().getInitParameter("jdbcUsername");
String jdbcPassword = getServletContext().getInitParameter("jdbcPassword");
DAO = new DAO(jdbcURL, jdbcUsername, jdbcPassword);
gson = new Gson();
}
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
response.setContentType("text/html;charset=UTF-8");
response.setStatus(500);
PrintWriter out = response.getWriter();
Response data;
String token = request.getParameter("token");
// Check token in post body
if (token == null) { ;
data = new Response(Response.STATUS_ERROR, null, null, "Wrong parameter!");
out.print(gson.toJson(data));
return;
}
// Check if token valid
int userId = DAO.validateToken(token);
if (userId == -1) {
data = new Response(Response.STATUS_ERROR, null, "invalid", "Token is invalid!");
out.print(gson.toJson(data));
return;
}
// Token is valid
response.setStatus(200);
data = new Response(Response.STATUS_SUCCESS, null, "valid", "Token is valid!");
out.print(gson.toJson(data));
}
}
package org.informatika.ojek.model;
import java.security.MessageDigest;
import java.util.Date;
import java.util.UUID;
public class Account {
protected int id;
protected String name;
protected String username;
protected String email;
protected String phone;
protected String photo;
protected Boolean isDriver;
public Account(int id, String name, String username, String email, String phone, String photo, Boolean isDriver) {
this.id = id;
this.name = name;
this.username = username;
this.email = email;
this.phone = phone;
this.photo = photo;
this.isDriver = isDriver;
}
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getUsername() {
return username;
}
public void setUsername(String username) {
this.username = username;
}
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
public String getPhoto() {
return photo;
}
public void setPhoto(String photo) {
this.photo = photo;
}
public Boolean getIsDriver() {
return isDriver;
}
public void setIsDriver(Boolean isDriver) {
this.isDriver = isDriver;
}
public String generateToken(String password) throws Exception {
String token = "x"+id+username+password+new Date();
MessageDigest md = MessageDigest.getInstance("SHA-256");
md.update(token.getBytes());
byte tokenData[] = md.digest();
StringBuffer sb = new StringBuffer();
for (int i = 0; i < tokenData.length; i++) {
sb.append(Integer.toString((tokenData[i] & 0xff) + 0x100, 16).substring(1));
}
token = sb.toString();
return token;
}
}
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package org.informatika.ojek.model;
/**
*
* @author fadhilimamk
*/
public class Response {
public static final String STATUS_ERROR = "error";
public static final String STATUS_SUCCESS= "success";
protected String status;
protected String token;
protected Object data;
protected String message;
public Response(String status, String token, Object data, String message) {
this.status = status;
this.token = token;
this.data = data;
this.message = message;
}
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
public String getToken() {
return token;
}
public void setToken(String token) {
this.token = token;
}
public Object getData() {
return data;
}
public void setData(Object data) {
this.data = data;
}
public String getMessage() {
return message;
}
public void setMessage(String message) {
this.message = message;
}
}
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1">
<servlet>
<servlet-name>Auth</servlet-name>
<servlet-class>org.informatika.ojek.Auth</servlet-class>
</servlet>
<servlet>
<servlet-name>Main</servlet-name>
<servlet-class>org.informatika.ojek.Main</servlet-class>
</servlet>
<servlet>
<servlet-name>Validate</servlet-name>
<servlet-class>org.informatika.ojek.Validate</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Auth</servlet-name>
<url-pattern>/login</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Validate</servlet-name>
<url-pattern>/validate</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Main</servlet-name>
<url-pattern>/info</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>main</welcome-file>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<session-config>
<session-timeout>
30
</session-timeout>
</session-config>
<display-name>Ojek Identity Service</display-name>
<context-param>
<param-name>jdbcURL</param-name>
<param-value>jdbc:mysql://localhost:3306/db_ojek_account</param-value>
</context-param>
<context-param>
<param-name>jdbcUsername</param-name>
<param-value>root</param-value>
</context-param>
<context-param>
<param-name>jdbcPassword</param-name>
<param-value></param-value>
</context-param>
</web-app>
\ No newline at end of file
<%--
Created by IntelliJ IDEA.
User: fadhilimamk
Date: 04/11/17
Time: 8:34
To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
<title>$Title$</title>
</head>
<body>
$END$
</body>
</html>
<component name="ArtifactManager">
<artifact type="exploded-war" name="WebApp:war exploded">
<output-path>$PROJECT_DIR$/out/artifacts/WebApp_war_exploded</output-path>
<root id="root">
<element id="javaee-facet-resources" facet="WebApp/web/Web" />
<element id="directory" name="WEB-INF">
<element id="directory" name="classes">
<element id="module-output" name="WebApp" />
</element>
</element>
</root>
</artifact>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Java EE 6-Java EE 6">
<CLASSES>
<root url="jar://$PROJECT_DIR$/lib/javax.annotation.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.ejb.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.jms.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.persistence.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.transaction.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.servlet.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.resource.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.servlet.jsp.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/javax.servlet.jsp.jstl.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/WebApp.iml" filepath="$PROJECT_DIR$/WebApp.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Palette2">
<group name="Swing">
<item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
</item>
<item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
</item>
<item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
</item>
<item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
<default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
</item>
<item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
<initial-values>
<property name="text" value="Button" />
</initial-values>
</item>
<item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
<initial-values>
<property name="text" value="RadioButton" />
</initial-values>
</item>
<item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
<initial-values>
<property name="text" value="CheckBox" />
</initial-values>
</item>
<item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
<initial-values>
<property name="text" value="Label" />
</initial-values>
</item>
<item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
</item>
<item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
<preferred-size width="200" height="200" />
</default-constraints>
</item>
<item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
<preferred-size width="200" height="200" />
</default-constraints>
</item>
<item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
</item>
<item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
</item>
<item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
</item>
<item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
</item>
<item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
<preferred-size width="-1" height="20" />
</default-constraints>
</item>
<item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
</item>
<item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
</item>
</group>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="web" name="Web">
<configuration>
<descriptors>
<deploymentDescriptor name="web.xml" url="file://$MODULE_DIR$/web/WEB-INF/web.xml" />
</descriptors>
<webroots>
<root url="file://$MODULE_DIR$/web" relative="/" />
</webroots>
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="Java EE 6-Java EE 6" level="project" />
</component>
</module>
\ No newline at end of file
File added
File added
File added
File added
File added
File added