This is a simple application that manages a database of terms and definitions. It will be built using Struts and MySQL, and run on a Tomcat Server.
The first version of this application will focus on only the most basic of operations. Searching, Adding, modifying, and deleting data in a database.
This database will consist of a single table. The table GlossaryItem will have three fields, an ID, term, and definition. The ID is included for future versions of this project, and to insure uniqueness.
The application will allow the user to:
The application will consist of the following pages.
| Page | Notes | Button/Links | Result |
|---|---|---|---|
| MainPage | This page will show a subset (25) of the GlossaryItems in the database in a table. Each entry in the table will have button/link for modify or delete. At the bottom of the page there will be four buttons. One for add, one for search, one for previous, and one for next. There will be a data entry field for the search. | Add | Will navigate to the AddPage |
| Modify | Will navigate to the ModifyPage pre-populated with the GlossaryItem to be modified. | ||
| Delete | Will navigate to the DeletePage pre-populated with the GlossaryItem to be deleted. | ||
| Next | Will navigate back to the MainPage, displaying the next subset of GlossaryItems. | ||
| Previous | Will navigate back to the MainPage, displaying the prior subset of GlossaryItems. | ||
| Search | Will navigate back to the MainPage, displaying the searched GlossaryItem at the top of the page. If no GlossaryItem is found exactly matching the search term, then the mainpage will display a note that the term could not be found, and display the closest matching results. | ||
| AddPage | This page will be a form that will prompt the user to enter the term and definition. Button/links on this page will consist of cancel, reset, or add. | Add | Will add the GlossaryItem to the database, and then return to the MainPage displaying the item added. |
| Reset | Will clear the data entry fields. | ||
| Cancel | Will return the user to the mainpage. | ||
| ModifyPage | This page will be a form pre-populated and prompt the user to modify either the term or definition. Buttons/Links on this page will consist of cancel and modify. | Modify | Will update the GlossaryItem in the database to contain the modified term or definition, and return to the main page. |
| Cancel | Will return to the main page. | ||
| DeletePage | This page will display the item to be deleted, and will prompt are you sure you want to delete. Buttons/Links on this page will consist of cancel and delete. | Delete | Will delete the Glossary item from the database and return to the main page. |
| Cancel | Will return to the main page. |
To see this application in action, click here.
This version of MyGlossary will add the functionality of categories. Each term will be assignable to zero or more categories.
I have found that this is an important addition, and functionality I would like to use for other pages here. Furthermore, this application will be architected and oriented in such a way as not to assume that it is a stand alone web application, but rather, a web service that will support other pages and applications gaining access to glossary terms and definitions. I came upon this in building the xml web pages. I found that I wanted a table with all of the many xml terms and acronyms. What better a place to pull this information from my glossary. If I only want terms and definitions associated with xml, then I should be able to have a category named xml that only returns terms associated with terms labeled with a category of xml. I also do not want to be able to add, modify, or delete terms on this web page, but merely dump them in a table and presented in the web page. I could see many pages making use of the same functionality. Thus, this application is oriented a little differently as opposed to the original MyGossary. The original MyGlossary assumed CRUD, and all occurring in one application. While the UI from MyGlossary will continue to do what it does quite nicely, I believe that I will have other pages making use of the underlying database. Thus a service.

All of the capabilities of the prior application will be maintained with the addition of the following:
The useful public interfaces (in addition to others) are as follows:
// This method will return a list of GlossaryItems based upon a
// List of Strings representing category names.
public List getCategoryTerms(List catNames);
// This method will return a list of GlossaryItems based upon a
// single String representing the name of a category.
public List getCategoryTerms(String catName);
Both of these interface will be found in the package com.hhartley.myglossaryonefive.service.iface.
MyGlossary OneFive will build upon the application as it already exists, but add pages for managing and manipulating categories as well as basic configuration.
| Page | Notes | Button/Links | Result |
|---|---|---|---|
| MainPage | This page will show a subset (25) of the GlossaryItems in the database in a table. Each entry in the table will have button/link for modify or delete. At the bottom of the page there will be four buttons. One for add, one for search, one for previous, and one for next. There will be a data entry field for the search. | Add | Will navigate to the AddPage |
| Modify | Will navigate to the ModifyPage pre-populated with the GlossaryItem to be modified. | ||
| Delete | Will navigate to the DeletePage pre-populated with the GlossaryItem to be deleted. | ||
| Next | Will navigate back to the MainPage, displaying the next subset of GlossaryItems. | ||
| Previous | Will navigate back to the MainPage, displaying the prior subset of GlossaryItems. | ||
| Search | Will navigate back to the MainPage, displaying the searched GlossaryItem at the top of the page. If no GlossaryItem is found exactly matching the search term, then the mainpage will display a note that the term could not be found, and display the closest matching results. | ||
| Configure | Will navigate to the configure page. | ||
| Filter | A dropdown combobox will cause the list returned to be filtered based upon the category or categories selected. | ||
| AddPage | This page will be a form that will prompt the user to enter the term and definition. Button/links on this page will consist of cancel, reset, or add. | Add | Will add the GlossaryItem to the database, and then return to the MainPage displaying the item added. |
| Reset | Will clear the data entry fields. | ||
| Cancel | Will return the user to the mainpage. | ||
| ModifyPage | This page will be a form pre-populated and prompt the user to modify either the term or definition. Buttons/Links on this page will consist of cancel and modify. | Modify | Will update the GlossaryItem in the database to contain the modified term or definition, and return to the main page. |
| Cancel | Will return to the main page. | ||
| DeletePage | This page will display the item to be deleted, and will prompt are you sure you want to delete. Buttons/Links on this page will consist of cancel and delete. | Delete | Will delete the Glossary item from the database and return to the main page. |
| Cancel | Will return to the main page. | ||
| ConfigurePage | This page will display a list of categories and allow you to add, rename, or remove categories. Configuration will also include the ability to modify the number of rows to show on the main page. | Add | Will add the category typed into the text field into a listbox of categories. |
| Rename | Will rename the current category selected in the lsitbox to whatever is present in the textfield | ||
| Delete | Will remove the current highlighted category. | ||
| Process | Will return to the main page after having update the configuration and categories. |
To see this application in action, click here.