Sam Eldin
Information Technology (IT)
Sam Eldin
- IT Profile
Home CV - Resume Tools 4 Sharing Architects 2 Show Big Data Presentation Android Training Java-Unix Code Templates Interviews QA & Code

My Templates
Executive Summary
A Template - Definition
By Oxford Dictionary:
1) A shaped piece of metal, wood, card, plastic, or other material used as a pattern for processes such as painting, cutting out, shaping, or drilling.
2) Computing: a preset format for a document or file, used so that the format does not have to be recreated each time it is used: a memo template.

By Sam Eldin:
Anything I can reuse or educate myself with that would save time and effort, is a template.
Templates can be old notes, programs, architect, designs, code segment, classes, packages, frameworks, design patterns, websites and web pages, training material or simply ideas that were document in a word file and saved for future use.
The following is a list of some of my Templates that I have created over the years and I would like to share them with my colleagues.

Sam Templates Listings:

Aanlysis Cases Architect Code Frameworks
Requirement Vision Business Case System Architect Unix HTML Markup
Business Plan Summary Use Case Data Structure Java-SQL Prototype
Requirement Test Case Dynamic Business Rules Swing Project Structure
Specifications Test Script Testing, Logger and Architect JavaScript PM Planner

go to top
Under Construction

    1) Bourne Shell Commands 2) Starting Unix 3) UNIX Directory Struture
    4) Intoduction to SHELL PROGRAMMING 5) First Shell Script 6) Unix Shell Loops
    7) Case Statement 8) Change Premission Unix Script 9) Java and Makefile
    10) VI EDITOR 11) Unix PIPES 12) Ant Example -Under Construction

go to top
Under Construction
    1) 2) 3)
    4) 5) 6)
    7) 8) 9)
    10) 11) 12)
    13) 14) 15) InsertSQLStatements.javas
    16) 17) 18)
    10) 20) 21)
    22) 23) 24)
    25) 26) 27)

go to top
Under Construction

swing - command_pattern_w_objects


    1) 2) 3)
    4) 5) 6)

swing - behavior_patterns.command_pattern_w_menu


    1) 2) 3) CommandPanel.html
    4) 5) 6)
    7) 8) 9)
    10) 11) 12)
    13) 14) 15)
    16) 17) 18)

swing - structural_patterns_pdf_facade_pattern


    1) 2) 3)
    4) 5) 6) DummyObject.javas
    7) 8) 9)
    10) 11) 12)

go to top

    1) AddSearchSamLinks.jsp 2) DatesFields.jsp 3) MyTestjsp.jsp
    4) MyUploadDocs.jsp 5) 6)
    7) 8) 9)
    7) 8) SessionExample.jsp 9)

go to top
Requirement Vision
The following are the topics in the Requirement Vision Template:

     • Introduction
     •Document Acronyms
     •Contact Information
     •URL Address & Links
     •Stakeholders and Users
     •Business Position
     •Architect and Design
     •Requirement Visions Control Flow Template

go to top
System Architect
System Architect is the overall system building blocks and interfaces. It represents the system tiers and data flow. System Architect Template should present the following views:

     • Tiers
     • Deployment
     • Data Flow
     • Interfaces
     • Open Source
     • Communication
     • Subsystems
     • Distributed Systems
     • User Interface (UI)
     • Shared libraries
     • Security
     • Performance
     • Testing
     • Assessment
     • Capacity Planning Issues

go to top
Business Plan
The following are the topics in the Business Plan Summary Template:

     • Introduction
     • Executive Summary
     • Proposed System
     • Technology Used
     • Business Description
     • Products/Services
     • Building a Running Model
     • System Components
     • Management Plan
     • Milestones
     • Competition
     • Risk Assessment
     • Business Position
     • Marketing Plan
     • Cost
     • Balance Sheet

go to top
Data Structure
Data structures provide a means to manage large amounts of data efficiently for uses such as large databases and internet indexing services. Usually, efficient data structures are key to designing efficient algorithms. Different kinds of data structures are suited to different kinds of applications, and some are highly specialized to specific tasks.
Developers have to be familiar with different types of data structure and the supporting libraries and functions-code such as Java Collections framework, linked lists, trees, files, etc.
The following are some of criteria for selecting data structure:

     • Physical data
     • Logical data – (Business Entity)
     • Data types
     • Data fields
     • Relationship
     • Tables
     • Databases
     • Queries
     • Keys
     • Files
     • Linked list, trees, ...
     • Memory size
     • Access time

go to top
The following are the topics in the Requirement Template:

          A. Product
          B. System
          C. System characteristic – hardware and software
          A. Common Vocabulary
          B. The system analysis, design and development
          A. Recommendation
          A. Acceptance Criteria
          B. Errors and Exceptions
          C. Accuracy and system tolerance
          A. Technology that will be used to build and run the system
          B. Response to undesired events
          C. Assumptions
          D. Changes
          E. Resources
          F. Nice to have and Have to have features – added code
          G. Standard used.
          H. Statistics
     Design constraints
          A. Design Constraints
          B. Priority – Ranking of Tasks
          C. Time Constraints
     Implementation requirements
          A. Project Phases
     Interface requirements
          A. Interfaces
     Physical requirements.

go to top
Dynamic Business Rules
To simplify our approach to implementing Dynamic Business Rules, we think of rules as formulas needed to do math problems. For example let us look at the following formula:

          A      Rule_X      B      ==>

Rule_X can be stored in a table as follows:

          case 1: Rule_X = + addition
          case 2: Rule_X = * multiplication
          case 3: Rule_X = / division - second rule is "B" cannot have zero value.

These dynamic rules helps your formula performs more tasks without code modification and we can also make it intelligent.
The following image is our framework implementing Dynamic Business Rules where the rules can stored in different systems (Legacy, Database, Files, Web services, ...). These rules are retrieved and translated into business processes which run Java code. The Rules Manager with the help of Vocabulary-Dictionary, plus the WeightScore (value) of each rule translates-maps the rules in lists of maps. Each may have a number of Java functions that perform the actual work. The Validation and Weight calculation (score) can guide the decision making processes.

Dynamic Business Rules Architect

go to top
What is the difference between Requirement and Specification?
The best way to answer this question is by giving an example. Java developers may use Oracle (former Sun Microsystems) code Standards and that is also known as Code Spec.
The following are the topics in the Specs Templates:

     • Product
     • System
     • Performance and Liability
     • Approaches to design
     • Data Structures
     • Hardware
     • Integration
     • Maintenance plans and teams
     • Testing tools and plans
     • Acceptance Criteria
     • Standard Used
     • Business Use Cases
     • Documentation
     • Standards - Code, ...
     • Design Models
     • Test

go to top
Testing Logger Architect
There is new title called Test Architect. The primary responsibility of a test architect is to provide technical leadership and strategic direction for their testing organization. Test architects focus on a diverse set of goals and perform a wide variety of tasks. Some spend time developing testing infrastructure, test authoring frameworks, or evaluating features in order to create complex tests. Some are in charge of a particular technology for their group. A test architect has in-depth knowledge of a variety of testing techniques and methodologies used. A test architect often provides technical assistance and/or advice to the test Manager.

What Software Testing?
Testing is the process of achieving error free system.
There should be a test plan, which includes unit test, stage development testing and system testing.
The design should include testing stages and plans. Testing teams and tools should be available.

Usecase Testing:
Usecase testing is a technique that helps software team identify test cases that exercise the whole system on a transaction by transaction basis from start to finish.

Unit Testing:
Unit test spec is a document, which is for programmers as a guideline on how to test code module.
Unit testing may involve the programmer, group manager and client.

White-box Testing:
White-box testing (also known as clear box testing, glass box testing, transparent box testing and structural testing) tests internal structures or workings of a program, as opposed to the functionality exposed to the end-user. In white-box testing an internal perspective of the system, as well as programming skills, are used to design test cases.
While white-box testing can be applied at the unit, integration and system levels of the software testing process, it is usually done at the unit level.

Black-box testing:
Black-box testing treats the software as a "black box", examining functionality without any knowledge of internal implementation. The tester is only aware of what the software is supposed to do, not how it does it.
Black-box testing methods include:
Equivalence partitioning, boundary value analysis, all-pairs testing, state transition tables, decision table testing, fuzz testing, model-based testing, use case testing, exploratory testing and specification-based testing.

QA testing – Integration Testing:
Unit testing does not take care of all errors due to interfaces and different module calling.
Testing all the modules at once is called integration testing.
Persons other than programmers should do this testing.
There should be dedicated testers whom are part of Quality Assurance group (QA).
QA should be an independent group from the client side, who will sign off on whatever they have tested.
QA testing should be part of the design and planned ahead of time.

Benchmark Testing:
A benchmark testing is to compare the testing performance of the developed system to a previously developed or an existing system testing as reference.

There are certain standards which are followed in almost all the software testing. Having these standards makes life easier for use, because these standards can be converted into checklist and the software testing can be used easily against the checklist. Functionality Tests may include the following tests types.

Stress Testing:
A stress test is to focus on running abnormal conditions as well extreme values that the system may encounter.
Stresses on the system may include the following:

     1. Extreme workloads including max and min integers or floats
     2. Insufficient memory and memory management
     3. Unavailable services and hardware
     4. Infinite loops
     5. Accessing resource that may not be available or limited.
     6. Stress the bottlenecks of the system.
     7. Time Stamp

Structural Testing:
White box testing technique which takes into account the internal structure of a system or component and ensures that each program statement performs its intended function. It is usually performed by the software developers.

System Testing:
The process of testing an integrated hardware and software system to verify that the system meets its specified requirements. It is conducted by the testing teams in both development and target environment.

System Integration Testing:
Testing process that exercises a software system's coexistence with others.

Performance Testing:
Functional testing conducted to evaluate the compliance of a system or component with specified performance requirements.

Breadth Testing:
A test suite that exercises the full functionality of a product but does not test features in detail.

Reliability testing is used to determine the system reliability such as Boundary , Special Case, and Build Verification test (BVT).

What is Boundary Testing?
A test data selection technique in which values are chosen to lie along data extremes. Boundary values include maximum, minimum, just inside/outside boundaries, typical values, and error values. The hope is that, if a systems works correctly for these special values then it will work correctly for all values in between.

Special case:
This used for testing cases that may require special data, values and or sequence of steps.

What is BVT?
Build Verification test is a set of tests run on every new build to verify that build is testable before it is released to test team for further testing. These test cases are core functionality test cases that ensure application is stable and can be tested thoroughly. Typically BVT process is automated. If BVT fails that build is again get assigned to developer for fix.

Thread Testing:
Test for Thread-Safe run. For example, 10 threads would be created and tested to check for deadlock, errors or side effects.

Regression Testing:
Type of software testing that seeks to uncover software errors after changes to the program (e.g. bug fixes or new functionality) have been made, by retesting the program.

Security Testing:
A process to determine that an information system protects data and maintains functionality as intended.
It may have a list of security check points that the system must pass and errors and exceptions handling.

Top Down Integration Testing:
Testing technique that involves starting at the stop of a system hierarchy at the user interface and using stubs to test from the top down until the entire system has been implemented.

Regression Testing:
Type of software testing that seeks to uncover software errors after changes to the program (e.g. bug fixes or new functionality) have been made, by retesting the program.

What is Logging?
Logging refers to the recording of activity. Logging is a common issue for development teams. In the past, write lines or print statements were the only logging tools, but currently there is a number of logging tools such as Log4J, and java.util.logging.Logger. They also come with helpful APIs and structures that can be used with any Java code.

Logging and Testing:
Testing is the process of achieving error free system.
Logging is the process of writing messages to an output (screen, files, SMTP-Mail, sockets or any printable media).

Testing may benefits greatly from logging as a form of tracing tool for errors, warnings, data dump and processing time.
Sadly logging comes with a performance overhead and may be a bottleneck if the media for writing messages would have performance issues. For example, Logging is an I/O intensive activity and can get in the way of the application's performance. With the fact that logging code is synchronized may lead to slowing the system even more.

Using Assertions:
Assertions ensure a program’s validity by catching potential bugs and identifying possible logic errors during development.

To enable assertions at runtime, -ea command-line option is used.

go to top
Business Case
What is a Business Use Case?
What is a Business Actor?
Business Use Case Template


     • Project Manager
     • System Analyst
     • Customer

Business Use Case Control Flow Template:

     1. Brief description
          A short and to point description of the business use case
     2. Business Entity
          How to Describe a Business Unit
     3. Preconditions
          List of conditions that must be met before the start of the business use case
     4. Primary flow of events
          The start and end of a business use case and what it will encounter including errors and how to handle them.
     5. Alternative flow of events
          In case of errors or other things, what are the alternatives?
     6. Post-conditions
          What must be always true after the end of business use case?
     7. Business Actor
          A short and to point description of the actor(s) interfacing with business use case

go to top
Use Case
What is a Use Case?
What is an Actor?
Use Case Template #1
Use Case Template #2

Use Cases Template #1
     Brief description
          A short and to point description of the use case
          List of conditions that must be met before the start of the use case
     Primary flow of events
          The start and end of a use case and what it will encounter including errors and how to
          Handle them.
     Alternative flow of events
          In case of errors or other things, what are the alternatives?
          What must be always true after the end of use case?

Use Cases Template #2
     Use Case Name
          Brief Description
     Flow of Events
          Basic Flow
          Alternative Flows
          First Alternative Flow
          Second Alternative Flow
     Special Requirements
          First special requirement
          Pre-condition One
          Post-condition One
     Extension Points
          Name of extension point

go to top
Test Case
General Technique for Identifying Test Cases:

     • Functionality
     • Performance
     • Security
     • Access
     • Configuration
     • Installation
     • Regression
     • Other

Testing Material:

     • Test Guideline
     • Test Cases
     • Test Data
     • Stages of Testing
     • Test Procedures
     • Test Script
     • Testing Equipments

go to top
Test Script
A Test Script in Software Testing is a set of instructions that will be performed on the System under Test to test that the system functions as expected. These steps can be executed manually or automatically.

A Test Script is a step-by-step description on:

     • What is it
     • What to do
     • How to do it
     • What to expect
     • Validate
     • Comments

Test Script composed of the following:

     1. Introduction
     2. General Details
     3. Objectives
     4. Test Components
     5. Test tasks
     6. Scenarios
     7. Test Plan
     8. Expected Results
     9. Actual Results
     10. Error Log
     11. Validation

go to top
HTML Markup
HTML markup is more of a static prototype which is made up of web pages to present some aspect of the project output web pages, processes or the system flow. It is created using HTML document with its content is used as information elements. Specific tags, denoted by characters within angle brackets, are used to signify the beginning, and end of each element. The following image is Sam Eldin Home page Markup.

Sam Home Page Markup

go to top
In software development, a prototype is a working model of a product or information system, usually built for demonstration purposes or as part of the development process.

We do have a number of prototypes with code ready to be used and the following are some what we have done for reusability:

     • Insurance Framework - Web system
     • Design Patterns Project (PDF doc) - GUI swing desktop Application
     • JSP - session front
     • XML_Parser Project - Web services

The following image shows the InsuranceFramework and the XML_ParserProject where each project has Front (HTML, JSP, js, images, CSS), Server side code (Servlets), Business Object (BO), database Abstract Factory and database Adapter and web services, utils and resources, etc.

Prototype Projects Image

These prototypes and their classes and code are ready to be reused. Architects and Developers may have to modify the code to fit the new requirement, but the saving in term of time and effort can only be imagined.

go to top
Project Structure
The following is an introduction to “Project Structure Template”. It is our attempt to make using PM and Project Structure Template as easy as it can be.

What is a Template?
A Template can be viewed as a model, pattern or form for others to use. The goal of providing a template is to help others perform any number of tasks without having to guess what is needed to be done. It can also be used as a guideline and learning tool for doing a job. In the case of software projects, it is a suggested structure and processes that would help software projects with the following:

     1. Setting a solid structure
     2. Setting the rules for such structure
     3. Setting roles and role playing for project teams
     4. Helping with task assignments
     5. Setting up project processes
     6. Simplifying tasks and processes
     7. Eliminating the guessing game of what should be done
     8. Speeding building of projects
     9. Enhancing project teams performance
     10. Inheriting structure and effort for reusability with future projects

Project Structure Template is composed of:

Main Folders: are the structure of the project and the place holders of project artifacts
Subfolders: are the same as folders, but they belong to a parent folder for hierarchal structure
Folder and Task Doc: a word file that contains documentation about the folder, tasks and processes associated with the folder. For example, this document “SamEldinProjectStructureTemplate” is a word file that provides the explanation of what Project Structure Template is all about and how to use it.
Folder Template: is a word file which is a template or a list of suggested processes, topics, documentation which the project team member may need to perform. Teams are free to use any or all of the suggested processes, topics and documentation and/or add their own. They also free to create documents in any format that is convenient for them. They are free to create word doc files, spreadsheets, HTML or any format of their choice or available. The structure itself can be placed in software such as SourceSafe or any software tool that would help protect ownerships and revisions.

The following image has our CRM project which was created using our Project Structure Template.

Sam Home Page Markup

go to top
PM Planner
Project Management (PM) role came with the territory and I was expected to lead both as a technical lead and a project management. To me Project management is both:

     • Art
     • Science

The art part is God given talent such as intelligence, looks, height, charm, and soft skills as good listener, problem solver, and the list continues.

The science of PM is that PM is a plan that has to be executed, but PM comes with:

Requirement, scope, budget, timeline, resources, deliverable, dependencies, interfaces, workers and calendar.
Estimates, statement of work (SOW), activities, artifacts, master plan, work breakdown structure (WBS), milestones, scheduler, paths, phases, documentation, reports and workflow.
Risks, conflicts and changes.
Assumptions, assessment, project review and release notes.
Meet budget and end the project within budget and on time.

I do have a PM Planner and following link is one of PM tools:

I also created a Project Manager Planner (PMP) for where we combined all the three concepts Project Management Institute (PMI)®, Rational Unified Process (RUP) and Object Oriented (OO) and created a workable practical model that structures, executes, manages, controls and ends software projects. Our Project Manager Planner (PMP) configures a software project into a hierarchical structure with phases. Each phase is composed of PMP classes. Inheritance is passed from super-classes (parent and/or grandparents) to subclasses (child and/or grandchild).