SlideShare a Scribd company logo
i
DECLARATION
This is to declare thatproject work which is done under the supervision of Daniel Mehetote
and having title TourGondar city guide mobile application is the sole contribution of:
BONSA FEKADU
MEDIHANIT KALARO
MERON NEGASH
MINTESNOT KASU
WORKNESH TSEGUYE
No part of the project work has been reproduced illegally (copy and paste) which can be
considered as Plagiarism. All referenced parts have been used to argue the idea and have
cited properly. We will be responsible and liable for any consequence if violation of this
declaration is proven.
Date:_____________________________
Group Members:
Full Name Signature
BONSA FEKADU __________________
MEDIHANIT KALARO __________________
MERON NEGASH __________________
MINTESNOT KASU __________________
WORKNESH TSEGUYE __________________
TOURGONDAR CITY GUIDE MOBILE APPLICATION
ii
CERTIFICATE
This is to certify that this BSc industrial project report entitled TourGondar city guide mobile
application by:
BONSA FEKADU
MEDIHANIT KALARO
MERON NEGASH
MINTESNOT KASU
WORKNESH TSEGUYE
is approved by me for submission. I certify further that, to the best of my knowledge, the
report represents work carried out by these students.
______________________________ __________________________________
Date Name and signature of supervisor
TOURGONDAR CITY GUIDE MOBILE APPLICATION
iii
Acknowledgment
Tour Gondar city guide application would like to thank all our project supporters for this success, it
will not be successful without those who scarified their time, share experience and support with idea
next to God. We also like to express our warmest blessing and appreciation to our advisor Daniel
Mahetot for his patience, good humor and helpful comments, suggestion to finalize this project.
Secondly we would like to thank administration of Gondar city and Tourism office for supporting the
project by giving us the necessary information.
Last but not least our deep gratitude goes to our family who help us by giving moral, economical and
materials support for this project.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
iv
Table of Contents
DECLARATION.......................................................................................................................................... i
CERTIFICATE............................................................................................................................................ ii
Acknowledgment................................................................................................................................... iii
List of Tables......................................................................................................................................... vii
List Of Figure........................................................................................................................................ viii
CHAPTER ONE......................................................................................................................................... 1
1.1. Introduction..................................................................................................................................... 1
1.2. Background...................................................................................................................................... 2
1.3. Statement of the problem............................................................................................................... 3
1.4. Objective of the project................................................................................................................... 3
1.4.1 .General objective ......................................................................................................................... 3
1.4.2 .Specific objective.......................................................................................................................... 3
1.5. Scope of the project ........................................................................................................................ 4
1.6. System Development Methodology................................................................................................4
1.6.1. Investigation (fact-finding) methods............................................................................................5
1.6.2. System Development Tools.......................................................................................................... 5
1.6.2.1. Hardware................................................................................................................................... 5
1.6.2.2. Software .................................................................................................................................... 5
1.7. Significance of the project............................................................................................................... 6
1.8. Beneficiaries .................................................................................................................................... 6
1.9. Time schedule.................................................................................................................................. 7
CHAPTER TWO........................................................................................................................................ 8
2. Requirement Analysis........................................................................................................................ 8
2.1. Introduction..................................................................................................................................... 8
2.2. Current System................................................................................................................................ 8
TOURGONDAR CITY GUIDE MOBILE APPLICATION
v
2.2.1. Major function of current system ................................................................................................8
2.2.2. Problem of existing system .......................................................................................................... 8
2.3. Gathering Information..................................................................................................................... 9
2.3.1 Requirement Gathering Methodologies .....................................................................................10
2.3.2. Result Found............................................................................................................................... 10
2.4. Proposed System........................................................................................................................... 10
2.4.1. Overview..................................................................................................................................... 10
2.4.2 Functional Requirement..............................................................................................................11
2.4.3. Non-Functional Requirement.....................................................................................................11
2.4.3.1. User interface and Human Factors..........................................................................................11
2.4.3.2. Documentation........................................................................................................................ 12
2.4.3.3. Hardware consideration..........................................................................................................12
2.4.3.4. Performance characteristics....................................................................................................12
2.4.3.5. Error Handling and Extreme conditions ..................................................................................12
2.4.3.6. Quality Issues........................................................................................................................... 13
2.4.3.7. System Modifications..............................................................................................................13
2.4.3.8. Physical Environment ..............................................................................................................13
2.4.3.9. Security Issues ......................................................................................................................... 14
2.4.3.10. Resource Issues ..................................................................................................................... 14
2.5. System Model................................................................................................................................ 15
2.5.1. Scenario...................................................................................................................................... 15
2.5.2. Use case Model .......................................................................................................................... 17
2.5.2.1. Use case diagram..................................................................................................................... 17
2.5.2.2. Description of Use case Model................................................................................................19
2.5.3. Activity Diagram ......................................................................................................................... 23
2.5.4. Object Model.............................................................................................................................. 31
2.5.4.1. Data Dictionary........................................................................................................................ 31
2.5.4.2. Class Modeling......................................................................................................................... 32
2.5.4.3. Dynamic Modeling...................................................................................................................34
2.5.5. User Interface............................................................................................................................. 41
CHAPTER THREE ................................................................................................................................... 42
3. System Design............................................................................................................................... 42
TOURGONDAR CITY GUIDE MOBILE APPLICATION
vi
3.1. Introduction................................................................................................................................... 42
3.2. Current software architecture.......................................................................................................42
3.3. Proposed software architecture....................................................................................................42
3.3.1. Overview................................................................................................................................. 42
3.3.2. Subsystem decomposition .....................................................................................................43
3.3.3. Hardware/Software mapping.....................................................................................................45
3.3.4. Persistent data management .....................................................................................................46
3.3.5. Access control and security........................................................................................................49
3.3.6. Subsystem services..................................................................................................................... 50
3.3.7. Detailed class diagram................................................................................................................51
3.3.8. Package....................................................................................................................................... 52
CHAPTER FOUR..................................................................................................................................... 53
4. Implementation................................................................................................................................ 53
4.1. Mapping models to code...............................................................................................................53
4.2. Source codes of major classes, packages or interfaces.................................................................55
4.3. Screen Images..............................................................................................................................109
CHAPTER 5.......................................................................................................................................... 114
5. Conclusion and Recommendation..................................................................................................114
5.1. Conclusion ................................................................................................................................... 114
5.2. Recommendation ........................................................................................................................114
5.3. Bibliography.................................................................................................................................115
Appendix A ......................................................................................................................................... 116
TOURGONDAR CITY GUIDE MOBILE APPLICATION
vii
List of Tables
Table 1 Events..................................................................................................................................... 46
Table 2 hotels ...................................................................................................................................... 46
Table 3 hotels pictures ....................................................................................................................... 46
Table 4 restaurants............................................................................................................................. 46
Table 5 restaurant pictures................................................................................................................47
Table 6 attractions.............................................................................................................................. 47
Table 7 attraction pictures.................................................................................................................47
Table 8 bank........................................................................................................................................ 47
Table 9 bank pictures......................................................................................................................... 47
Table 10 health center........................................................................................................................ 48
Table 11 health center pictures .........................................................................................................48
Table 12 police station........................................................................................................................ 48
Table 13 police station pictures.........................................................................................................48
Table 14 tour and travel agent ..........................................................................................................48
Table 15 TTA pictures ....................................................................................................................... 49
Table 16 Access control and security................................................................................................49
TOURGONDAR CITY GUIDE MOBILE APPLICATION
viii
List of Figure
Figure 1 Time schedule ........................................................................................................................ 7
Figure 2 Use case diagram................................................................................................................18
Figure 3 Update content activity diagram........................................................................................23
Figure 4 Delete content activity diagram .........................................................................................24
Figure 5 Upload content activity diagram........................................................................................25
Figure 6 Change language activity diagram ....................................................................................26
Figure 7 Detect location activity diagram ........................................................................................27
Figure 8 Attraction activity diagram................................................................................................28
Figure 9 Available service activity diagram.....................................................................................29
Figure 10 Search activity diagram....................................................................................................30
Figure 11 High level Class diagram..................................................................................................33
Figure 12 Sequence diagram for updating content .........................................................................37
Figure 13 Sequence diagram for deleting content...........................................................................38
Figure 14 Sequence diagram for uploading content........................................................................39
Figure 15 Sequence diagram for search ...........................................................................................40
Figure 16 Overview of the new system .............................................................................................43
Figure 17 Components diagram for subsystem decomposition......................................................44
Figure 18 Deployment diagram for hardware/software mapping .................................................45
Figure 19 Detailed class diagram.....................................................................................................51
Figure 20 Package diagram...............................................................................................................52
1
CHAPTER ONE
1.1. Introduction
A mobile device, which is also referred to as a handheld device or handheld computer, is a
pint-sized computing device. Mobile devices usually come with a touch or non-touch display
screen and sometimes, even a mini keyboard. There are many types of mobile devices; the
commonest ones are mobile phones, smart phones, PDAs, pagers and Personal Navigation
Devices. PDAs and smart phones are among the most preferred mobile devices, which offer
all the conveniences of a personal computer, along with a very small form factor.
Although mobile phones have taken over our current society, they have been around for
several decades in some form or another. Beginning in the late 1940s, the technology that
would later be used in today’s cell phones was created and the idea of a mobile phone was
introduced. This cell technology was first used in mobile rigs which were mainly used in
taxis, police cars and other emergency vehicles and situations. Truckers also used a form of
this technology to communicate with each other. The first mobile phones, referred to as First
Generation or 1G, were introduced to the public market in 1983 by the Motorola Company.
These first mobile phones used analog technology which was much less reliable than the
digital technology we use today. The analog phones also had a great deal more static and
noise interference than we are accustomed to today. The main purpose of this First
Generation technology was for voice traffic, but consumers felt insecure about people
listening in on their conversations. During the 1990s, great improvements were made in the
mobile phone technology. These phones used Second Generation, or 2G technology. In 1990,
the first cell phone call was made using the new digital technology that became characteristic
of this era. The Second Generation cellular phone technology was faster and much quieter
than its analog predecessor. As a result, it became even more popular than previous models,
too. The new technology also made them capable of being smaller rather than the large
briefcase-sized units from the 1980s.The Third Generation technology, or 3G, is what many
people currently use in their digital cellular phones today. This technology was created very
soon after the excitement that the 2G technology created. This new technology is not only
capable of transferring voice data (such as a phone call), but it is also able to transfer other
types of data, including emails, information and instant messages. There are currently plans
TOURGONDAR CITY GUIDE MOBILE APPLICATION
2
in place to develop a Fourth Generation – 4G – technology. Goals for this new set of
standards include a combination of technologies that will make information transfer and
internet capabilities faster and more affordable for cellular phones.
A mobile application (or mobile app) is a software application designed to run on smart
phone, tablet computer and other mobile devices. They are usually available through
application distribution platforms, which are typically operated by the owner of the mobile
operating system. A mobile operating system (OS) is software that allows smart phones,
tablet Pcs and other devices to run applications and programs. A mobile OS typically starts
up when a device powers on, presenting a screen with icons or tiles that present information
and provide application access. Mobile operating systems also manage cellular and wireless
network connectivity, as well as phone access. Examples of mobile device operating systems
include Apple iOS, Google Android, BlackBerry OS, Nokia’s Symbian, Hewlett-Packard’s
webOS (formerly Palm OS) and Microsoft’s Windows Phone OS. Android is one of the most
popular Linux based mobile operating system.[1]
1.2. Background
The mobile phone device is a very important communication tool as it was built to enhance
social contacts and network while enhancing business productivity. The mobile phone
enables us to be on time during appointments. It also helps in verifying the degree of
temperature to enable us chose appropriate dress code for the day. It keeps us informed on
current events because of its connectivity to the internet. It relaxes it also when we play
games with it or listen to music through it. The mobile device can provide the information
about something and also it detecting the location of the user.
Today, a mobile application plays a great role in our day to day activities. Tour Gondar
application is a city guide mobile application which is run in the smart phones. This
application provides basic information about the services which reside Gondar town like
Hotels, Restaurants, Attraction places, Banks, Tour and Travel agents and Health centers.
The application informs the current events in the town and also it detects the current location
of the users.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
3
1.3. Statement of the problem
Gondar is one of the oldest and historical town in Ethiopian history. In this town there are
money Attraction and Historical places, Hotels ,Restaurants, Banks, Health centers and Tour
and Travel agents and also many events are happen in this town like the great epiphany
ceremony (carnival). But the people which are living in this town and also the visitors cannot
access the information about the service providers and events easily. More specific problem
listed as follows:
 User cannot access well organized information at anywhere about service provider
like Hotels, Restaurants, Attraction and Historical places ,Banks, Health centers and
Tour and Travel Agents.
 User cannot get information about service provider for 24/7 hours.
 When there is a new event(like carnival ceremony) happen in the town the user must
be wait until announced and post in mass media.
 There is no a mechanism a visitor to detect the current location.
 Manually system needs more human power and time.
1.4. Objective of the project
The general and specific objectives of the study are described below.
1.4.1 .General objective
The general objective of this project is to developing a city guide android mobile
application.
1.4.2 .Specific objective
In order to achieve the general objective of this project, the following specific objectives are
addressed.
 The system provide information about service provider either in Amharic or English
language
 The system detect the current location of the user,
 The system provide new update information about events like celebrity;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
4
 The system also provides a city map to user to search a point of interests like
Attractions places, Hotels and Restaurants.
1.5. Scope of the project
Tour Gondar mobile application is software application which is run only in smartphones and
performs the following activities:
 The application gives information about the types of service which is provided by
service provider.
 The application provides a working day, time and location of service providers.
 The application provides new updated information about service providers and
events.
But the application does not include the following activities:
 The application doesn’t provide any information about services provider which is
located outside of Gondar town.
 Tour Gondar application is not operates other language rather than Amharic and
English languages.
1.6. System Development Methodology
Since the entire project requirements are not well known in detail initially, the development
team chooses prototype system development methodology to develop the new system. The
basic idea of prototype model is that a prototype build, test, and then rework as necessary
until an acceptable prototype is finally achieved from which the complete system or product
can now be developed. It is an iterative, trial-and-error process that takes place between the
developers and the users. The most significant advantage of using prototype system
development methodology is listed as follows:
 Users are actively involved in the development.
 Errors can be detects much earlier.
 Quicker user feedback is available leading to better solutions.
 Missing functionality can be identifying easily.
 Confusing or difficult functions can be identifying.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
5
 Since in this methodology a working model of the system is provided, the users get a
better understanding of the system being developed.[2]
1.6.1. Investigation (fact-finding) methods
For gathering information to our project we use different methods.
 Observation: Observation is one of the most important methodologies to gathering
information by physical going to the place and looks how the current system. It can
be very difficult for humans to explain what they do or to even describe accurately
how they achieve a task, so observation very crucial to gathering information.
 Interview: Interview is another important methodology to gathering information by
asking someone a set of questions. It helps us to get critical and important
information about the overall view of the current system.
 Document analysis: This is also another information gathering methodology by
referring the document of the existing system.
1.6.2. System Development Tools
1.6.2.1. Hardware
The system needs different materials to develop the mobile application and to run the system
in the real world, the basic hardware are:
 Personal computer(PC)
 Android platform mobile
 Flash disc
 Digital camera
1.6.2.2. Software
We use the following tools to develop the mobile application:
 Eclipse (IDE)
 MySQL
 Apache
TOURGONDAR CITY GUIDE MOBILE APPLICATION
6
 Edraw-max
 Adobe Photoshop
 Microsoft Word
1.7. Significance of the project
At the end of this project, the application will raise the following significance for the users
and the town.
 The user can access organized information about services at anywhere and at any
time.
 The users (visitors) can easily detecting the current location.
 The user can find the services in a simple user interface.
 When we develop the mobile application there is some significant role in developing
technology by making the society more interact with technology, this leads to the
Gondar town to shift one step in technology.
1.8. Beneficiaries
The most beneficiaries are:
 User: when the users use this mobile application it saves their time and money.
 Town: it will enhance the development of the town in the side of technology.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
7
1.9. Time schedule
Figure 1 Time schedule
8
CHAPTER TWO
2. Requirement Analysis
2.1. Introduction
Requirements analysis, also called requirements engineering, is the process of determining
user expectations for a new or modified product. These features, called requirements, must be
quantifiable, relevant and detailed. In software engineering, such requirements are often
called functional specification.
Requirements analysis is critical to the success of a systems or software project. The purpose
of Requirements Analysis is to obtain a thorough and detailed understanding of the user
needs and to break it down into discrete requirements, which are then clearly define, review
and agree upon with the Customer Decision-Makers. Requirements Analysis provides the
foundation for the desired product or services. [4]
2.2. Current System
2.2.1. Major function of current system
The major functions of the system that are currently available in Gondar town are providing
information manually about the service providers like Hotels, Restaurants, Tour and Travel
agent, Banks and Health centers. Other function of the current system is providing
information about events manually. Bazars, pamphlet papers and mass media are using to
advertising the town. Generally the current system uses a manually system.
2.2.2. Problem of existing system
As we have observed the existing system it is not preferable for the user since everything is
manually. As mention above the current system providing information about the service
providers and events but it is not attractive for the users and it needs more human power to
perform the activity. And also the way of advertising the town cannot address many people.
The major problems which are found in the existing g system listed as follow as:
 Availability: The current system which is existed in Gondar town is not available at
anywhere and at any time. The system does not easily providing information about
TOURGONDAR CITY GUIDE MOBILE APPLICATION
9
the service providers to the user when the user is located outside of Gondar town and
also the system doesn’t work for 24/7 hours.
 Performance: The other problem which is resided in the current system is
performance. We are measuring the performance of the current system in terms time.
The time took by the current system to proving information about the service
provider to user so slow.
 Data Storage mechanism: The data storage mechanism which is used by the existing
system is manually. The current system used more stationary materials like papers
and pen frequently to store data. Because of this the current system spent more cost
for data storage mechanism.
 Efficiency: The other crucial problem which is found in the existing system is
efficiency. We are measuring the efficiency of the current system in terms of
resource: human and time resources. The existing system needs more human power
and time to perform the task like advertising, announcing new information and store
data.
 Security: Since the current system used manually system it is easily expose to
security problem. The existing system used hard copy document to store data and it
may be stole the information by unauthorized user easily and it cause a serious
problem.
2.3. Gathering Information
Different fact finding techniques were used to gathering information about the current
system. It is the fundamental activity for the development of the system. Without them data
modeling cannot be constructed. In order to know how the existing system work and what
problem are there we have been using the following fact-finding techniques.
 Interviewing
 Observations
 Document analysis
TOURGONDAR CITY GUIDE MOBILE APPLICATION
10
2.3.1 Requirement Gathering Methodologies
To develop the new system we have to collect information, to collect information we use
different methodologies.
 Observation: The development team visiting and take look how the manual system
works.
 Interview: The development team interviewed administrator of Gondar town about
how the user gain information about the service provider which available in the
town, what is working time and days of the current system , what kind services are
provided by the current system ,what kind services are not provided by the current
system and also ask the challenge which is found in the current system and we
interviewed manager of tourism office about the general working system of tourism
in Gondar town and also we interviewed some people about how much the current
system is effective.
 Document analysis: The development team also referring the document of the
existing system.
2.3.2. Result Found
After interviewing, observing and analyzing of the current system, the development team
found some results those are listed as below:
 The current system provide information about service providers manually,
 The current system works from Monday to Friday for 7 hours in each day,
 The current system provide information about attraction and historical places
manually and
 The current system needs more time and human power.
2.4. Proposed System
2.4.1. Overview
We would like to create a mobile city guide application. Users of this application will be able
to search services, historical places and other points of interest by using two type of interface:
either a categorized list or by viewing a map. Users can also see more details of a point of
interest when they select it, like a describing text.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
11
2.4.2 Functional Requirement
It is a function or features that must be include in the new system to satisfy the user needs
and also be acceptable to the user and solve the problem in the current system.
The functionality of this system are:
 The system must provide the working time, days and location of the service
providers.
 The system must provide a searching mechanism to the user to find information about
service providers.
 The system must providing information in either Amharic or English.
 The system must provide new updated information about service provider and events.
 The system must provide a map view to users to find the points of interest.
2.4.3. Non-Functional Requirement
It deals with the performance, time, cost and so on. It also describes the importance that is
not directly related to the system.
The non-functionalities of the system are:
 The user can access the information about the service provider with a second.
 Easy user interface to communication with the user.
 The user can access more relevant and reliable information.
 The user can access information at anywhere for 24/7 hours.
2.4.3.1. User interface and Human Factors
When conceptualizing the mobile applications user interface, there are a few things that you
should keep in mind. Some of the basic things such as clarity of interface, consistency from
one view to the next, and making sure that size and uniformity user interface element .
The user interface of mobile application must be easy for the user to use without any
ambiguity. Tour Gondar city guide mobile application having attractive list view, consistent
user interface and few and uniform buttons. Even if the interface is easy to use the customers,
there will be some difficulties in understanding some part of the system like how to use and
TOURGONDAR CITY GUIDE MOBILE APPLICATION
12
accessing the system. So the user must have some level of experience to accesses and use the
system easily and effectively such as:
 The user must have knowledge about how to use the smart phone
2.4.3.2. Documentation
Tour Gondar city guide mobile application provided two documentation which helps to the
user help menu and technical documentation .The help menu providing information to the
user how to use the application. The system might need to be maintained and modified in the
future therefore the maintainers will be provided with technical documentation which are the
analysis, design and implementation documents.
2.4.3.3. Hardware consideration
Tour Gondar City Guide application is deploy in Android 4.2.2 and late versions because
this are the latest’s version for android mobile phone and most people having this versions in
their mobile phone.
Version: Android 4.2.2 versions
Processor: 1GHZ
Memory: at least 512RAM
2.4.3.4. Performance characteristics
The user to access information about the service provider from server it takes only a second.
Since the information is accessed from the database, the new system can support one
thousand users at time and the user can use the system efficiently.
2.4.3.5. Error Handling and Extreme conditions
When the user make an error or extreme condition like that is not allowed by the system, the
system handle error or extreme condition by giving or show an error message and also alert
message to user.
The extreme condition that may occur in this system is:
 Out of range(when the user out of Gondar city),the system doesn’t detect the current
location of the user
TOURGONDAR CITY GUIDE MOBILE APPLICATION
13
2.4.3.6. Quality Issues
The new system is reliable, robust compare with the current system and also when we
observe the current system it’s not always available anywhere and anytime as the new
system.
Availability: The new system providing service to the client without concerning the locations
of the user and also it works for 24 hours.
Reliability: The user of the new system can access more relevant and reliable information
about the services and also it detect the current location accurately.
Robustness: The ability of error detecting of the new system more efficient than current
system. Since new system is based on client server architecture when error occurred we just
concerning manly on server side. For this reason we are saving time to detecting error.
Content Richness: The new system providing rich information about Hotels, Restaurants,
Attraction and historical places and events in the town.
In case of our new system user involvement in the development processes is vital
requirement for the quality of the system.
2.4.3.7. System Modifications
In the future the system can be modified in order to have the following extra features that are
not implementing now.
This can be listed as:
 Enabling the users to detect the current locations using Wi-Fi rather than GPS.
 Enabling the users to viewing offline map rather than online map.
Those new features can be implemented by another programmer or by the team in future.
2.4.3.8. Physical Environment
The System is deploy in each individual smart phone. In order to detect the current location
of the user the system need protection from external factors like those things that does not
make clear line between the device and the sky since the GPS system need a clear line
between the phone and Satellites to detect the location of the user.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
14
2.4.3.9. Security Issues
To protect the application from unauthorized user and malicious attack, we will concern the
security issues into two perspectives: from client and server perspective.
Client perspective
Compared with personal computers or servers, mobile devices store much more sensitive
personal information and are thus attractive targets for attackers seeking financial gain.
Because these devices are always online and have a restricted user interface, it is easier for
attackers to hide their malicious activities. This special issue aims to present high-quality
articles describing security algorithms, protocols, policies, and frameworks for applications
running on modern mobile platforms such as Android, iOS, and Windows Mobile. Security is
a major part of any Android device. Since the system will be hosted on the user smart phone
the user will provide security tools such as antivirus to protect the applications.
Server perspective
An electronic announcement board where authorized users can publish and/or read
announcements. There two types of user, author user and read-only user. The rights of a user
are determined by its type: An author user has the right to create new announcements and to
modify or delete announcements authored by himself. A read-only user has the right to read
all announcements. The announcements are centrally stored in a database server and the
author users and read-only users, can use mobile devices to perform their application related
operations remotely. The core of the application is built on mobile database technology. So
by giving such kind of privilege to the user, we can protect the data in database server from
unauthorized user.
2.4.3.10. Resource Issues
The system has a resource that requires the following performance characteristics:
 The smart phone must have enough memory space to process the application.
 The smart phone must have high processor speed.
 The phone must have a latest version of android OS.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
15
2.5. System Model
A system model is the conceptual model that describes and represents a system. A system
comprises multiple views such as planning, requirement analysis, design, implementation,
deployment, structure, behavior, input data, and output data views. A system model is
required to describe and represent all these multipleviews.
System modeling is intended to assist in developing and maintaining large systems with
emphasis on the Construction phase. The idea is to encapsulate complex or changeable
aspects of a design inside separate components with well-defined interfaces indicating how
each component interacts with its environment. Complete systems are then developed by
composing these components. System modeling can increase reliability and reduce
development cost by making it easier to build systems, to reuse previous built components
within new systems, to change systems to suit changing requirements such as functional
enhancement and platform changes, and to understand systems. In this way, a system model
can satisfy different requirements such as documenting the system, providing a notation for
tools such as consistency checkers and can also be used in the design stage of system
development.[2]
Thus, system modeling is used to ensure that a developing piece of software evolves in a
consistent manner and that the task of integrating software components is simplified.
2.5.1. Scenario
A scenario is a brief narrative, or story, that describes the hypothetical use of a system in one
or more paragraph.
Scenario for update content
Scenario name: Update content
Actor: Administrator
Flow event: 1. Administrator request for updating.
2. The system verifies if the user is authorized or not.
3. The system allows to updating the content.
4. Administrator updates the content.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
16
Scenario for delete content
Scenario name: Delete content
Actor: Administrator
Flow event: 1. Administrator request for deleting.
2. The system verifies if the user is authorized or not.
3. The system allow to deleting the content
4. Administrator deletes the content.
Scenario for upload content
Scenario name: Upload content
Actor: Administrator
Flow event: 1. Administrator request for upload.
2. The system verifies if the user is authorized or not.
3. The system allows to uploading the content.
4. Administrator uploads the content
Scenario for change language
Scenario name: Change language
Actor: User
Flow event: 1. User touches on link which is allowed to change the language.
2. The system changed into the selected language.
Scenario for detect location
Scenario name: Detect location
Actor: User
Flow event: 1. User starts the application.
2. The system starts detecting the current location.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
17
3. The system displays the current location.
Scenario for Attractions
Scenario name: Attractions
Actor: User
Flow event: 1. User touches on attraction link.
2. The system listed different attractions and historical places.
3. The user selects one of the types.
4. The system display basic information about the particular place.
Scenario for Available services
Scenario name: Available services
Actor: User
Flow event: 1. User touches on service link.
2. The system listed different available services.
3. The user selects one of the types.
4. The system display basic information about the particular service.
2.5.2. Use case Model
2.5.2.1. Use case diagram
Use case diagram is a visual depiction of the different scenarios of the interaction between
actor and use case. An actor is an idealization of an external person, process, things that
interact with the system or subsystem. A use case is logical description of the slice of the
system functionality.[3]
TOURGONDAR CITY GUIDE MOBILE APPLICATION
18
Figure 2 Use case diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
19
2.5.2.2. Description of Use case Model
Actor description
Name: Administrator
Description: A person who is responsible for updating, deleting, and uploading information.
Name: User
Description: Someone who wants to visit Gondar town. She/he can access information about
the service providers and events in Gondar town.
Use case description
Use case Name: Update Content
Actor: Administrator
Description: Administrator changes some new information to the application.
Precondition: Administrator should have some new information to add in the
application.
Main sequence: 1. Administrator makes a link to the database.
2. Administrator enters valid user name and password.
3. Administrator changes the old information by the new one.
4. Post the new information to the application.
5. Use case ends.
Alternative sequence: 2. Invalid inputs, system display invalid user name and password.
Post condition: New information is added.
Use case Name: Delete Content
Actor: Administrator
Description: Administrator deleting unnecessary information from the application.
Precondition: Administrator should have some data to be deleted.
Main sequence: 1. Administrator makes a link to the database.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
20
2. Administrator enters a valid user name and password.
3. The administrator deletes some data from the existed one which is
Unnecessary currently.
4. Display to the application.
5. Use case ends.
Alternative sequence: 2. Invalid input system display invalid user name and password.
Post condition: Data is deleted successfully.
Use case Name: Upload Content
Actor: Administrator
Description: Administrator adds a new data to the application.
Precondition: Administrator should have new information to add in the application.
Main sequence: 1 .Administrator makes a link to the database.
2. Administrator enters valid user name and password.
3. Administrator adds new data.
4. Display to the application.
5. Use case ends
Alternative sequence: 2. Invalid input. System display invalid user name and password
Post condition: New information is added successfully.
Use case Name: Change Language
Actor: User
Description: The user can change the language either Amharic or English.
Precondition: Home screen displayed with “ወደአማርኛ” or “To English ” button.
Main sequence: 1. User touch on ወደአማርኛ or To English button.
2. The application changed into the selected language.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
21
3. Use case ends.
Alternative sequence: 1.If the user does not want to change language, he/she will not be
touch on “ወደአማርኛ” or “To English” button.
Post condition: Language successfully changed.
Use case Name: Detect Location
Actor: User
Description: The user can detect the current location automatically in every 10 meters.
Precondition: The user should run the application.
Main sequence: 1. User run the application.
2. The system automatically detecting the current location in every 10
meters.
3. Use case ends.
Alternative sequence: 1. Out of Range location, system display “You are out Reach” alert
message.
Post condition: The system displays the current location.
Use case Name: Attraction
Actor: User
Description: User can access basic information about attraction and historical place.
Precondition: Home screen displayed with Attraction link.
Main sequence: 1. User touch on Attraction link.
2. The System listed attracting and historical place.
3. Select one of type.
4. System display information about particular place.
5. Use case ends.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
22
Alternative sequence: 1.If user does not want to see attracting and historical place, he/she
will not be touch on Attraction link.
Post condition: System display basic information about particular place
Use case Name: Available Service
Actor: User
Description: User selects the serviceto get information about the service provider.
Precondition: Home screen displayed with servicelink.
Main sequence: 1 .User touch on servicelink.
2. The system listed different service provider.
3. Select one of the types.
4. System display information about a particular service provider.
5. Use case ends.
Alternative sequence: 2.If the user does not want to get information about the service, he/she
will not be touch on service link
Post condition: System display basic information about a particular service.
Use case Name: Search
Actor: User
Description: The user enters the text in search text field and the system retrieves
information from the database that match with the input text.
Precondition: The search text field appears on each service screen.
Main sequence: 1.The user enters the text in the search text field.
2. Touch on filter button.
3. Use case ends.
Alternative sequence: 2. Mismatch input text.
Post condition: The system retrieves information that match with the input text.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
23
2.5.3. Activity Diagram
Activity diagram is basically a flow chart to represent the flow form one activity to another
activity. The activity can be described as an operation of the system.[3]
.
Figure 3 Update content activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
24
Figure 4 Delete content activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
25
Figure 5 Upload content activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
26
Figure 6 Change language activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
27
Figure 7 Detect location activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
28
Figure 8 Attraction activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
29
Figure 9 Available service activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
30
Figure 10 Search activity diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
31
2.5.4. Object Model
2.5.4.1. Data Dictionary
User –has the following attributes
 Name
 Location
Administrator-has the following attributes
 User Name
 Password
Location detector -has the following attributes
 Outdoor
Language-has the following attributes
 Amharic Label
 English Label
Events-has the following attributes
 Cultural event
 Religious event
 Institutional event
Service provider-has the following attributes
 Name
 Location
 Phone no.
 Email
 Web site
Hotels- has the following attributes
 Hotels_services
Restaurant- has the following attributes
 Restaurant_services
TOURGONDAR CITY GUIDE MOBILE APPLICATION
32
Police station- has the following attributes
 Police_services
Bank- has the following attributes
 Bank_services
Health center- has the following attributes
 Medical_services
Hospital- has the following attributes
 Examine
 Bed_room
Clinic- has the following attributes
 Drugs_shop
Tour and Travel agent- has the following attributes
 Tour_services
 Car_rentals
Attraction- has the following attributes
 Cultural
 Natural
Pictures - has the following attributes
 Category
 Image
2.5.4.2. Class Modeling
The purpose of the class diagram is to model the static view of an application. The class
diagrams are the only diagrams which can be directly mapped with object oriented languages
and thus widely used at the time of construction.[3]
TOURGONDAR CITY GUIDE MOBILE APPLICATION
33
High level Class diagram for the new system.
Figure 11 High level Class diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
34
2.5.4.3. Dynamic Modeling
State chart diagram
Figure 12 state chart diagrams for administrator
TOURGONDAR CITY GUIDE MOBILE APPLICATION
35
Figure 13 State chart diagram for users
TOURGONDAR CITY GUIDE MOBILE APPLICATION
36
Sequence Diagram
A sequence diagram is an interaction diagram that shows how processes operate with one
another and in what order. It is a construct of a Message Sequence Chart. A sequence
diagram shows object interactions arranged in time sequence. It depicts the objects and
classes involved in the scenario and the sequence of messages exchanged between the objects
needed to carry out the functionality of the scenario. Sequence diagrams are typically
associated with use case realizations in the Logical View of the system under development.
Sequence diagrams are sometimes called event diagrams, event scenarios
A sequence diagram shows, as parallel vertical lines (lifelines), different processes or objects
that live simultaneously, and, as horizontal arrows, the messages exchanged between them, in
the order in which they occur. This allows the specification of simple runtime scenarios in a
graphical manner.[3]
TOURGONDAR CITY GUIDE MOBILE APPLICATION
37
Here is some sequence diagram of the new system.
Figure 12 Sequence diagram for updating content
TOURGONDAR CITY GUIDE MOBILE APPLICATION
38
Figure 13 Sequence diagram for deleting content
TOURGONDAR CITY GUIDE MOBILE APPLICATION
39
Figure 14 Sequence diagram for uploading content
TOURGONDAR CITY GUIDE MOBILE APPLICATION
40
Figure 15 Sequence diagram for search
41
2.5.5. User Interface
Figure 16 User interface
TOURGONDAR CITY GUIDE MOBILE APPLICATION
42
CHAPTER THREE
3. System Design
3.1. Introduction
Systems design is the process of defining the architecture, components, modules, interfaces,
and data for a system to satisfy specified requirements. The System Design Document
describes the system requirements, operating environment, system and subsystem
architecture, files and database design, input formats, output layouts, human-machine
interfaces, detailed design, processing logic, and external interfaces.
In this chapter we try to discuss the design part and also we see the architecture part. After
this has been done, the analysis was completed using different UML diagram. System design
is the first step to get into the solution domain. In this document we will try to describe the
design aspect of the new system.[2]
3.2. Current software architecture
In the city currently there is no any software in use to guide the city for the users.
3.3. Proposed software architecture
3.3.1. Overview
We try show the bird’s eye view of the new system so that, the software architecture for each
subsystem functionality will be the following.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
43
Figure 16 Overview of the new system
3.3.2. Subsystem decomposition
Component diagram is a special kind of diagram in UML. It does not describe the
functionality of the system but it describes the components used to make those
functionalities.
So from that point component diagrams are used to visualize the physical components in a
system. Component diagrams can also be described as a static implementation view of a
system. Static implementation represents the organization of the components at a particular
moment.
Use component diagram to partition a system into subcomponents. The main subsystem of
the system list as follows:
 User Interface subsystem
 Database subsystem
 Account Management subsystem.[3]
TOURGONDAR CITY GUIDE MOBILE APPLICATION
44
Figure 17 Components diagram for subsystem decomposition
TOURGONDAR CITY GUIDE MOBILE APPLICATION
45
3.3.3. Hardware/Software mapping
Deployment diagrams are used for describing the hardware components where software
components are deployed.[3]
Figure 18 Deployment diagram for hardware/software mapping
TOURGONDAR CITY GUIDE MOBILE APPLICATION
46
3.3.4. Persistent data management
Persistence modeling is used to communicate the design of the database, usually to the
developers. It is also used to describe the persistence data aspect of the system.
Scheme diagram
Events
Information Pictures
Table 1 Events
Hotels
Hotels-name Location Phone_no e-mail Hotel_services
Table 2 hotels
Hotel pictures
Hotels-name Category pictures
Table 3 hotels pictures
Restaurants
Restu-name Location Phone_no e-mail Restuarant_services
Table 4 restaurants
TOURGONDAR CITY GUIDE MOBILE APPLICATION
47
Restaurant pictures
Restu-name Category pictures
Table 5 restaurant pictures
Attractions
Att-name Location Phone_no e-mail Services
Table 6 attractions
Attraction pictures
Att-name Category pictures
Table 7 attraction pictures
Bank
Bank-name Location Phone_no e-mail Bank_services
Table 8 bank
Bank pictures
Bank-name Category pictures
Table 9 bank pictures
TOURGONDAR CITY GUIDE MOBILE APPLICATION
48
Health centers
HealthCenter-name Location Phone_no e-mail Medical_services
Table 10 health center
Health center pictures
HealthCenter-name Category pictures
Table 11 health center pictures
Police station
Poli-name Location Phone-no e-mail Police_services
Table 12 police station
Police station pictures
Poli-name Category pictures
Table 13 police station pictures
Tour and Travel agent
TTA-name Location Phone_no e-mail Tour_services Car_rental
Table 14 tour and travel agent
TOURGONDAR CITY GUIDE MOBILE APPLICATION
49
TTA pictures
TTA-name Category Pictures
Table 15 TTA pictures
3.3.5. Access control and security
In this new system different actor have access to different functionality and data. Who can
access what is by using an access control matrix is describe in the following table. The
following table describes an actor who is involved in the scene and the possible benefit
assigned to the actor.
Actor Privilege
User requestToView();
Administrator uploadData();
updataData();
deleteData();
Table 16 Access control and security
TOURGONDAR CITY GUIDE MOBILE APPLICATION
50
3.3.6. Subsystem services
In this section try to cover the main subsystems that are used in the system and the service
provide by each subsystem. Those are:
 User interface subsystem: this subsystem used to interact the user with system and it
is majorly connected with the database subsystem for displaying up to date
information that is stored in database.
 Database subsystem: this subsystem is used to perform the task that is performed by the
administrator. The tasks that are performed in the database are updating information such as
deleting and uploading information.
 Account management subsystem: this subsystem is used to perform user management
and validating there account.
TOURGONDAR CITY GUIDE MOBILE APPLICATION
51
3.3.7. Detailed class diagram
Figure 19 Detailed class diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
52
3.3.8. Package
Package diagram is UML structure diagram which shows packages and dependencies
between the packages. Package diagram enables you to gain a high level understanding of the
collaboration among model elements through analyzing the relationships among their parent
package. This also helps explain the system's architecture from a broad view.[3]
Figure 20 Package diagram
TOURGONDAR CITY GUIDE MOBILE APPLICATION
53
CHAPTER FOUR
4. Implementation
4.1. Mapping models to code
The system has the following actors.
 Administrator
 User
The administrator who controls all over the system and access the tables in the database these
are:
Administrator
Figure 22 Mapping model for administrator
Notice: The administrator has permission of managing or controlling the application and it
has one to one relationship.
Events
Hotels
Restaurants
Attractions
Banks
Health Centers
Tour and Travel agent
TOURGONDAR CITY GUIDE MOBILE APPLICATION
54
The users can view and access information from the database.
User
Figure 23 Mapping model for User
Notice: The user has the permission to view information that is filled by administrator.It has
one to one relationship.
Events
Hotels
Restaurants
Attractions
Banks
Health Centers
Tour and Travel agent
TOURGONDAR CITY GUIDE MOBILE APPLICATION
55
4.2. Source codes of major classes, packages or interfaces
//Android manifest file for Gondar city guide application
<?xmlversion="1.0"encoding="utf-8"?>
<manifestxmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.gondarcityguide"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="17"/>
<permissionandroid:name="com.example.gondarcityguide.permission.MAPS_RECEIVE"
android:protectionLevel="signature"/>
<uses-
permissionandroid:name="com.example.gondarcityguide.permission.MAPS_RECEIVE"/>
<uses-permissionandroid:name="android.permission.INTERNET"/>
<uses-permissionandroid:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-
permissionandroid:name="com.google.android.providers.gsf.permission.READ_GSERVICE
S"/>
<uses-permissionandroid:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permissionandroid:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permissionandroid:name="android.permission.ACCESS_FINE_LOCATION"/>
<uses-feature
android:glEsVersion="0x00020000"
android:required="true"/>
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme">
<activity
android:name="com.example.gondarcityguide.Home_Eng"
android:label="@string/app_name">
<intent-filter>
<actionandroid:name="android.intent.action.MAIN"/>
TOURGONDAR CITY GUIDE MOBILE APPLICATION
56
<categoryandroid:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<activityandroid:name=".Home_Amh"android:label="ጎንድርንይጎብኙ"></activity>
<activityandroid:name=".Hotel_Eng"android:label="Hotels"android:icon="@drawable/hotel
s"></activity>
<activityandroid:name=".Hotel_Amh"android:label="ሆቴል"android:icon="@drawable/hotels
"></activity>
<activityandroid:name=".Restaurant_Eng"android:label="Restaurants"android:icon="@dra
wable/resturant"></activity>
<activityandroid:name=".Restaurant_Amh"android:label="ሬስቶራንት"android:icon="@drawa
ble/resturant"></activity>
<activityandroid:name=".Attraction_Eng"android:label="Attractions"android:icon="@draw
able/attraction"></activity>
<activityandroid:name=".Attraction_Amh"android:label="መስብ"android:icon="@drawable/a
ttraction"></activity>
<activityandroid:name=".Bank_Eng"android:label="Banks"android:icon="@drawable/bank"
></activity>
<activityandroid:name=".Bank_Amh"android:label="ባንክ"android:icon="@drawable/bank">
</activity>
<activityandroid:name=".FourSistersRestaurant_Eng"android:label="Four Sisters
Restaurant"android:icon="@drawable/resturant"/>
<activityandroid:name=".FourSistersRestaurant_Amh"android:label="ፎርሲስተር
"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".MasterChefRestaurant_Eng"android:label="Master Chef
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".MasterChefRestaurant_Amh"android:label="ማስተርቼፍ"android:ico
n="@drawable/resturant"></activity>
<activityandroid:name=".DashenBreweryRestaurant_Eng"android:label="Dashen Brewery
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".DashenBreweryRestaurant_Amh"android:label="ዳሽንቢራ"android:i
con="@drawable/resturant"></activity>
<activityandroid:name=".GohaHotelRestaurant_Eng"android:label="Goha Hotel
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".GohaHotelRestaurant_Amh"android:label="ጎሃሆቴልሬስቶራንት"androi
d:icon="@drawable/resturant"></activity>
<activityandroid:name=".TayeBelayHotelRestaurant_Eng"android:label="Taye Belay Hotel
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".TayeBelayHotelRestaurant_Amh"android:label="ታዬበላይሆቴልሬስቶራ
ንት"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".HashBazRestaurant_Eng"android:label="Hash-Baz
Restaurant"android:icon="@drawable/resturant"></activity>
TOURGONDAR CITY GUIDE MOBILE APPLICATION
57
<activityandroid:name=".HashBazRestaurant_Amh"android:label="ሀሽ -
ባዝ"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".EliltaCulturalRestaurant_Eng"android:label="Elilta Cultural
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".EliltaCulturalRestaurant_Amh"android:label="እልልታየባህልሬስቶራንት
"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".HabeshaKitfoRestaurant_Eng"android:label="Habesha Kitfo
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".HabeshaKitfoRestaurant_Amh"android:label="ሀበሻክትፎ
ሬስቶራንት"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".MiniFogeraRestaurant_Eng"android:label="Mini Fogera
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".MiniFogeraRestaurant_Amh"android:label="ሚኒፎገራሬስቶራንት"andr
oid:icon="@drawable/resturant"></activity>
<activityandroid:name=".HabeshaCoffeeRestaurant_Eng"android:label="Habesha Coffee
Restaurant"android:icon="@drawable/resturant"/>
<activityandroid:name=".HabeshaCoffeeRestaurant_Amh"android:label="ሀበሻኮፊሬስቶራንት
"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".CircleHotelRestaurant_Eng"android:label="Circle Hotel
Restaurant"android:icon="@drawable/resturant"></activity>
<activityandroid:name=".CircleHotelRestaurant_Amh"android:label="ሰርክልሆቴልሬስቶራንት"an
droid:icon="@drawable/resturant"></activity>
<activityandroid:name=".AgHotel_Eng"android:label="AG
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".AgHotel_Amh"android:label="ኤጂሆቴል"android:icon="@drawable/
hotels"></activity>
<activityandroid:name=".LShapeHotel_Eng"android:label="L-Shape
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".LShapeHotel_Amh"android:label="ኤል-
ሼፕሆቴል"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".FloridaHotel_Eng"android:label="Florida International
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".FloridaHotel_Amh"android:label="ፍሎሪዳኢተርናሽናልሆቴል"android:ic
on="@drawable/hotels"></activity>
<activityandroid:name=".TayeBelayHotel_Eng"android:label="Taye Belay
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".TayeBelayHotel_Amh"android:label="ታዬበላይሆቴል"android:icon="
@drawable/hotels"></activity>
<activityandroid:name=".GohaHotel_Eng"android:label="Goha
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".GohaHotel_Amh"android:label="ጎሃሆቴል"android:icon="@drawabl
e/hotels"></activity>
<activityandroid:name=".QuaraHotel_Eng"android:label="Quara
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".QuaraHotel_Amh"android:label="ቋራሆቴል"android:icon="@drawa
ble/hotels"></activity>
TOURGONDAR CITY GUIDE MOBILE APPLICATION
58
<activityandroid:name=".NewFesicaHotel_Eng"android:label="New Fesica
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".NewFesicaHotel_Amh"android:label="ኒውፋሲካሆቴል"android:icon="
@drawable/hotels"></activity>
<activityandroid:name=".YalewAykerHotel_Eng"android:label="Yalew Ayker
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".YalewAykerHotel_Amh"android:label="ያለውአይቀርሆቴል"android:ico
n="@drawable/hotels"></activity>
<activityandroid:name=".LammergeyerHotel_Eng"android:label="Lammergeyer
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".LammergeyerHotel_Amh"android:label="ላመርገየርሆቴል"android:ico
n="@drawable/hotels"></activity>
<activityandroid:name=".FogeraHotel_Eng"android:label="Fogera
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".FogeraHotel_Amh"android:label="ፎገራሆቴል"android:icon="@draw
able/hotels"></activity>
<activityandroid:name=".CircleHotel_Eng"android:label="Circle
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".CircleHotel_Amh"android:label="ሰርክልሆቴል"android:icon="@dra
wable/hotels"></activity>
<activityandroid:name=".QueensHotel_Eng"android:label="Queens
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".QueensHotel_Amh"android:label="ኪዊስሆቴል"android:icon="@dra
wable/hotels"></activity>
<activityandroid:name=".LandmarkHotel_Eng"android:label="Landmark
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".LandmarkHotel_Amh"android:label="ጎንደርላድማርክሆቴል"android:ico
n="@drawable/hotels"></activity>
<activityandroid:name=".JantekleHotel_Eng"android:label="Jantekle
Hotel"android:icon="@drawable/hotels"></activity>
<activityandroid:name=".JantekelHotel_Amh"android:label="ጃንተክልሆቴል"android:icon="@d
rawable/hotels"></activity>
<activityandroid:name=".DebreBerhanSelassie_Eng"android:label="Debre Berhan
Selassie"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".DebreBerhanSelassie_Amh"android:label="ደብረብርሃንስላሴ
"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".SimenLandTour_Eng"android:label="Simen Land
Tour"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".SimenLandTour_Amh"android:label="የሰሜንተራሮች"android:icon="
@drawable/attraction"></activity>
<activityandroid:name=".FasilGehbbi_Eng"android:label="Fasil
Gehbbi"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".FasilGehbbi_Amh"android:label="ፋሲልግቢ"android:icon="@drawa
ble/attraction"></activity>
<activityandroid:name=".FasiladasBath_Eng"android:label="Fasiladas Bath
Timket"android:icon="@drawable/attraction"></activity>
TOURGONDAR CITY GUIDE MOBILE APPLICATION
59
<activityandroid:name=".FasiladasBath_Amh"android:label="የፋሲለደስመዋኛገንዳ"android:icon
="@drawable/attraction"></activity>
<activityandroid:name=".Gondar_Eng"android:label="Gondar"android:icon="@drawable/a
ttraction"></activity>
<activityandroid:name=".Gondar_Amh"android:label="ጎንደር"android:icon="@drawable/attr
action"></activity>
<activityandroid:name=".AtseBekefa_Eng"android:label="Atse
Bekefa"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".AtseBekefa_Amh"android:label="አዔባካፋየባህልምሽት
"android:icon="@drawable/attraction"></activity>
<activityandroid:name=".Event_Eng"android:label="Events"></activity>
<meta-data
android:name="com.google.android.maps.v2.API_KEY"
android:value="Your api key"/>
<meta-dataandroid:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
</application>
</manifest>
//Source code for Get JSON object from URL
package com.example.gondarcityguide;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.util.List;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.NameValuePair;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.client.utils.URLEncodedUtils;
import org.apache.http.impl.client.DefaultHttpClient;
import org.json.JSONException;
import org.json.JSONObject;
import android.util.Log;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
60
publicclass JSONParser {
static InputStream is=null;
static JSONObject jObj=null;
static String json="";
// constructor
public JSONParser(){
}
// function get json from url
// by making HTTP POST or GET mehtod
public JSONObject makeHttpRequest(String url,String
method,List<NameValuePair>params){
// Making HTTP request
// check for request method
try{if(method=="POST")
{
// request method is POST
// defaultHttpClient
DefaultHttpClient httpClient = newDefaultHttpClient();
HttpPost httpPost = newHttpPost(url);
httpPost.setEntity(new UrlEncodedFormEntity(params));
HttpResponse httpResponse = httpClient.execute(httpPost);
HttpEntity httpEntity = httpResponse.getEntity();
is = httpEntity.getContent();
}elseif(method == "GET"){
// request method is GET
DefaultHttpClient httpClient = newDefaultHttpClient();
String paramString = URLEncodedUtils.format(params, "utf-8");
url += "?" + paramString;
HttpGet httpGet = newHttpGet(url);
HttpResponse httpResponse = httpClient.execute(httpGet);
HttpEntity httpEntity = httpResponse.getEntity();
is = httpEntity.getContent();
}
TOURGONDAR CITY GUIDE MOBILE APPLICATION
61
}catch(UnsupportedEncodingException e)
{
e.printStackTrace();
}catch(ClientProtocolException e)
{
e.printStackTrace();
}catch(IOException e)
{
e.printStackTrace();
}
try{
//BufferedReader reader = new BufferedReader(new InputStreamReader(is,
"iso-8859-1"), 8);
BufferedReader reader = newBufferedReader(new InputStreamReader(is,
"UTF-8"), 8000);
StringBuilder sb = newStringBuilder();
String line = null;
while ((line = reader.readLine()) != null) {
sb.append(line + "n");
}
is.close();
json = sb.toString();
}catch(Exception e)
{
Log.e("Buffer Error", "Error Converting Result"+e.toString());
}
// try parse the string to a JSON object
try {
jObj=new JSONObject(json);
} catch (JSONException e) {
Log.e("JSON Parse", "Error parsing"+e.toString());
}
// return JSON String
returnjObj;
}
}
//Source code for Home Screen in English java code
package com.example.gondarcityguide;
import android.os.Bundle;
import android.app.Activity;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
62
import android.content.Intent;
importandroid.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.Button;
importandroid.widget.ImageButton;
import android.widget.ListView;
importandroid.widget.TextView;
publicclass Home_Eng extends Activity implements OnItemClickListener {
ListView listView;
Button eventBtnEng;
Button btnAmahric;
String[] title={"Attractions",
"Hotels",
"Restaurants",
"Banks",
"Tour and Travel Agents",
"Health Centers",
"Police Stations"};
Integer[] imageId={R.drawable.attraction,
R.drawable.hotels,
R.drawable.resturant,
R.drawable.bank,
R.drawable.tour,
R.drawable.health,
R.drawable.police};
@Override
protectedvoid onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.home__eng);
CustomListHomeEng
adapter=newCustomListHomeEng(Home_Eng.this,title,imageId);
listView=(ListView) findViewById(R.id.listHomeEng);
listView.setAdapter(adapter);
listView.setOnItemClickListener(this);
btnAmahric=(Button) findViewById(R.id.btnAmahric);
btnAmahric.setOnClickListener(new OnClickListener() {
@Override
TOURGONDAR CITY GUIDE MOBILE APPLICATION
63
publicvoid onClick(View arg0) {
startActivity(new Intent(getApplicationContext(),
Home_Amh.class));
}
});
eventBtnEng=(Button) findViewById(R.id.eventBtnEng);
eventBtnEng.setOnClickListener(new OnClickListener() {
@Override
publicvoid onClick(View arg0) {
startActivity(new Intent(getApplicationContext(),
Event_Eng.class));
}
});
}
@Override
publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) {
// TODO Auto-generated method stub
//use switch to launch different Activity
switch(position){
case 0:
Intent att = newIntent(getApplicationContext(), Attraction_Eng.class);
startActivity(att);
break;
case 1:
Intent hotel = newIntent(getApplicationContext(), Hotel_Eng.class);
startActivity(hotel);
break;
case 2:
Intent res = newIntent(getApplicationContext(),
Restaurant_Eng.class);
startActivity(res);
break;
case 3:
Intent bank = newIntent(getApplicationContext(), Bank_Eng.class);
startActivity(bank);
break;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
64
default:
break;
}
}
}
//Xml file for Home Screen in English
<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
tools:context=".Home_Eng">
<TextViewandroid:id="@+id/textLang"
android:layout_width="150dp"
android:layout_height="38dp"
android:text="Language Option"
android:paddingLeft="20dp"
android:paddingTop="10dp"
android:layout_alignParentTop="true"
android:textAlignment="center"
android:textSize="15dp"/>
<Button
android:id="@+id/btnAmahric"
android:layout_width="174dp"
android:layout_height="38dp"
android:background="@drawable/toamahricbtn"
android:textAlignment="center"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
/>
<ImageView
android:id="@+id/imageView1"
android:layout_width="fill_parent"
android:layout_height="170dp"
TOURGONDAR CITY GUIDE MOBILE APPLICATION
65
android:layout_alignParentLeft="true"
android:src="@drawable/homegondarimageenglish"
android:adjustViewBounds="true"
android:scaleType="fitXY"
android:layout_below="@+id/btnAmahric"
/>
>
<ListView
android:id="@+id/listHomeEng"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_below="@+id/cityMapBtnEng"
android:paddingTop="10dp">
</ListView>
<Button
android:id="@+id/cityMapBtnEng"
android:layout_width="150dp"
android:layout_height="40dp"
android:layout_below="@+id/imageView1"
android:layout_alignParentRight="true"
android:background="@drawable/citymapbtnenglish"/>
<Button
android:id="@+id/eventBtnEng"
android:layout_width="150dp"
android:layout_height="40dp"
android:layout_alignParentLeft="true"
android:layout_below="@+id/imageView1"
android:background="@drawable/eventsbtnenglish"/>
</RelativeLayout>
//Source code for Home Screen in Amharic java code
package com.example.gondarcityguide;
import android.app.Activity;
importandroid.app.ListActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
66
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.Button;
import android.widget.ImageButton;
import android.widget.ListView;
publicclass Home_Amh extends Activity implements OnItemClickListener {
ListView listView;
ImageButton eventImageBtn;
String[] title={ "መስብ",
"ሆቴል",
"ሬስቶራንት",
"ባንክ",
"አስጎብኚድርጅት",
"የጤናተቀም",
"ፖሊስጣቢያ",
};
Integer[] imageId={R.drawable.attraction,
R.drawable.hotels,
R.drawable.resturant,
R.drawable.bank,
R.drawable.tour,
R.drawable.health,
R.drawable.police};
@Override
protectedvoid onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.home_amh);
CustomListHomeAmh adapter=newCustomListHomeAmh(Home_Amh.this,
title, imageId);
listView=(ListView) findViewById(R.id.listHomeAmh);
listView.setAdapter(adapter);
listView.setOnItemClickListener(this);
Button btnToEnglish=(Button) findViewById(R.id.btnEnglish);
btnToEnglish.setOnClickListener(new OnClickListener() {
@Override
publicvoid onClick(View arg0) {
startActivity(new Intent(getApplicationContext(),
Home_Eng.class));
}
TOURGONDAR CITY GUIDE MOBILE APPLICATION
67
});
}
@Override
publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) {
//use switch to launch different activity
switch(position)
{
case 0:
startActivity(new Intent(getApplicationContext(),
Attraction_Amh.class));
break;
case 1:
startActivity(new Intent(getApplicationContext(), Hotel_Amh.class));
break;
case 2:
startActivity(new Intent(getApplicationContext(),
Restaurant_Amh.class));
break;
case 3:
startActivity(new Intent(getApplicationContext(), Bank_Amh.class));
break;
default:
break;
}
}
}
//Xml file for Home Screen in Amharic
<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="top"
tools:context=".Home_Eng"
TOURGONDAR CITY GUIDE MOBILE APPLICATION
68
>
<TextViewandroid:id="@+id/textLangAmh"
android:layout_width="150dp"
android:layout_height="38dp"
android:text="የቋንቋአማራጭ"
android:paddingLeft="20dp"
android:paddingTop="10dp"
android:layout_alignParentTop="true"
android:textAlignment="center"
android:textSize="15dp"/>
<Button
android:id="@+id/btnEnglish"
android:layout_width="175dp"
android:layout_height="38dp"
android:background="@drawable/toenglishbtn"
android:textAlignment="center"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
/>
<ImageView
android:id="@+id/imageView1"
android:layout_width="fill_parent"
android:layout_height="170dp"
android:layout_alignParentLeft="true"
android:src="@drawable/homegondarimageamahric"
android:adjustViewBounds="true"
android:scaleType="fitXY"
android:layout_below="@+id/btnEnglish"
/>
<Button
android:id="@+id/eventBtnAmh"
android:layout_width="150dp"
android:layout_height="40dp"
android:layout_below="@+id/imageView1"
android:layout_alignParentLeft="true"
android:background="@drawable/eventsbtnamahric"
android:paddingLeft="10dp"/>
<Button
TOURGONDAR CITY GUIDE MOBILE APPLICATION
69
android:id="@+id/citymapBtnAmh"
android:layout_width="150dp"
android:layout_height="40dp"
android:layout_below="@+id/imageView1"
android:layout_alignParentRight="true"
android:background="@drawable/citymapbtnamahric"/>
<ListView
android:id="@+id/listHomeAmh"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_below="@+id/eventBtnAmh"
android:paddingTop="10dp">
</ListView>
</RelativeLayout>
//Source code for Hotel Activity in English java code
package com.example.gondarcityguide;
import java.io.File;
import java.io.FileOutputStream;
import java.io.InputStream;
import java.net.HttpURLConnection;
import java.net.URL;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import org.apache.http.NameValuePair;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import android.app.AlertDialog;
import android.app.ListActivity;
import android.app.ProgressDialog;
import android.content.DialogInterface;
import android.content.Intent;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.AsyncTask;
import android.os.Bundle;
import android.util.Log;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
70
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ListView;
import android.widget.SimpleAdapter;
publicclass Hotel_Eng extends ListActivity implements OnItemClickListener{
ListView list;
EditText getHotel;
Button btnFilterHotel;
// Progress Dialog
private ProgressDialog pDialog;
// Creating JSON Parser object
JSONParser jParser = newJSONParser();
List<HashMap<String,Object>>hotelList;
// url to get all hotels list
privatestatic String urlHotel="http://10.139.179.119/test/hotels.php/hotels";
// JSON Node names
privatestaticfinal String TAG_HOTELS = "hotels";
privatestaticfinal String TAG_TITLEHOTEL = "TitleHotle";
privatestaticfinal String TAG_DESCHOTEL = "DescHotel";
privatestaticfinal String TAG_IMAGEHOTEL="ImageHotel";
// hotels JSONArray
JSONArray hotels=null;
@Override
protectedvoid onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.hotel_eng);
// Hashmap for ListView
hotelList=new ArrayList<HashMap<String,Object>>();
TOURGONDAR CITY GUIDE MOBILE APPLICATION
71
// Loading hotels in Background Thread
new LoadHotels().execute();
//institiatedlistview
list=getListView();
list.setOnItemClickListener(this);
getHotel=(EditText) findViewById(R.id.getHotel);
btnFilterHotel=(Button) findViewById(R.id.btnFilterHotelEng);
btnFilterHotel.setOnClickListener(new OnClickListener() {
@Override
publicvoid onClick(View arg0) {
//Text for search
String textForSearch=getHotel.getText().toString();
if(textForSearch.equalsIgnoreCase("AG Hotel Gondar")||
textForSearch.equalsIgnoreCase("AG Hotel")||
textForSearch.equalsIgnoreCase("AG")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
AgHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("L-Shape Hotel")||
textForSearch.equalsIgnoreCase("L Shape
Hotel")||
textForSearch.equalsIgnoreCase("LShape
Hotel")||
textForSearch.equalsIgnoreCase("L-Shape")||
textForSearch.equalsIgnoreCase("L Shape")||
textForSearch.equalsIgnoreCase("LShape")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
LShapeHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Florida International
Hotel")||
textForSearch.equalsIgnoreCase("Florida
International")||
TOURGONDAR CITY GUIDE MOBILE APPLICATION
72
textForSearch.equalsIgnoreCase("Florida
Hotel")||
textForSearch.equalsIgnoreCase("Florida")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
FloridaHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Taye Belay Hotel")||
textForSearch.equalsIgnoreCase("Taye
Belay")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
TayeBelayHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Goha Hotel")||
textForSearch.equalsIgnoreCase("Goha")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
GohaHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Quara Hotel")||
textForSearch.equalsIgnoreCase("Quara")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
QuaraHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("New Fesica Hotel")||
textForSearch.equalsIgnoreCase("New Fesica")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
NewFesicaHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Yalew Ayker Hotel")||
textForSearch.equalsIgnoreCase("Yalew Ayker")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
YalewAykerHotel_Eng.class));
TOURGONDAR CITY GUIDE MOBILE APPLICATION
73
}
elseif(textForSearch.equalsIgnoreCase("Lammergeyer Hotel")||
textForSearch.equalsIgnoreCase("Lamergeyer
Hotel")||
textForSearch.equalsIgnoreCase("Lammergeyer")||
textForSearch.equalsIgnoreCase("Lamergeyer")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
LammergeyerHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Fogera Hotel")||
textForSearch.equalsIgnoreCase("Fogera")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
FogeraHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Circle Hotel")||
textForSearch.equalsIgnoreCase("Circle")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
CircleHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Queens Hotel")||
textForSearch.equalsIgnoreCase("Queen
Hotel")||
textForSearch.equalsIgnoreCase("Queens")||
textForSearch.equalsIgnoreCase("Queen")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
QueensHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Gondar Landmark
Hotel")||
textForSearch.equalsIgnoreCase("Landmark
Hotel")||
textForSearch.equalsIgnoreCase("Gondar
Landmark")||
TOURGONDAR CITY GUIDE MOBILE APPLICATION
74
textForSearch.equalsIgnoreCase("Landmark")){
//if it is match the string launching the activity
startActivity(new Intent(getApplicationContext(),
LandmarkHotel_Eng.class));
}
elseif(textForSearch.equalsIgnoreCase("Jantekel Hotel")||
textForSearch.equalsIgnoreCase("Jantekel")){
startActivity(new Intent(getApplicationContext(),
JantekleHotel_Eng.class));
}
else{
AlertDialog.Builder
builder=newAlertDialog.Builder(Hotel_Eng.this);
builder.setMessage("Sorry! No Match is
Foundn Please check the spelling.");
builder.setCancelable(false);
builder.setPositiveButton("Ok", new
DialogInterface.OnClickListener() {
@Override
publicvoid onClick(DialogInterface dialog, int which) {
Hotel_Eng.this.finish();
}
});
AlertDialog alert=builder.create();
alert.show();
}
}
});
TOURGONDAR CITY GUIDE MOBILE APPLICATION
75
}
//Launching differen Activity by click on list item
@Override
publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) {
//use switch statment to launch Activity
switch(position)
{
case 0:
startActivity(new Intent(getApplicationContext(),
AgHotel_Eng.class));
break;
case 1:
startActivity(new Intent(getApplicationContext(),
LShapeHotel_Eng.class));
break;
case 2:
startActivity(new Intent(getApplicationContext(),
FloridaHotel_Eng.class));
break;
case 3:
startActivity(new Intent(getApplicationContext(),
TayeBelayHotel_Eng.class));
break;
case 4:
startActivity(new Intent(getApplicationContext(),
GohaHotel_Eng.class));
break;
case 5:
startActivity(new Intent(getApplicationContext(),
QuaraHotel_Eng.class));
break;
case 6:
startActivity(new Intent(getApplicationContext(),
NewFesicaHotel_Eng.class));
break;
case 7:
startActivity(new Intent(getApplicationContext(),
YalewAykerHotel_Eng.class));
break;
case 8:
startActivity(new Intent(getApplicationContext(),
LammergeyerHotel_Eng.class));
break;
TOURGONDAR CITY GUIDE MOBILE APPLICATION
76
case 9:
startActivity(new Intent(getApplicationContext(),
FogeraHotel_Eng.class));
break;
case 10:
startActivity(new Intent(getApplicationContext(),
CircleHotel_Eng.class));
break;
case 11:
startActivity(new Intent(getApplicationContext(),
QueensHotel_Eng.class));
break;
case 12:
startActivity(new Intent(getApplicationContext(),
LandmarkHotel_Eng.class));
break;
case 13:
startActivity(new Intent(getApplicationContext(),
JantekleHotel_Eng.class));
break;
default:
break;
}
}
// Response from Edit Product Activity
@Override
protectedvoid onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
// if result code 100
if (resultCode == 100) {
// if result code 100 is received
// means user edited/deleted product
// reload this screen again
Intent intent = getIntent();
finish();
startActivity(intent);
}
}
//Background Async Task to Load all hotels by making HTTP Request
class LoadHotels extends AsyncTask<String, String, String>{
TOURGONDAR CITY GUIDE MOBILE APPLICATION
77
//Before starting background thread Show Progress Dialog
protectedvoid onPreExecute()
{
super.onPreExecute();
pDialog=new ProgressDialog(Hotel_Eng.this);
pDialog.setMessage("Loading Hotels ...please wait");
pDialog.setIndeterminate(false);
pDialog.setCancelable(false);
pDialog.show();
}
//getting All Hotels from url
@Override
protected String doInBackground(String... args) {
// Building Parameters
List<NameValuePair> params = new ArrayList<NameValuePair>();
// getting JSON string from URL
JSONObject json = jParser.makeHttpRequest(urlHotel, "GET", params);
// Check your log cat for JSON reponse
Log.d("All Hotels: ", json.toString());
//get json Array
try {
hotels=json.getJSONArray(TAG_HOTELS);
// looping through All hotels
for (int i = 0; i <hotels.length(); i++) {
JSONObject c = hotels.getJSONObject(i);
// Storing each json item in variable
String TitleHotel = c.getString(TAG_TITLEHOTEL);
String DescHotel = c.getString(TAG_DESCHOTEL);
String ImageHotel=c.getString(TAG_IMAGEHOTEL);
// creating new HashMap
HashMap<String, Object> map=new HashMap<String, Object>();
// adding each child node to HashMap key => value
map.put(TAG_TITLEHOTEL, TitleHotel);
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document
Final document

More Related Content

Viewers also liked

Camtasia getting started guide
Camtasia getting started guideCamtasia getting started guide
Camtasia getting started guidedimtod
 
9789241501750 eng annexes (1)
9789241501750 eng annexes (1)9789241501750 eng annexes (1)
9789241501750 eng annexes (1)clac.cab
 
Human rights risk
Human rights riskHuman rights risk
Human rights risk
clac.cab
 
Challenging changing and mobilizing
Challenging changing and mobilizing Challenging changing and mobilizing
Challenging changing and mobilizing
clac.cab
 
An overview of access to medicines
An overview of access to medicinesAn overview of access to medicines
An overview of access to medicines
clac.cab
 
Gym Matting
Gym MattingGym Matting
Gym Mattinggymuk
 
Preparing for the nfm+crg 12th dec 2013
Preparing for the nfm+crg 12th dec 2013Preparing for the nfm+crg 12th dec 2013
Preparing for the nfm+crg 12th dec 2013clac.cab
 
NFM_master deck
NFM_master deckNFM_master deck
NFM_master deck
clac.cab
 
Punishing success ?
Punishing success ?Punishing success ?
Punishing success ?
clac.cab
 
Access to HIV Prevention and Treatment for Men Who Have Sex with Men
Access to HIV Prevention and Treatment for Men Who Have Sex with MenAccess to HIV Prevention and Treatment for Men Who Have Sex with Men
Access to HIV Prevention and Treatment for Men Who Have Sex with Men
clac.cab
 
The needs and rights of male sex workers (summary)
The needs and rights of male sex workers (summary)The needs and rights of male sex workers (summary)
The needs and rights of male sex workers (summary)
clac.cab
 
Country dialogue training external
Country dialogue training externalCountry dialogue training external
Country dialogue training external
clac.cab
 
Gf community update_nov2013
Gf community update_nov2013Gf community update_nov2013
Gf community update_nov2013
clac.cab
 

Viewers also liked (13)

Camtasia getting started guide
Camtasia getting started guideCamtasia getting started guide
Camtasia getting started guide
 
9789241501750 eng annexes (1)
9789241501750 eng annexes (1)9789241501750 eng annexes (1)
9789241501750 eng annexes (1)
 
Human rights risk
Human rights riskHuman rights risk
Human rights risk
 
Challenging changing and mobilizing
Challenging changing and mobilizing Challenging changing and mobilizing
Challenging changing and mobilizing
 
An overview of access to medicines
An overview of access to medicinesAn overview of access to medicines
An overview of access to medicines
 
Gym Matting
Gym MattingGym Matting
Gym Matting
 
Preparing for the nfm+crg 12th dec 2013
Preparing for the nfm+crg 12th dec 2013Preparing for the nfm+crg 12th dec 2013
Preparing for the nfm+crg 12th dec 2013
 
NFM_master deck
NFM_master deckNFM_master deck
NFM_master deck
 
Punishing success ?
Punishing success ?Punishing success ?
Punishing success ?
 
Access to HIV Prevention and Treatment for Men Who Have Sex with Men
Access to HIV Prevention and Treatment for Men Who Have Sex with MenAccess to HIV Prevention and Treatment for Men Who Have Sex with Men
Access to HIV Prevention and Treatment for Men Who Have Sex with Men
 
The needs and rights of male sex workers (summary)
The needs and rights of male sex workers (summary)The needs and rights of male sex workers (summary)
The needs and rights of male sex workers (summary)
 
Country dialogue training external
Country dialogue training externalCountry dialogue training external
Country dialogue training external
 
Gf community update_nov2013
Gf community update_nov2013Gf community update_nov2013
Gf community update_nov2013
 

Similar to Final document

Affordable Housing For All: Challenges, Opportunities and Way Forward
Affordable Housing For All: Challenges, Opportunities and Way ForwardAffordable Housing For All: Challenges, Opportunities and Way Forward
Affordable Housing For All: Challenges, Opportunities and Way Forward
Vishad Sharma
 
final_diagnostic_report_clean.pdf
final_diagnostic_report_clean.pdffinal_diagnostic_report_clean.pdf
final_diagnostic_report_clean.pdf
Fajar Baskoro
 
Babados Tourism Policy - Revised_May_28_2001[1]
Babados Tourism Policy - Revised_May_28_2001[1]Babados Tourism Policy - Revised_May_28_2001[1]
Babados Tourism Policy - Revised_May_28_2001[1]
Scott Rains
 
Social media for sustainable tourism development dissertation manoj kumar
Social media for sustainable tourism development dissertation manoj kumarSocial media for sustainable tourism development dissertation manoj kumar
Social media for sustainable tourism development dissertation manoj kumar
Manoj Kumar
 
Le Thi Quynh Nhu - 2551 - Graduation thesis.docx
Le Thi Quynh Nhu - 2551 - Graduation thesis.docxLe Thi Quynh Nhu - 2551 - Graduation thesis.docx
Le Thi Quynh Nhu - 2551 - Graduation thesis.docx
NhSamantha
 
Usr tour and tra vel mini project report
Usr tour and tra vel mini project reportUsr tour and tra vel mini project report
Usr tour and tra vel mini project report
Ravindra Chaudhary
 
Urban Planning for City Leaders
Urban Planning for City LeadersUrban Planning for City Leaders
Urban Planning for City Leaders
Oswar Mungkasa
 
Business plan
Business planBusiness plan
Business plan
Kavindu Gamage
 
Internship report on IT
Internship report on ITInternship report on IT
Internship report on IT
surafelteshome3
 
Computer science internship report
Computer science internship reportComputer science internship report
Computer science internship report
surafelteshome3
 
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdfSPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
TomTom149267
 
Shyroke Amalgamated Community Investment overview
Shyroke Amalgamated Community Investment overviewShyroke Amalgamated Community Investment overview
Shyroke Amalgamated Community Investment overview
zodauzez zodauzez
 
Shyroke Amalgamated Community Investment Overview
Shyroke Amalgamated Community Investment OverviewShyroke Amalgamated Community Investment Overview
Shyroke Amalgamated Community Investment Overview
zodauzez zodauzez
 
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)Rahul Sattar
 
Digital brand strategy - Ugo Orlando
Digital brand strategy - Ugo OrlandoDigital brand strategy - Ugo Orlando
Digital brand strategy - Ugo Orlando
Ugo Orlando
 
adams_pizza_inn final.docx
adams_pizza_inn final.docxadams_pizza_inn final.docx
adams_pizza_inn final.docx
gurucyber4
 
MariahShaltry_Portfolio
MariahShaltry_PortfolioMariahShaltry_Portfolio
MariahShaltry_PortfolioMariah Shaltry
 
PROJECT REPORT_ONLINE VOTING SYSTEM
PROJECT REPORT_ONLINE VOTING SYSTEMPROJECT REPORT_ONLINE VOTING SYSTEM
PROJECT REPORT_ONLINE VOTING SYSTEMNandasaba Wilson
 
Product Innovation: An Effective Strategy To Penetrate Into Small Towns And ...
Product Innovation: An Effective Strategy To  Penetrate Into Small Towns And ...Product Innovation: An Effective Strategy To  Penetrate Into Small Towns And ...
Product Innovation: An Effective Strategy To Penetrate Into Small Towns And ...
Ankit Agarwal
 

Similar to Final document (20)

Affordable Housing For All: Challenges, Opportunities and Way Forward
Affordable Housing For All: Challenges, Opportunities and Way ForwardAffordable Housing For All: Challenges, Opportunities and Way Forward
Affordable Housing For All: Challenges, Opportunities and Way Forward
 
final_diagnostic_report_clean.pdf
final_diagnostic_report_clean.pdffinal_diagnostic_report_clean.pdf
final_diagnostic_report_clean.pdf
 
Babados Tourism Policy - Revised_May_28_2001[1]
Babados Tourism Policy - Revised_May_28_2001[1]Babados Tourism Policy - Revised_May_28_2001[1]
Babados Tourism Policy - Revised_May_28_2001[1]
 
Social media for sustainable tourism development dissertation manoj kumar
Social media for sustainable tourism development dissertation manoj kumarSocial media for sustainable tourism development dissertation manoj kumar
Social media for sustainable tourism development dissertation manoj kumar
 
Le Thi Quynh Nhu - 2551 - Graduation thesis.docx
Le Thi Quynh Nhu - 2551 - Graduation thesis.docxLe Thi Quynh Nhu - 2551 - Graduation thesis.docx
Le Thi Quynh Nhu - 2551 - Graduation thesis.docx
 
Usr tour and tra vel mini project report
Usr tour and tra vel mini project reportUsr tour and tra vel mini project report
Usr tour and tra vel mini project report
 
Urban Planning for City Leaders
Urban Planning for City LeadersUrban Planning for City Leaders
Urban Planning for City Leaders
 
Business plan
Business planBusiness plan
Business plan
 
Internship report on IT
Internship report on ITInternship report on IT
Internship report on IT
 
Computer science internship report
Computer science internship reportComputer science internship report
Computer science internship report
 
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdfSPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
SPORTSWEAR E-COMMERCE MOBILE APPLICATION.pdf
 
Shyroke Amalgamated Community Investment overview
Shyroke Amalgamated Community Investment overviewShyroke Amalgamated Community Investment overview
Shyroke Amalgamated Community Investment overview
 
Shyroke Amalgamated Community Investment Overview
Shyroke Amalgamated Community Investment OverviewShyroke Amalgamated Community Investment Overview
Shyroke Amalgamated Community Investment Overview
 
SOIL Markezine - Oct 2012
SOIL Markezine - Oct 2012SOIL Markezine - Oct 2012
SOIL Markezine - Oct 2012
 
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)
BUSINESS AND BRAND DEVELOPMENT AT MAGNACODE(1)
 
Digital brand strategy - Ugo Orlando
Digital brand strategy - Ugo OrlandoDigital brand strategy - Ugo Orlando
Digital brand strategy - Ugo Orlando
 
adams_pizza_inn final.docx
adams_pizza_inn final.docxadams_pizza_inn final.docx
adams_pizza_inn final.docx
 
MariahShaltry_Portfolio
MariahShaltry_PortfolioMariahShaltry_Portfolio
MariahShaltry_Portfolio
 
PROJECT REPORT_ONLINE VOTING SYSTEM
PROJECT REPORT_ONLINE VOTING SYSTEMPROJECT REPORT_ONLINE VOTING SYSTEM
PROJECT REPORT_ONLINE VOTING SYSTEM
 
Product Innovation: An Effective Strategy To Penetrate Into Small Towns And ...
Product Innovation: An Effective Strategy To  Penetrate Into Small Towns And ...Product Innovation: An Effective Strategy To  Penetrate Into Small Towns And ...
Product Innovation: An Effective Strategy To Penetrate Into Small Towns And ...
 

Recently uploaded

一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
一比一原版(CBU毕业证)卡普顿大学毕业证如何办理一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
ahzuo
 
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
u86oixdj
 
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
yhkoc
 
Q1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year ReboundQ1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year Rebound
Oppotus
 
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdfCh03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
haila53
 
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project PresentationPredicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Boston Institute of Analytics
 
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
mbawufebxi
 
Empowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptxEmpowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptx
benishzehra469
 
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
Tiktokethiodaily
 
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
v3tuleee
 
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
vcaxypu
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单
enxupq
 
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
NABLAS株式会社
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
ewymefz
 
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
ahzuo
 
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
Subhajit Sahu
 
standardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghhstandardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghh
ArpitMalhotra16
 
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
vcaxypu
 
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
John Andrews
 
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
pchutichetpong
 

Recently uploaded (20)

一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
一比一原版(CBU毕业证)卡普顿大学毕业证如何办理一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
一比一原版(CBU毕业证)卡普顿大学毕业证如何办理
 
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
 
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
 
Q1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year ReboundQ1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year Rebound
 
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdfCh03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
 
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project PresentationPredicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
 
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
 
Empowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptxEmpowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptx
 
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
1.Seydhcuxhxyxhccuuxuxyxyxmisolids 2019.pptx
 
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
 
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
一比一原版(ArtEZ毕业证)ArtEZ艺术学院毕业证成绩单
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单
 
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
【社内勉強会資料_Octo: An Open-Source Generalist Robot Policy】
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
 
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
 
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
Algorithmic optimizations for Dynamic Levelwise PageRank (from STICD) : SHORT...
 
standardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghhstandardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghh
 
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
 
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
 
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
Data Centers - Striving Within A Narrow Range - Research Report - MCG - May 2...
 

Final document

  • 1. i DECLARATION This is to declare thatproject work which is done under the supervision of Daniel Mehetote and having title TourGondar city guide mobile application is the sole contribution of: BONSA FEKADU MEDIHANIT KALARO MERON NEGASH MINTESNOT KASU WORKNESH TSEGUYE No part of the project work has been reproduced illegally (copy and paste) which can be considered as Plagiarism. All referenced parts have been used to argue the idea and have cited properly. We will be responsible and liable for any consequence if violation of this declaration is proven. Date:_____________________________ Group Members: Full Name Signature BONSA FEKADU __________________ MEDIHANIT KALARO __________________ MERON NEGASH __________________ MINTESNOT KASU __________________ WORKNESH TSEGUYE __________________
  • 2. TOURGONDAR CITY GUIDE MOBILE APPLICATION ii CERTIFICATE This is to certify that this BSc industrial project report entitled TourGondar city guide mobile application by: BONSA FEKADU MEDIHANIT KALARO MERON NEGASH MINTESNOT KASU WORKNESH TSEGUYE is approved by me for submission. I certify further that, to the best of my knowledge, the report represents work carried out by these students. ______________________________ __________________________________ Date Name and signature of supervisor
  • 3. TOURGONDAR CITY GUIDE MOBILE APPLICATION iii Acknowledgment Tour Gondar city guide application would like to thank all our project supporters for this success, it will not be successful without those who scarified their time, share experience and support with idea next to God. We also like to express our warmest blessing and appreciation to our advisor Daniel Mahetot for his patience, good humor and helpful comments, suggestion to finalize this project. Secondly we would like to thank administration of Gondar city and Tourism office for supporting the project by giving us the necessary information. Last but not least our deep gratitude goes to our family who help us by giving moral, economical and materials support for this project.
  • 4. TOURGONDAR CITY GUIDE MOBILE APPLICATION iv Table of Contents DECLARATION.......................................................................................................................................... i CERTIFICATE............................................................................................................................................ ii Acknowledgment................................................................................................................................... iii List of Tables......................................................................................................................................... vii List Of Figure........................................................................................................................................ viii CHAPTER ONE......................................................................................................................................... 1 1.1. Introduction..................................................................................................................................... 1 1.2. Background...................................................................................................................................... 2 1.3. Statement of the problem............................................................................................................... 3 1.4. Objective of the project................................................................................................................... 3 1.4.1 .General objective ......................................................................................................................... 3 1.4.2 .Specific objective.......................................................................................................................... 3 1.5. Scope of the project ........................................................................................................................ 4 1.6. System Development Methodology................................................................................................4 1.6.1. Investigation (fact-finding) methods............................................................................................5 1.6.2. System Development Tools.......................................................................................................... 5 1.6.2.1. Hardware................................................................................................................................... 5 1.6.2.2. Software .................................................................................................................................... 5 1.7. Significance of the project............................................................................................................... 6 1.8. Beneficiaries .................................................................................................................................... 6 1.9. Time schedule.................................................................................................................................. 7 CHAPTER TWO........................................................................................................................................ 8 2. Requirement Analysis........................................................................................................................ 8 2.1. Introduction..................................................................................................................................... 8 2.2. Current System................................................................................................................................ 8
  • 5. TOURGONDAR CITY GUIDE MOBILE APPLICATION v 2.2.1. Major function of current system ................................................................................................8 2.2.2. Problem of existing system .......................................................................................................... 8 2.3. Gathering Information..................................................................................................................... 9 2.3.1 Requirement Gathering Methodologies .....................................................................................10 2.3.2. Result Found............................................................................................................................... 10 2.4. Proposed System........................................................................................................................... 10 2.4.1. Overview..................................................................................................................................... 10 2.4.2 Functional Requirement..............................................................................................................11 2.4.3. Non-Functional Requirement.....................................................................................................11 2.4.3.1. User interface and Human Factors..........................................................................................11 2.4.3.2. Documentation........................................................................................................................ 12 2.4.3.3. Hardware consideration..........................................................................................................12 2.4.3.4. Performance characteristics....................................................................................................12 2.4.3.5. Error Handling and Extreme conditions ..................................................................................12 2.4.3.6. Quality Issues........................................................................................................................... 13 2.4.3.7. System Modifications..............................................................................................................13 2.4.3.8. Physical Environment ..............................................................................................................13 2.4.3.9. Security Issues ......................................................................................................................... 14 2.4.3.10. Resource Issues ..................................................................................................................... 14 2.5. System Model................................................................................................................................ 15 2.5.1. Scenario...................................................................................................................................... 15 2.5.2. Use case Model .......................................................................................................................... 17 2.5.2.1. Use case diagram..................................................................................................................... 17 2.5.2.2. Description of Use case Model................................................................................................19 2.5.3. Activity Diagram ......................................................................................................................... 23 2.5.4. Object Model.............................................................................................................................. 31 2.5.4.1. Data Dictionary........................................................................................................................ 31 2.5.4.2. Class Modeling......................................................................................................................... 32 2.5.4.3. Dynamic Modeling...................................................................................................................34 2.5.5. User Interface............................................................................................................................. 41 CHAPTER THREE ................................................................................................................................... 42 3. System Design............................................................................................................................... 42
  • 6. TOURGONDAR CITY GUIDE MOBILE APPLICATION vi 3.1. Introduction................................................................................................................................... 42 3.2. Current software architecture.......................................................................................................42 3.3. Proposed software architecture....................................................................................................42 3.3.1. Overview................................................................................................................................. 42 3.3.2. Subsystem decomposition .....................................................................................................43 3.3.3. Hardware/Software mapping.....................................................................................................45 3.3.4. Persistent data management .....................................................................................................46 3.3.5. Access control and security........................................................................................................49 3.3.6. Subsystem services..................................................................................................................... 50 3.3.7. Detailed class diagram................................................................................................................51 3.3.8. Package....................................................................................................................................... 52 CHAPTER FOUR..................................................................................................................................... 53 4. Implementation................................................................................................................................ 53 4.1. Mapping models to code...............................................................................................................53 4.2. Source codes of major classes, packages or interfaces.................................................................55 4.3. Screen Images..............................................................................................................................109 CHAPTER 5.......................................................................................................................................... 114 5. Conclusion and Recommendation..................................................................................................114 5.1. Conclusion ................................................................................................................................... 114 5.2. Recommendation ........................................................................................................................114 5.3. Bibliography.................................................................................................................................115 Appendix A ......................................................................................................................................... 116
  • 7. TOURGONDAR CITY GUIDE MOBILE APPLICATION vii List of Tables Table 1 Events..................................................................................................................................... 46 Table 2 hotels ...................................................................................................................................... 46 Table 3 hotels pictures ....................................................................................................................... 46 Table 4 restaurants............................................................................................................................. 46 Table 5 restaurant pictures................................................................................................................47 Table 6 attractions.............................................................................................................................. 47 Table 7 attraction pictures.................................................................................................................47 Table 8 bank........................................................................................................................................ 47 Table 9 bank pictures......................................................................................................................... 47 Table 10 health center........................................................................................................................ 48 Table 11 health center pictures .........................................................................................................48 Table 12 police station........................................................................................................................ 48 Table 13 police station pictures.........................................................................................................48 Table 14 tour and travel agent ..........................................................................................................48 Table 15 TTA pictures ....................................................................................................................... 49 Table 16 Access control and security................................................................................................49
  • 8. TOURGONDAR CITY GUIDE MOBILE APPLICATION viii List of Figure Figure 1 Time schedule ........................................................................................................................ 7 Figure 2 Use case diagram................................................................................................................18 Figure 3 Update content activity diagram........................................................................................23 Figure 4 Delete content activity diagram .........................................................................................24 Figure 5 Upload content activity diagram........................................................................................25 Figure 6 Change language activity diagram ....................................................................................26 Figure 7 Detect location activity diagram ........................................................................................27 Figure 8 Attraction activity diagram................................................................................................28 Figure 9 Available service activity diagram.....................................................................................29 Figure 10 Search activity diagram....................................................................................................30 Figure 11 High level Class diagram..................................................................................................33 Figure 12 Sequence diagram for updating content .........................................................................37 Figure 13 Sequence diagram for deleting content...........................................................................38 Figure 14 Sequence diagram for uploading content........................................................................39 Figure 15 Sequence diagram for search ...........................................................................................40 Figure 16 Overview of the new system .............................................................................................43 Figure 17 Components diagram for subsystem decomposition......................................................44 Figure 18 Deployment diagram for hardware/software mapping .................................................45 Figure 19 Detailed class diagram.....................................................................................................51 Figure 20 Package diagram...............................................................................................................52
  • 9. 1 CHAPTER ONE 1.1. Introduction A mobile device, which is also referred to as a handheld device or handheld computer, is a pint-sized computing device. Mobile devices usually come with a touch or non-touch display screen and sometimes, even a mini keyboard. There are many types of mobile devices; the commonest ones are mobile phones, smart phones, PDAs, pagers and Personal Navigation Devices. PDAs and smart phones are among the most preferred mobile devices, which offer all the conveniences of a personal computer, along with a very small form factor. Although mobile phones have taken over our current society, they have been around for several decades in some form or another. Beginning in the late 1940s, the technology that would later be used in today’s cell phones was created and the idea of a mobile phone was introduced. This cell technology was first used in mobile rigs which were mainly used in taxis, police cars and other emergency vehicles and situations. Truckers also used a form of this technology to communicate with each other. The first mobile phones, referred to as First Generation or 1G, were introduced to the public market in 1983 by the Motorola Company. These first mobile phones used analog technology which was much less reliable than the digital technology we use today. The analog phones also had a great deal more static and noise interference than we are accustomed to today. The main purpose of this First Generation technology was for voice traffic, but consumers felt insecure about people listening in on their conversations. During the 1990s, great improvements were made in the mobile phone technology. These phones used Second Generation, or 2G technology. In 1990, the first cell phone call was made using the new digital technology that became characteristic of this era. The Second Generation cellular phone technology was faster and much quieter than its analog predecessor. As a result, it became even more popular than previous models, too. The new technology also made them capable of being smaller rather than the large briefcase-sized units from the 1980s.The Third Generation technology, or 3G, is what many people currently use in their digital cellular phones today. This technology was created very soon after the excitement that the 2G technology created. This new technology is not only capable of transferring voice data (such as a phone call), but it is also able to transfer other types of data, including emails, information and instant messages. There are currently plans
  • 10. TOURGONDAR CITY GUIDE MOBILE APPLICATION 2 in place to develop a Fourth Generation – 4G – technology. Goals for this new set of standards include a combination of technologies that will make information transfer and internet capabilities faster and more affordable for cellular phones. A mobile application (or mobile app) is a software application designed to run on smart phone, tablet computer and other mobile devices. They are usually available through application distribution platforms, which are typically operated by the owner of the mobile operating system. A mobile operating system (OS) is software that allows smart phones, tablet Pcs and other devices to run applications and programs. A mobile OS typically starts up when a device powers on, presenting a screen with icons or tiles that present information and provide application access. Mobile operating systems also manage cellular and wireless network connectivity, as well as phone access. Examples of mobile device operating systems include Apple iOS, Google Android, BlackBerry OS, Nokia’s Symbian, Hewlett-Packard’s webOS (formerly Palm OS) and Microsoft’s Windows Phone OS. Android is one of the most popular Linux based mobile operating system.[1] 1.2. Background The mobile phone device is a very important communication tool as it was built to enhance social contacts and network while enhancing business productivity. The mobile phone enables us to be on time during appointments. It also helps in verifying the degree of temperature to enable us chose appropriate dress code for the day. It keeps us informed on current events because of its connectivity to the internet. It relaxes it also when we play games with it or listen to music through it. The mobile device can provide the information about something and also it detecting the location of the user. Today, a mobile application plays a great role in our day to day activities. Tour Gondar application is a city guide mobile application which is run in the smart phones. This application provides basic information about the services which reside Gondar town like Hotels, Restaurants, Attraction places, Banks, Tour and Travel agents and Health centers. The application informs the current events in the town and also it detects the current location of the users.
  • 11. TOURGONDAR CITY GUIDE MOBILE APPLICATION 3 1.3. Statement of the problem Gondar is one of the oldest and historical town in Ethiopian history. In this town there are money Attraction and Historical places, Hotels ,Restaurants, Banks, Health centers and Tour and Travel agents and also many events are happen in this town like the great epiphany ceremony (carnival). But the people which are living in this town and also the visitors cannot access the information about the service providers and events easily. More specific problem listed as follows:  User cannot access well organized information at anywhere about service provider like Hotels, Restaurants, Attraction and Historical places ,Banks, Health centers and Tour and Travel Agents.  User cannot get information about service provider for 24/7 hours.  When there is a new event(like carnival ceremony) happen in the town the user must be wait until announced and post in mass media.  There is no a mechanism a visitor to detect the current location.  Manually system needs more human power and time. 1.4. Objective of the project The general and specific objectives of the study are described below. 1.4.1 .General objective The general objective of this project is to developing a city guide android mobile application. 1.4.2 .Specific objective In order to achieve the general objective of this project, the following specific objectives are addressed.  The system provide information about service provider either in Amharic or English language  The system detect the current location of the user,  The system provide new update information about events like celebrity;
  • 12. TOURGONDAR CITY GUIDE MOBILE APPLICATION 4  The system also provides a city map to user to search a point of interests like Attractions places, Hotels and Restaurants. 1.5. Scope of the project Tour Gondar mobile application is software application which is run only in smartphones and performs the following activities:  The application gives information about the types of service which is provided by service provider.  The application provides a working day, time and location of service providers.  The application provides new updated information about service providers and events. But the application does not include the following activities:  The application doesn’t provide any information about services provider which is located outside of Gondar town.  Tour Gondar application is not operates other language rather than Amharic and English languages. 1.6. System Development Methodology Since the entire project requirements are not well known in detail initially, the development team chooses prototype system development methodology to develop the new system. The basic idea of prototype model is that a prototype build, test, and then rework as necessary until an acceptable prototype is finally achieved from which the complete system or product can now be developed. It is an iterative, trial-and-error process that takes place between the developers and the users. The most significant advantage of using prototype system development methodology is listed as follows:  Users are actively involved in the development.  Errors can be detects much earlier.  Quicker user feedback is available leading to better solutions.  Missing functionality can be identifying easily.  Confusing or difficult functions can be identifying.
  • 13. TOURGONDAR CITY GUIDE MOBILE APPLICATION 5  Since in this methodology a working model of the system is provided, the users get a better understanding of the system being developed.[2] 1.6.1. Investigation (fact-finding) methods For gathering information to our project we use different methods.  Observation: Observation is one of the most important methodologies to gathering information by physical going to the place and looks how the current system. It can be very difficult for humans to explain what they do or to even describe accurately how they achieve a task, so observation very crucial to gathering information.  Interview: Interview is another important methodology to gathering information by asking someone a set of questions. It helps us to get critical and important information about the overall view of the current system.  Document analysis: This is also another information gathering methodology by referring the document of the existing system. 1.6.2. System Development Tools 1.6.2.1. Hardware The system needs different materials to develop the mobile application and to run the system in the real world, the basic hardware are:  Personal computer(PC)  Android platform mobile  Flash disc  Digital camera 1.6.2.2. Software We use the following tools to develop the mobile application:  Eclipse (IDE)  MySQL  Apache
  • 14. TOURGONDAR CITY GUIDE MOBILE APPLICATION 6  Edraw-max  Adobe Photoshop  Microsoft Word 1.7. Significance of the project At the end of this project, the application will raise the following significance for the users and the town.  The user can access organized information about services at anywhere and at any time.  The users (visitors) can easily detecting the current location.  The user can find the services in a simple user interface.  When we develop the mobile application there is some significant role in developing technology by making the society more interact with technology, this leads to the Gondar town to shift one step in technology. 1.8. Beneficiaries The most beneficiaries are:  User: when the users use this mobile application it saves their time and money.  Town: it will enhance the development of the town in the side of technology.
  • 15. TOURGONDAR CITY GUIDE MOBILE APPLICATION 7 1.9. Time schedule Figure 1 Time schedule
  • 16. 8 CHAPTER TWO 2. Requirement Analysis 2.1. Introduction Requirements analysis, also called requirements engineering, is the process of determining user expectations for a new or modified product. These features, called requirements, must be quantifiable, relevant and detailed. In software engineering, such requirements are often called functional specification. Requirements analysis is critical to the success of a systems or software project. The purpose of Requirements Analysis is to obtain a thorough and detailed understanding of the user needs and to break it down into discrete requirements, which are then clearly define, review and agree upon with the Customer Decision-Makers. Requirements Analysis provides the foundation for the desired product or services. [4] 2.2. Current System 2.2.1. Major function of current system The major functions of the system that are currently available in Gondar town are providing information manually about the service providers like Hotels, Restaurants, Tour and Travel agent, Banks and Health centers. Other function of the current system is providing information about events manually. Bazars, pamphlet papers and mass media are using to advertising the town. Generally the current system uses a manually system. 2.2.2. Problem of existing system As we have observed the existing system it is not preferable for the user since everything is manually. As mention above the current system providing information about the service providers and events but it is not attractive for the users and it needs more human power to perform the activity. And also the way of advertising the town cannot address many people. The major problems which are found in the existing g system listed as follow as:  Availability: The current system which is existed in Gondar town is not available at anywhere and at any time. The system does not easily providing information about
  • 17. TOURGONDAR CITY GUIDE MOBILE APPLICATION 9 the service providers to the user when the user is located outside of Gondar town and also the system doesn’t work for 24/7 hours.  Performance: The other problem which is resided in the current system is performance. We are measuring the performance of the current system in terms time. The time took by the current system to proving information about the service provider to user so slow.  Data Storage mechanism: The data storage mechanism which is used by the existing system is manually. The current system used more stationary materials like papers and pen frequently to store data. Because of this the current system spent more cost for data storage mechanism.  Efficiency: The other crucial problem which is found in the existing system is efficiency. We are measuring the efficiency of the current system in terms of resource: human and time resources. The existing system needs more human power and time to perform the task like advertising, announcing new information and store data.  Security: Since the current system used manually system it is easily expose to security problem. The existing system used hard copy document to store data and it may be stole the information by unauthorized user easily and it cause a serious problem. 2.3. Gathering Information Different fact finding techniques were used to gathering information about the current system. It is the fundamental activity for the development of the system. Without them data modeling cannot be constructed. In order to know how the existing system work and what problem are there we have been using the following fact-finding techniques.  Interviewing  Observations  Document analysis
  • 18. TOURGONDAR CITY GUIDE MOBILE APPLICATION 10 2.3.1 Requirement Gathering Methodologies To develop the new system we have to collect information, to collect information we use different methodologies.  Observation: The development team visiting and take look how the manual system works.  Interview: The development team interviewed administrator of Gondar town about how the user gain information about the service provider which available in the town, what is working time and days of the current system , what kind services are provided by the current system ,what kind services are not provided by the current system and also ask the challenge which is found in the current system and we interviewed manager of tourism office about the general working system of tourism in Gondar town and also we interviewed some people about how much the current system is effective.  Document analysis: The development team also referring the document of the existing system. 2.3.2. Result Found After interviewing, observing and analyzing of the current system, the development team found some results those are listed as below:  The current system provide information about service providers manually,  The current system works from Monday to Friday for 7 hours in each day,  The current system provide information about attraction and historical places manually and  The current system needs more time and human power. 2.4. Proposed System 2.4.1. Overview We would like to create a mobile city guide application. Users of this application will be able to search services, historical places and other points of interest by using two type of interface: either a categorized list or by viewing a map. Users can also see more details of a point of interest when they select it, like a describing text.
  • 19. TOURGONDAR CITY GUIDE MOBILE APPLICATION 11 2.4.2 Functional Requirement It is a function or features that must be include in the new system to satisfy the user needs and also be acceptable to the user and solve the problem in the current system. The functionality of this system are:  The system must provide the working time, days and location of the service providers.  The system must provide a searching mechanism to the user to find information about service providers.  The system must providing information in either Amharic or English.  The system must provide new updated information about service provider and events.  The system must provide a map view to users to find the points of interest. 2.4.3. Non-Functional Requirement It deals with the performance, time, cost and so on. It also describes the importance that is not directly related to the system. The non-functionalities of the system are:  The user can access the information about the service provider with a second.  Easy user interface to communication with the user.  The user can access more relevant and reliable information.  The user can access information at anywhere for 24/7 hours. 2.4.3.1. User interface and Human Factors When conceptualizing the mobile applications user interface, there are a few things that you should keep in mind. Some of the basic things such as clarity of interface, consistency from one view to the next, and making sure that size and uniformity user interface element . The user interface of mobile application must be easy for the user to use without any ambiguity. Tour Gondar city guide mobile application having attractive list view, consistent user interface and few and uniform buttons. Even if the interface is easy to use the customers, there will be some difficulties in understanding some part of the system like how to use and
  • 20. TOURGONDAR CITY GUIDE MOBILE APPLICATION 12 accessing the system. So the user must have some level of experience to accesses and use the system easily and effectively such as:  The user must have knowledge about how to use the smart phone 2.4.3.2. Documentation Tour Gondar city guide mobile application provided two documentation which helps to the user help menu and technical documentation .The help menu providing information to the user how to use the application. The system might need to be maintained and modified in the future therefore the maintainers will be provided with technical documentation which are the analysis, design and implementation documents. 2.4.3.3. Hardware consideration Tour Gondar City Guide application is deploy in Android 4.2.2 and late versions because this are the latest’s version for android mobile phone and most people having this versions in their mobile phone. Version: Android 4.2.2 versions Processor: 1GHZ Memory: at least 512RAM 2.4.3.4. Performance characteristics The user to access information about the service provider from server it takes only a second. Since the information is accessed from the database, the new system can support one thousand users at time and the user can use the system efficiently. 2.4.3.5. Error Handling and Extreme conditions When the user make an error or extreme condition like that is not allowed by the system, the system handle error or extreme condition by giving or show an error message and also alert message to user. The extreme condition that may occur in this system is:  Out of range(when the user out of Gondar city),the system doesn’t detect the current location of the user
  • 21. TOURGONDAR CITY GUIDE MOBILE APPLICATION 13 2.4.3.6. Quality Issues The new system is reliable, robust compare with the current system and also when we observe the current system it’s not always available anywhere and anytime as the new system. Availability: The new system providing service to the client without concerning the locations of the user and also it works for 24 hours. Reliability: The user of the new system can access more relevant and reliable information about the services and also it detect the current location accurately. Robustness: The ability of error detecting of the new system more efficient than current system. Since new system is based on client server architecture when error occurred we just concerning manly on server side. For this reason we are saving time to detecting error. Content Richness: The new system providing rich information about Hotels, Restaurants, Attraction and historical places and events in the town. In case of our new system user involvement in the development processes is vital requirement for the quality of the system. 2.4.3.7. System Modifications In the future the system can be modified in order to have the following extra features that are not implementing now. This can be listed as:  Enabling the users to detect the current locations using Wi-Fi rather than GPS.  Enabling the users to viewing offline map rather than online map. Those new features can be implemented by another programmer or by the team in future. 2.4.3.8. Physical Environment The System is deploy in each individual smart phone. In order to detect the current location of the user the system need protection from external factors like those things that does not make clear line between the device and the sky since the GPS system need a clear line between the phone and Satellites to detect the location of the user.
  • 22. TOURGONDAR CITY GUIDE MOBILE APPLICATION 14 2.4.3.9. Security Issues To protect the application from unauthorized user and malicious attack, we will concern the security issues into two perspectives: from client and server perspective. Client perspective Compared with personal computers or servers, mobile devices store much more sensitive personal information and are thus attractive targets for attackers seeking financial gain. Because these devices are always online and have a restricted user interface, it is easier for attackers to hide their malicious activities. This special issue aims to present high-quality articles describing security algorithms, protocols, policies, and frameworks for applications running on modern mobile platforms such as Android, iOS, and Windows Mobile. Security is a major part of any Android device. Since the system will be hosted on the user smart phone the user will provide security tools such as antivirus to protect the applications. Server perspective An electronic announcement board where authorized users can publish and/or read announcements. There two types of user, author user and read-only user. The rights of a user are determined by its type: An author user has the right to create new announcements and to modify or delete announcements authored by himself. A read-only user has the right to read all announcements. The announcements are centrally stored in a database server and the author users and read-only users, can use mobile devices to perform their application related operations remotely. The core of the application is built on mobile database technology. So by giving such kind of privilege to the user, we can protect the data in database server from unauthorized user. 2.4.3.10. Resource Issues The system has a resource that requires the following performance characteristics:  The smart phone must have enough memory space to process the application.  The smart phone must have high processor speed.  The phone must have a latest version of android OS.
  • 23. TOURGONDAR CITY GUIDE MOBILE APPLICATION 15 2.5. System Model A system model is the conceptual model that describes and represents a system. A system comprises multiple views such as planning, requirement analysis, design, implementation, deployment, structure, behavior, input data, and output data views. A system model is required to describe and represent all these multipleviews. System modeling is intended to assist in developing and maintaining large systems with emphasis on the Construction phase. The idea is to encapsulate complex or changeable aspects of a design inside separate components with well-defined interfaces indicating how each component interacts with its environment. Complete systems are then developed by composing these components. System modeling can increase reliability and reduce development cost by making it easier to build systems, to reuse previous built components within new systems, to change systems to suit changing requirements such as functional enhancement and platform changes, and to understand systems. In this way, a system model can satisfy different requirements such as documenting the system, providing a notation for tools such as consistency checkers and can also be used in the design stage of system development.[2] Thus, system modeling is used to ensure that a developing piece of software evolves in a consistent manner and that the task of integrating software components is simplified. 2.5.1. Scenario A scenario is a brief narrative, or story, that describes the hypothetical use of a system in one or more paragraph. Scenario for update content Scenario name: Update content Actor: Administrator Flow event: 1. Administrator request for updating. 2. The system verifies if the user is authorized or not. 3. The system allows to updating the content. 4. Administrator updates the content.
  • 24. TOURGONDAR CITY GUIDE MOBILE APPLICATION 16 Scenario for delete content Scenario name: Delete content Actor: Administrator Flow event: 1. Administrator request for deleting. 2. The system verifies if the user is authorized or not. 3. The system allow to deleting the content 4. Administrator deletes the content. Scenario for upload content Scenario name: Upload content Actor: Administrator Flow event: 1. Administrator request for upload. 2. The system verifies if the user is authorized or not. 3. The system allows to uploading the content. 4. Administrator uploads the content Scenario for change language Scenario name: Change language Actor: User Flow event: 1. User touches on link which is allowed to change the language. 2. The system changed into the selected language. Scenario for detect location Scenario name: Detect location Actor: User Flow event: 1. User starts the application. 2. The system starts detecting the current location.
  • 25. TOURGONDAR CITY GUIDE MOBILE APPLICATION 17 3. The system displays the current location. Scenario for Attractions Scenario name: Attractions Actor: User Flow event: 1. User touches on attraction link. 2. The system listed different attractions and historical places. 3. The user selects one of the types. 4. The system display basic information about the particular place. Scenario for Available services Scenario name: Available services Actor: User Flow event: 1. User touches on service link. 2. The system listed different available services. 3. The user selects one of the types. 4. The system display basic information about the particular service. 2.5.2. Use case Model 2.5.2.1. Use case diagram Use case diagram is a visual depiction of the different scenarios of the interaction between actor and use case. An actor is an idealization of an external person, process, things that interact with the system or subsystem. A use case is logical description of the slice of the system functionality.[3]
  • 26. TOURGONDAR CITY GUIDE MOBILE APPLICATION 18 Figure 2 Use case diagram
  • 27. TOURGONDAR CITY GUIDE MOBILE APPLICATION 19 2.5.2.2. Description of Use case Model Actor description Name: Administrator Description: A person who is responsible for updating, deleting, and uploading information. Name: User Description: Someone who wants to visit Gondar town. She/he can access information about the service providers and events in Gondar town. Use case description Use case Name: Update Content Actor: Administrator Description: Administrator changes some new information to the application. Precondition: Administrator should have some new information to add in the application. Main sequence: 1. Administrator makes a link to the database. 2. Administrator enters valid user name and password. 3. Administrator changes the old information by the new one. 4. Post the new information to the application. 5. Use case ends. Alternative sequence: 2. Invalid inputs, system display invalid user name and password. Post condition: New information is added. Use case Name: Delete Content Actor: Administrator Description: Administrator deleting unnecessary information from the application. Precondition: Administrator should have some data to be deleted. Main sequence: 1. Administrator makes a link to the database.
  • 28. TOURGONDAR CITY GUIDE MOBILE APPLICATION 20 2. Administrator enters a valid user name and password. 3. The administrator deletes some data from the existed one which is Unnecessary currently. 4. Display to the application. 5. Use case ends. Alternative sequence: 2. Invalid input system display invalid user name and password. Post condition: Data is deleted successfully. Use case Name: Upload Content Actor: Administrator Description: Administrator adds a new data to the application. Precondition: Administrator should have new information to add in the application. Main sequence: 1 .Administrator makes a link to the database. 2. Administrator enters valid user name and password. 3. Administrator adds new data. 4. Display to the application. 5. Use case ends Alternative sequence: 2. Invalid input. System display invalid user name and password Post condition: New information is added successfully. Use case Name: Change Language Actor: User Description: The user can change the language either Amharic or English. Precondition: Home screen displayed with “ወደአማርኛ” or “To English ” button. Main sequence: 1. User touch on ወደአማርኛ or To English button. 2. The application changed into the selected language.
  • 29. TOURGONDAR CITY GUIDE MOBILE APPLICATION 21 3. Use case ends. Alternative sequence: 1.If the user does not want to change language, he/she will not be touch on “ወደአማርኛ” or “To English” button. Post condition: Language successfully changed. Use case Name: Detect Location Actor: User Description: The user can detect the current location automatically in every 10 meters. Precondition: The user should run the application. Main sequence: 1. User run the application. 2. The system automatically detecting the current location in every 10 meters. 3. Use case ends. Alternative sequence: 1. Out of Range location, system display “You are out Reach” alert message. Post condition: The system displays the current location. Use case Name: Attraction Actor: User Description: User can access basic information about attraction and historical place. Precondition: Home screen displayed with Attraction link. Main sequence: 1. User touch on Attraction link. 2. The System listed attracting and historical place. 3. Select one of type. 4. System display information about particular place. 5. Use case ends.
  • 30. TOURGONDAR CITY GUIDE MOBILE APPLICATION 22 Alternative sequence: 1.If user does not want to see attracting and historical place, he/she will not be touch on Attraction link. Post condition: System display basic information about particular place Use case Name: Available Service Actor: User Description: User selects the serviceto get information about the service provider. Precondition: Home screen displayed with servicelink. Main sequence: 1 .User touch on servicelink. 2. The system listed different service provider. 3. Select one of the types. 4. System display information about a particular service provider. 5. Use case ends. Alternative sequence: 2.If the user does not want to get information about the service, he/she will not be touch on service link Post condition: System display basic information about a particular service. Use case Name: Search Actor: User Description: The user enters the text in search text field and the system retrieves information from the database that match with the input text. Precondition: The search text field appears on each service screen. Main sequence: 1.The user enters the text in the search text field. 2. Touch on filter button. 3. Use case ends. Alternative sequence: 2. Mismatch input text. Post condition: The system retrieves information that match with the input text.
  • 31. TOURGONDAR CITY GUIDE MOBILE APPLICATION 23 2.5.3. Activity Diagram Activity diagram is basically a flow chart to represent the flow form one activity to another activity. The activity can be described as an operation of the system.[3] . Figure 3 Update content activity diagram
  • 32. TOURGONDAR CITY GUIDE MOBILE APPLICATION 24 Figure 4 Delete content activity diagram
  • 33. TOURGONDAR CITY GUIDE MOBILE APPLICATION 25 Figure 5 Upload content activity diagram
  • 34. TOURGONDAR CITY GUIDE MOBILE APPLICATION 26 Figure 6 Change language activity diagram
  • 35. TOURGONDAR CITY GUIDE MOBILE APPLICATION 27 Figure 7 Detect location activity diagram
  • 36. TOURGONDAR CITY GUIDE MOBILE APPLICATION 28 Figure 8 Attraction activity diagram
  • 37. TOURGONDAR CITY GUIDE MOBILE APPLICATION 29 Figure 9 Available service activity diagram
  • 38. TOURGONDAR CITY GUIDE MOBILE APPLICATION 30 Figure 10 Search activity diagram
  • 39. TOURGONDAR CITY GUIDE MOBILE APPLICATION 31 2.5.4. Object Model 2.5.4.1. Data Dictionary User –has the following attributes  Name  Location Administrator-has the following attributes  User Name  Password Location detector -has the following attributes  Outdoor Language-has the following attributes  Amharic Label  English Label Events-has the following attributes  Cultural event  Religious event  Institutional event Service provider-has the following attributes  Name  Location  Phone no.  Email  Web site Hotels- has the following attributes  Hotels_services Restaurant- has the following attributes  Restaurant_services
  • 40. TOURGONDAR CITY GUIDE MOBILE APPLICATION 32 Police station- has the following attributes  Police_services Bank- has the following attributes  Bank_services Health center- has the following attributes  Medical_services Hospital- has the following attributes  Examine  Bed_room Clinic- has the following attributes  Drugs_shop Tour and Travel agent- has the following attributes  Tour_services  Car_rentals Attraction- has the following attributes  Cultural  Natural Pictures - has the following attributes  Category  Image 2.5.4.2. Class Modeling The purpose of the class diagram is to model the static view of an application. The class diagrams are the only diagrams which can be directly mapped with object oriented languages and thus widely used at the time of construction.[3]
  • 41. TOURGONDAR CITY GUIDE MOBILE APPLICATION 33 High level Class diagram for the new system. Figure 11 High level Class diagram
  • 42. TOURGONDAR CITY GUIDE MOBILE APPLICATION 34 2.5.4.3. Dynamic Modeling State chart diagram Figure 12 state chart diagrams for administrator
  • 43. TOURGONDAR CITY GUIDE MOBILE APPLICATION 35 Figure 13 State chart diagram for users
  • 44. TOURGONDAR CITY GUIDE MOBILE APPLICATION 36 Sequence Diagram A sequence diagram is an interaction diagram that shows how processes operate with one another and in what order. It is a construct of a Message Sequence Chart. A sequence diagram shows object interactions arranged in time sequence. It depicts the objects and classes involved in the scenario and the sequence of messages exchanged between the objects needed to carry out the functionality of the scenario. Sequence diagrams are typically associated with use case realizations in the Logical View of the system under development. Sequence diagrams are sometimes called event diagrams, event scenarios A sequence diagram shows, as parallel vertical lines (lifelines), different processes or objects that live simultaneously, and, as horizontal arrows, the messages exchanged between them, in the order in which they occur. This allows the specification of simple runtime scenarios in a graphical manner.[3]
  • 45. TOURGONDAR CITY GUIDE MOBILE APPLICATION 37 Here is some sequence diagram of the new system. Figure 12 Sequence diagram for updating content
  • 46. TOURGONDAR CITY GUIDE MOBILE APPLICATION 38 Figure 13 Sequence diagram for deleting content
  • 47. TOURGONDAR CITY GUIDE MOBILE APPLICATION 39 Figure 14 Sequence diagram for uploading content
  • 48. TOURGONDAR CITY GUIDE MOBILE APPLICATION 40 Figure 15 Sequence diagram for search
  • 49. 41 2.5.5. User Interface Figure 16 User interface
  • 50. TOURGONDAR CITY GUIDE MOBILE APPLICATION 42 CHAPTER THREE 3. System Design 3.1. Introduction Systems design is the process of defining the architecture, components, modules, interfaces, and data for a system to satisfy specified requirements. The System Design Document describes the system requirements, operating environment, system and subsystem architecture, files and database design, input formats, output layouts, human-machine interfaces, detailed design, processing logic, and external interfaces. In this chapter we try to discuss the design part and also we see the architecture part. After this has been done, the analysis was completed using different UML diagram. System design is the first step to get into the solution domain. In this document we will try to describe the design aspect of the new system.[2] 3.2. Current software architecture In the city currently there is no any software in use to guide the city for the users. 3.3. Proposed software architecture 3.3.1. Overview We try show the bird’s eye view of the new system so that, the software architecture for each subsystem functionality will be the following.
  • 51. TOURGONDAR CITY GUIDE MOBILE APPLICATION 43 Figure 16 Overview of the new system 3.3.2. Subsystem decomposition Component diagram is a special kind of diagram in UML. It does not describe the functionality of the system but it describes the components used to make those functionalities. So from that point component diagrams are used to visualize the physical components in a system. Component diagrams can also be described as a static implementation view of a system. Static implementation represents the organization of the components at a particular moment. Use component diagram to partition a system into subcomponents. The main subsystem of the system list as follows:  User Interface subsystem  Database subsystem  Account Management subsystem.[3]
  • 52. TOURGONDAR CITY GUIDE MOBILE APPLICATION 44 Figure 17 Components diagram for subsystem decomposition
  • 53. TOURGONDAR CITY GUIDE MOBILE APPLICATION 45 3.3.3. Hardware/Software mapping Deployment diagrams are used for describing the hardware components where software components are deployed.[3] Figure 18 Deployment diagram for hardware/software mapping
  • 54. TOURGONDAR CITY GUIDE MOBILE APPLICATION 46 3.3.4. Persistent data management Persistence modeling is used to communicate the design of the database, usually to the developers. It is also used to describe the persistence data aspect of the system. Scheme diagram Events Information Pictures Table 1 Events Hotels Hotels-name Location Phone_no e-mail Hotel_services Table 2 hotels Hotel pictures Hotels-name Category pictures Table 3 hotels pictures Restaurants Restu-name Location Phone_no e-mail Restuarant_services Table 4 restaurants
  • 55. TOURGONDAR CITY GUIDE MOBILE APPLICATION 47 Restaurant pictures Restu-name Category pictures Table 5 restaurant pictures Attractions Att-name Location Phone_no e-mail Services Table 6 attractions Attraction pictures Att-name Category pictures Table 7 attraction pictures Bank Bank-name Location Phone_no e-mail Bank_services Table 8 bank Bank pictures Bank-name Category pictures Table 9 bank pictures
  • 56. TOURGONDAR CITY GUIDE MOBILE APPLICATION 48 Health centers HealthCenter-name Location Phone_no e-mail Medical_services Table 10 health center Health center pictures HealthCenter-name Category pictures Table 11 health center pictures Police station Poli-name Location Phone-no e-mail Police_services Table 12 police station Police station pictures Poli-name Category pictures Table 13 police station pictures Tour and Travel agent TTA-name Location Phone_no e-mail Tour_services Car_rental Table 14 tour and travel agent
  • 57. TOURGONDAR CITY GUIDE MOBILE APPLICATION 49 TTA pictures TTA-name Category Pictures Table 15 TTA pictures 3.3.5. Access control and security In this new system different actor have access to different functionality and data. Who can access what is by using an access control matrix is describe in the following table. The following table describes an actor who is involved in the scene and the possible benefit assigned to the actor. Actor Privilege User requestToView(); Administrator uploadData(); updataData(); deleteData(); Table 16 Access control and security
  • 58. TOURGONDAR CITY GUIDE MOBILE APPLICATION 50 3.3.6. Subsystem services In this section try to cover the main subsystems that are used in the system and the service provide by each subsystem. Those are:  User interface subsystem: this subsystem used to interact the user with system and it is majorly connected with the database subsystem for displaying up to date information that is stored in database.  Database subsystem: this subsystem is used to perform the task that is performed by the administrator. The tasks that are performed in the database are updating information such as deleting and uploading information.  Account management subsystem: this subsystem is used to perform user management and validating there account.
  • 59. TOURGONDAR CITY GUIDE MOBILE APPLICATION 51 3.3.7. Detailed class diagram Figure 19 Detailed class diagram
  • 60. TOURGONDAR CITY GUIDE MOBILE APPLICATION 52 3.3.8. Package Package diagram is UML structure diagram which shows packages and dependencies between the packages. Package diagram enables you to gain a high level understanding of the collaboration among model elements through analyzing the relationships among their parent package. This also helps explain the system's architecture from a broad view.[3] Figure 20 Package diagram
  • 61. TOURGONDAR CITY GUIDE MOBILE APPLICATION 53 CHAPTER FOUR 4. Implementation 4.1. Mapping models to code The system has the following actors.  Administrator  User The administrator who controls all over the system and access the tables in the database these are: Administrator Figure 22 Mapping model for administrator Notice: The administrator has permission of managing or controlling the application and it has one to one relationship. Events Hotels Restaurants Attractions Banks Health Centers Tour and Travel agent
  • 62. TOURGONDAR CITY GUIDE MOBILE APPLICATION 54 The users can view and access information from the database. User Figure 23 Mapping model for User Notice: The user has the permission to view information that is filled by administrator.It has one to one relationship. Events Hotels Restaurants Attractions Banks Health Centers Tour and Travel agent
  • 63. TOURGONDAR CITY GUIDE MOBILE APPLICATION 55 4.2. Source codes of major classes, packages or interfaces //Android manifest file for Gondar city guide application <?xmlversion="1.0"encoding="utf-8"?> <manifestxmlns:android="http://schemas.android.com/apk/res/android" package="com.example.gondarcityguide" android:versionCode="1" android:versionName="1.0"> <uses-sdk android:minSdkVersion="8" android:targetSdkVersion="17"/> <permissionandroid:name="com.example.gondarcityguide.permission.MAPS_RECEIVE" android:protectionLevel="signature"/> <uses- permissionandroid:name="com.example.gondarcityguide.permission.MAPS_RECEIVE"/> <uses-permissionandroid:name="android.permission.INTERNET"/> <uses-permissionandroid:name="android.permission.ACCESS_NETWORK_STATE"/> <uses- permissionandroid:name="com.google.android.providers.gsf.permission.READ_GSERVICE S"/> <uses-permissionandroid:name="android.permission.WRITE_EXTERNAL_STORAGE"/> <uses-permissionandroid:name="android.permission.ACCESS_COARSE_LOCATION"/> <uses-permissionandroid:name="android.permission.ACCESS_FINE_LOCATION"/> <uses-feature android:glEsVersion="0x00020000" android:required="true"/> <application android:allowBackup="true" android:icon="@drawable/ic_launcher" android:label="@string/app_name" android:theme="@style/AppTheme"> <activity android:name="com.example.gondarcityguide.Home_Eng" android:label="@string/app_name"> <intent-filter> <actionandroid:name="android.intent.action.MAIN"/>
  • 64. TOURGONDAR CITY GUIDE MOBILE APPLICATION 56 <categoryandroid:name="android.intent.category.LAUNCHER"/> </intent-filter> </activity> <activityandroid:name=".Home_Amh"android:label="ጎንድርንይጎብኙ"></activity> <activityandroid:name=".Hotel_Eng"android:label="Hotels"android:icon="@drawable/hotel s"></activity> <activityandroid:name=".Hotel_Amh"android:label="ሆቴል"android:icon="@drawable/hotels "></activity> <activityandroid:name=".Restaurant_Eng"android:label="Restaurants"android:icon="@dra wable/resturant"></activity> <activityandroid:name=".Restaurant_Amh"android:label="ሬስቶራንት"android:icon="@drawa ble/resturant"></activity> <activityandroid:name=".Attraction_Eng"android:label="Attractions"android:icon="@draw able/attraction"></activity> <activityandroid:name=".Attraction_Amh"android:label="መስብ"android:icon="@drawable/a ttraction"></activity> <activityandroid:name=".Bank_Eng"android:label="Banks"android:icon="@drawable/bank" ></activity> <activityandroid:name=".Bank_Amh"android:label="ባንክ"android:icon="@drawable/bank"> </activity> <activityandroid:name=".FourSistersRestaurant_Eng"android:label="Four Sisters Restaurant"android:icon="@drawable/resturant"/> <activityandroid:name=".FourSistersRestaurant_Amh"android:label="ፎርሲስተር "android:icon="@drawable/resturant"></activity> <activityandroid:name=".MasterChefRestaurant_Eng"android:label="Master Chef Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".MasterChefRestaurant_Amh"android:label="ማስተርቼፍ"android:ico n="@drawable/resturant"></activity> <activityandroid:name=".DashenBreweryRestaurant_Eng"android:label="Dashen Brewery Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".DashenBreweryRestaurant_Amh"android:label="ዳሽንቢራ"android:i con="@drawable/resturant"></activity> <activityandroid:name=".GohaHotelRestaurant_Eng"android:label="Goha Hotel Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".GohaHotelRestaurant_Amh"android:label="ጎሃሆቴልሬስቶራንት"androi d:icon="@drawable/resturant"></activity> <activityandroid:name=".TayeBelayHotelRestaurant_Eng"android:label="Taye Belay Hotel Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".TayeBelayHotelRestaurant_Amh"android:label="ታዬበላይሆቴልሬስቶራ ንት"android:icon="@drawable/resturant"></activity> <activityandroid:name=".HashBazRestaurant_Eng"android:label="Hash-Baz Restaurant"android:icon="@drawable/resturant"></activity>
  • 65. TOURGONDAR CITY GUIDE MOBILE APPLICATION 57 <activityandroid:name=".HashBazRestaurant_Amh"android:label="ሀሽ - ባዝ"android:icon="@drawable/resturant"></activity> <activityandroid:name=".EliltaCulturalRestaurant_Eng"android:label="Elilta Cultural Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".EliltaCulturalRestaurant_Amh"android:label="እልልታየባህልሬስቶራንት "android:icon="@drawable/resturant"></activity> <activityandroid:name=".HabeshaKitfoRestaurant_Eng"android:label="Habesha Kitfo Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".HabeshaKitfoRestaurant_Amh"android:label="ሀበሻክትፎ ሬስቶራንት"android:icon="@drawable/resturant"></activity> <activityandroid:name=".MiniFogeraRestaurant_Eng"android:label="Mini Fogera Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".MiniFogeraRestaurant_Amh"android:label="ሚኒፎገራሬስቶራንት"andr oid:icon="@drawable/resturant"></activity> <activityandroid:name=".HabeshaCoffeeRestaurant_Eng"android:label="Habesha Coffee Restaurant"android:icon="@drawable/resturant"/> <activityandroid:name=".HabeshaCoffeeRestaurant_Amh"android:label="ሀበሻኮፊሬስቶራንት "android:icon="@drawable/resturant"></activity> <activityandroid:name=".CircleHotelRestaurant_Eng"android:label="Circle Hotel Restaurant"android:icon="@drawable/resturant"></activity> <activityandroid:name=".CircleHotelRestaurant_Amh"android:label="ሰርክልሆቴልሬስቶራንት"an droid:icon="@drawable/resturant"></activity> <activityandroid:name=".AgHotel_Eng"android:label="AG Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".AgHotel_Amh"android:label="ኤጂሆቴል"android:icon="@drawable/ hotels"></activity> <activityandroid:name=".LShapeHotel_Eng"android:label="L-Shape Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".LShapeHotel_Amh"android:label="ኤል- ሼፕሆቴል"android:icon="@drawable/hotels"></activity> <activityandroid:name=".FloridaHotel_Eng"android:label="Florida International Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".FloridaHotel_Amh"android:label="ፍሎሪዳኢተርናሽናልሆቴል"android:ic on="@drawable/hotels"></activity> <activityandroid:name=".TayeBelayHotel_Eng"android:label="Taye Belay Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".TayeBelayHotel_Amh"android:label="ታዬበላይሆቴል"android:icon=" @drawable/hotels"></activity> <activityandroid:name=".GohaHotel_Eng"android:label="Goha Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".GohaHotel_Amh"android:label="ጎሃሆቴል"android:icon="@drawabl e/hotels"></activity> <activityandroid:name=".QuaraHotel_Eng"android:label="Quara Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".QuaraHotel_Amh"android:label="ቋራሆቴል"android:icon="@drawa ble/hotels"></activity>
  • 66. TOURGONDAR CITY GUIDE MOBILE APPLICATION 58 <activityandroid:name=".NewFesicaHotel_Eng"android:label="New Fesica Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".NewFesicaHotel_Amh"android:label="ኒውፋሲካሆቴል"android:icon=" @drawable/hotels"></activity> <activityandroid:name=".YalewAykerHotel_Eng"android:label="Yalew Ayker Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".YalewAykerHotel_Amh"android:label="ያለውአይቀርሆቴል"android:ico n="@drawable/hotels"></activity> <activityandroid:name=".LammergeyerHotel_Eng"android:label="Lammergeyer Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".LammergeyerHotel_Amh"android:label="ላመርገየርሆቴል"android:ico n="@drawable/hotels"></activity> <activityandroid:name=".FogeraHotel_Eng"android:label="Fogera Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".FogeraHotel_Amh"android:label="ፎገራሆቴል"android:icon="@draw able/hotels"></activity> <activityandroid:name=".CircleHotel_Eng"android:label="Circle Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".CircleHotel_Amh"android:label="ሰርክልሆቴል"android:icon="@dra wable/hotels"></activity> <activityandroid:name=".QueensHotel_Eng"android:label="Queens Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".QueensHotel_Amh"android:label="ኪዊስሆቴል"android:icon="@dra wable/hotels"></activity> <activityandroid:name=".LandmarkHotel_Eng"android:label="Landmark Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".LandmarkHotel_Amh"android:label="ጎንደርላድማርክሆቴል"android:ico n="@drawable/hotels"></activity> <activityandroid:name=".JantekleHotel_Eng"android:label="Jantekle Hotel"android:icon="@drawable/hotels"></activity> <activityandroid:name=".JantekelHotel_Amh"android:label="ጃንተክልሆቴል"android:icon="@d rawable/hotels"></activity> <activityandroid:name=".DebreBerhanSelassie_Eng"android:label="Debre Berhan Selassie"android:icon="@drawable/attraction"></activity> <activityandroid:name=".DebreBerhanSelassie_Amh"android:label="ደብረብርሃንስላሴ "android:icon="@drawable/attraction"></activity> <activityandroid:name=".SimenLandTour_Eng"android:label="Simen Land Tour"android:icon="@drawable/attraction"></activity> <activityandroid:name=".SimenLandTour_Amh"android:label="የሰሜንተራሮች"android:icon=" @drawable/attraction"></activity> <activityandroid:name=".FasilGehbbi_Eng"android:label="Fasil Gehbbi"android:icon="@drawable/attraction"></activity> <activityandroid:name=".FasilGehbbi_Amh"android:label="ፋሲልግቢ"android:icon="@drawa ble/attraction"></activity> <activityandroid:name=".FasiladasBath_Eng"android:label="Fasiladas Bath Timket"android:icon="@drawable/attraction"></activity>
  • 67. TOURGONDAR CITY GUIDE MOBILE APPLICATION 59 <activityandroid:name=".FasiladasBath_Amh"android:label="የፋሲለደስመዋኛገንዳ"android:icon ="@drawable/attraction"></activity> <activityandroid:name=".Gondar_Eng"android:label="Gondar"android:icon="@drawable/a ttraction"></activity> <activityandroid:name=".Gondar_Amh"android:label="ጎንደር"android:icon="@drawable/attr action"></activity> <activityandroid:name=".AtseBekefa_Eng"android:label="Atse Bekefa"android:icon="@drawable/attraction"></activity> <activityandroid:name=".AtseBekefa_Amh"android:label="አዔባካፋየባህልምሽት "android:icon="@drawable/attraction"></activity> <activityandroid:name=".Event_Eng"android:label="Events"></activity> <meta-data android:name="com.google.android.maps.v2.API_KEY" android:value="Your api key"/> <meta-dataandroid:name="com.google.android.gms.version" android:value="@integer/google_play_services_version" /> </application> </manifest> //Source code for Get JSON object from URL package com.example.gondarcityguide; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.io.UnsupportedEncodingException; import java.util.List; import org.apache.http.HttpEntity; import org.apache.http.HttpResponse; import org.apache.http.NameValuePair; import org.apache.http.client.ClientProtocolException; import org.apache.http.client.entity.UrlEncodedFormEntity; import org.apache.http.client.methods.HttpGet; import org.apache.http.client.methods.HttpPost; import org.apache.http.client.utils.URLEncodedUtils; import org.apache.http.impl.client.DefaultHttpClient; import org.json.JSONException; import org.json.JSONObject; import android.util.Log;
  • 68. TOURGONDAR CITY GUIDE MOBILE APPLICATION 60 publicclass JSONParser { static InputStream is=null; static JSONObject jObj=null; static String json=""; // constructor public JSONParser(){ } // function get json from url // by making HTTP POST or GET mehtod public JSONObject makeHttpRequest(String url,String method,List<NameValuePair>params){ // Making HTTP request // check for request method try{if(method=="POST") { // request method is POST // defaultHttpClient DefaultHttpClient httpClient = newDefaultHttpClient(); HttpPost httpPost = newHttpPost(url); httpPost.setEntity(new UrlEncodedFormEntity(params)); HttpResponse httpResponse = httpClient.execute(httpPost); HttpEntity httpEntity = httpResponse.getEntity(); is = httpEntity.getContent(); }elseif(method == "GET"){ // request method is GET DefaultHttpClient httpClient = newDefaultHttpClient(); String paramString = URLEncodedUtils.format(params, "utf-8"); url += "?" + paramString; HttpGet httpGet = newHttpGet(url); HttpResponse httpResponse = httpClient.execute(httpGet); HttpEntity httpEntity = httpResponse.getEntity(); is = httpEntity.getContent(); }
  • 69. TOURGONDAR CITY GUIDE MOBILE APPLICATION 61 }catch(UnsupportedEncodingException e) { e.printStackTrace(); }catch(ClientProtocolException e) { e.printStackTrace(); }catch(IOException e) { e.printStackTrace(); } try{ //BufferedReader reader = new BufferedReader(new InputStreamReader(is, "iso-8859-1"), 8); BufferedReader reader = newBufferedReader(new InputStreamReader(is, "UTF-8"), 8000); StringBuilder sb = newStringBuilder(); String line = null; while ((line = reader.readLine()) != null) { sb.append(line + "n"); } is.close(); json = sb.toString(); }catch(Exception e) { Log.e("Buffer Error", "Error Converting Result"+e.toString()); } // try parse the string to a JSON object try { jObj=new JSONObject(json); } catch (JSONException e) { Log.e("JSON Parse", "Error parsing"+e.toString()); } // return JSON String returnjObj; } } //Source code for Home Screen in English java code package com.example.gondarcityguide; import android.os.Bundle; import android.app.Activity;
  • 70. TOURGONDAR CITY GUIDE MOBILE APPLICATION 62 import android.content.Intent; importandroid.view.Menu; import android.view.View; import android.view.View.OnClickListener; import android.widget.AdapterView; import android.widget.AdapterView.OnItemClickListener; import android.widget.Button; importandroid.widget.ImageButton; import android.widget.ListView; importandroid.widget.TextView; publicclass Home_Eng extends Activity implements OnItemClickListener { ListView listView; Button eventBtnEng; Button btnAmahric; String[] title={"Attractions", "Hotels", "Restaurants", "Banks", "Tour and Travel Agents", "Health Centers", "Police Stations"}; Integer[] imageId={R.drawable.attraction, R.drawable.hotels, R.drawable.resturant, R.drawable.bank, R.drawable.tour, R.drawable.health, R.drawable.police}; @Override protectedvoid onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.home__eng); CustomListHomeEng adapter=newCustomListHomeEng(Home_Eng.this,title,imageId); listView=(ListView) findViewById(R.id.listHomeEng); listView.setAdapter(adapter); listView.setOnItemClickListener(this); btnAmahric=(Button) findViewById(R.id.btnAmahric); btnAmahric.setOnClickListener(new OnClickListener() { @Override
  • 71. TOURGONDAR CITY GUIDE MOBILE APPLICATION 63 publicvoid onClick(View arg0) { startActivity(new Intent(getApplicationContext(), Home_Amh.class)); } }); eventBtnEng=(Button) findViewById(R.id.eventBtnEng); eventBtnEng.setOnClickListener(new OnClickListener() { @Override publicvoid onClick(View arg0) { startActivity(new Intent(getApplicationContext(), Event_Eng.class)); } }); } @Override publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) { // TODO Auto-generated method stub //use switch to launch different Activity switch(position){ case 0: Intent att = newIntent(getApplicationContext(), Attraction_Eng.class); startActivity(att); break; case 1: Intent hotel = newIntent(getApplicationContext(), Hotel_Eng.class); startActivity(hotel); break; case 2: Intent res = newIntent(getApplicationContext(), Restaurant_Eng.class); startActivity(res); break; case 3: Intent bank = newIntent(getApplicationContext(), Bank_Eng.class); startActivity(bank); break;
  • 72. TOURGONDAR CITY GUIDE MOBILE APPLICATION 64 default: break; } } } //Xml file for Home Screen in English <RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:gravity="center" tools:context=".Home_Eng"> <TextViewandroid:id="@+id/textLang" android:layout_width="150dp" android:layout_height="38dp" android:text="Language Option" android:paddingLeft="20dp" android:paddingTop="10dp" android:layout_alignParentTop="true" android:textAlignment="center" android:textSize="15dp"/> <Button android:id="@+id/btnAmahric" android:layout_width="174dp" android:layout_height="38dp" android:background="@drawable/toamahricbtn" android:textAlignment="center" android:layout_alignParentRight="true" android:layout_alignParentTop="true" /> <ImageView android:id="@+id/imageView1" android:layout_width="fill_parent" android:layout_height="170dp"
  • 73. TOURGONDAR CITY GUIDE MOBILE APPLICATION 65 android:layout_alignParentLeft="true" android:src="@drawable/homegondarimageenglish" android:adjustViewBounds="true" android:scaleType="fitXY" android:layout_below="@+id/btnAmahric" /> > <ListView android:id="@+id/listHomeEng" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/cityMapBtnEng" android:paddingTop="10dp"> </ListView> <Button android:id="@+id/cityMapBtnEng" android:layout_width="150dp" android:layout_height="40dp" android:layout_below="@+id/imageView1" android:layout_alignParentRight="true" android:background="@drawable/citymapbtnenglish"/> <Button android:id="@+id/eventBtnEng" android:layout_width="150dp" android:layout_height="40dp" android:layout_alignParentLeft="true" android:layout_below="@+id/imageView1" android:background="@drawable/eventsbtnenglish"/> </RelativeLayout> //Source code for Home Screen in Amharic java code package com.example.gondarcityguide; import android.app.Activity; importandroid.app.ListActivity; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.view.View.OnClickListener;
  • 74. TOURGONDAR CITY GUIDE MOBILE APPLICATION 66 import android.widget.AdapterView; import android.widget.AdapterView.OnItemClickListener; import android.widget.Button; import android.widget.ImageButton; import android.widget.ListView; publicclass Home_Amh extends Activity implements OnItemClickListener { ListView listView; ImageButton eventImageBtn; String[] title={ "መስብ", "ሆቴል", "ሬስቶራንት", "ባንክ", "አስጎብኚድርጅት", "የጤናተቀም", "ፖሊስጣቢያ", }; Integer[] imageId={R.drawable.attraction, R.drawable.hotels, R.drawable.resturant, R.drawable.bank, R.drawable.tour, R.drawable.health, R.drawable.police}; @Override protectedvoid onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.home_amh); CustomListHomeAmh adapter=newCustomListHomeAmh(Home_Amh.this, title, imageId); listView=(ListView) findViewById(R.id.listHomeAmh); listView.setAdapter(adapter); listView.setOnItemClickListener(this); Button btnToEnglish=(Button) findViewById(R.id.btnEnglish); btnToEnglish.setOnClickListener(new OnClickListener() { @Override publicvoid onClick(View arg0) { startActivity(new Intent(getApplicationContext(), Home_Eng.class)); }
  • 75. TOURGONDAR CITY GUIDE MOBILE APPLICATION 67 }); } @Override publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) { //use switch to launch different activity switch(position) { case 0: startActivity(new Intent(getApplicationContext(), Attraction_Amh.class)); break; case 1: startActivity(new Intent(getApplicationContext(), Hotel_Amh.class)); break; case 2: startActivity(new Intent(getApplicationContext(), Restaurant_Amh.class)); break; case 3: startActivity(new Intent(getApplicationContext(), Bank_Amh.class)); break; default: break; } } } //Xml file for Home Screen in Amharic <RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:gravity="top" tools:context=".Home_Eng"
  • 76. TOURGONDAR CITY GUIDE MOBILE APPLICATION 68 > <TextViewandroid:id="@+id/textLangAmh" android:layout_width="150dp" android:layout_height="38dp" android:text="የቋንቋአማራጭ" android:paddingLeft="20dp" android:paddingTop="10dp" android:layout_alignParentTop="true" android:textAlignment="center" android:textSize="15dp"/> <Button android:id="@+id/btnEnglish" android:layout_width="175dp" android:layout_height="38dp" android:background="@drawable/toenglishbtn" android:textAlignment="center" android:layout_alignParentRight="true" android:layout_alignParentTop="true" /> <ImageView android:id="@+id/imageView1" android:layout_width="fill_parent" android:layout_height="170dp" android:layout_alignParentLeft="true" android:src="@drawable/homegondarimageamahric" android:adjustViewBounds="true" android:scaleType="fitXY" android:layout_below="@+id/btnEnglish" /> <Button android:id="@+id/eventBtnAmh" android:layout_width="150dp" android:layout_height="40dp" android:layout_below="@+id/imageView1" android:layout_alignParentLeft="true" android:background="@drawable/eventsbtnamahric" android:paddingLeft="10dp"/> <Button
  • 77. TOURGONDAR CITY GUIDE MOBILE APPLICATION 69 android:id="@+id/citymapBtnAmh" android:layout_width="150dp" android:layout_height="40dp" android:layout_below="@+id/imageView1" android:layout_alignParentRight="true" android:background="@drawable/citymapbtnamahric"/> <ListView android:id="@+id/listHomeAmh" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/eventBtnAmh" android:paddingTop="10dp"> </ListView> </RelativeLayout> //Source code for Hotel Activity in English java code package com.example.gondarcityguide; import java.io.File; import java.io.FileOutputStream; import java.io.InputStream; import java.net.HttpURLConnection; import java.net.URL; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import org.apache.http.NameValuePair; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import android.app.AlertDialog; import android.app.ListActivity; import android.app.ProgressDialog; import android.content.DialogInterface; import android.content.Intent; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.AsyncTask; import android.os.Bundle; import android.util.Log;
  • 78. TOURGONDAR CITY GUIDE MOBILE APPLICATION 70 import android.view.View; import android.view.View.OnClickListener; import android.widget.AdapterView; import android.widget.AdapterView.OnItemClickListener; import android.widget.Button; import android.widget.EditText; import android.widget.ListView; import android.widget.SimpleAdapter; publicclass Hotel_Eng extends ListActivity implements OnItemClickListener{ ListView list; EditText getHotel; Button btnFilterHotel; // Progress Dialog private ProgressDialog pDialog; // Creating JSON Parser object JSONParser jParser = newJSONParser(); List<HashMap<String,Object>>hotelList; // url to get all hotels list privatestatic String urlHotel="http://10.139.179.119/test/hotels.php/hotels"; // JSON Node names privatestaticfinal String TAG_HOTELS = "hotels"; privatestaticfinal String TAG_TITLEHOTEL = "TitleHotle"; privatestaticfinal String TAG_DESCHOTEL = "DescHotel"; privatestaticfinal String TAG_IMAGEHOTEL="ImageHotel"; // hotels JSONArray JSONArray hotels=null; @Override protectedvoid onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.hotel_eng); // Hashmap for ListView hotelList=new ArrayList<HashMap<String,Object>>();
  • 79. TOURGONDAR CITY GUIDE MOBILE APPLICATION 71 // Loading hotels in Background Thread new LoadHotels().execute(); //institiatedlistview list=getListView(); list.setOnItemClickListener(this); getHotel=(EditText) findViewById(R.id.getHotel); btnFilterHotel=(Button) findViewById(R.id.btnFilterHotelEng); btnFilterHotel.setOnClickListener(new OnClickListener() { @Override publicvoid onClick(View arg0) { //Text for search String textForSearch=getHotel.getText().toString(); if(textForSearch.equalsIgnoreCase("AG Hotel Gondar")|| textForSearch.equalsIgnoreCase("AG Hotel")|| textForSearch.equalsIgnoreCase("AG")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), AgHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("L-Shape Hotel")|| textForSearch.equalsIgnoreCase("L Shape Hotel")|| textForSearch.equalsIgnoreCase("LShape Hotel")|| textForSearch.equalsIgnoreCase("L-Shape")|| textForSearch.equalsIgnoreCase("L Shape")|| textForSearch.equalsIgnoreCase("LShape")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), LShapeHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Florida International Hotel")|| textForSearch.equalsIgnoreCase("Florida International")||
  • 80. TOURGONDAR CITY GUIDE MOBILE APPLICATION 72 textForSearch.equalsIgnoreCase("Florida Hotel")|| textForSearch.equalsIgnoreCase("Florida")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), FloridaHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Taye Belay Hotel")|| textForSearch.equalsIgnoreCase("Taye Belay")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), TayeBelayHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Goha Hotel")|| textForSearch.equalsIgnoreCase("Goha")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), GohaHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Quara Hotel")|| textForSearch.equalsIgnoreCase("Quara")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), QuaraHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("New Fesica Hotel")|| textForSearch.equalsIgnoreCase("New Fesica")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), NewFesicaHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Yalew Ayker Hotel")|| textForSearch.equalsIgnoreCase("Yalew Ayker")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), YalewAykerHotel_Eng.class));
  • 81. TOURGONDAR CITY GUIDE MOBILE APPLICATION 73 } elseif(textForSearch.equalsIgnoreCase("Lammergeyer Hotel")|| textForSearch.equalsIgnoreCase("Lamergeyer Hotel")|| textForSearch.equalsIgnoreCase("Lammergeyer")|| textForSearch.equalsIgnoreCase("Lamergeyer")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), LammergeyerHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Fogera Hotel")|| textForSearch.equalsIgnoreCase("Fogera")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), FogeraHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Circle Hotel")|| textForSearch.equalsIgnoreCase("Circle")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), CircleHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Queens Hotel")|| textForSearch.equalsIgnoreCase("Queen Hotel")|| textForSearch.equalsIgnoreCase("Queens")|| textForSearch.equalsIgnoreCase("Queen")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), QueensHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Gondar Landmark Hotel")|| textForSearch.equalsIgnoreCase("Landmark Hotel")|| textForSearch.equalsIgnoreCase("Gondar Landmark")||
  • 82. TOURGONDAR CITY GUIDE MOBILE APPLICATION 74 textForSearch.equalsIgnoreCase("Landmark")){ //if it is match the string launching the activity startActivity(new Intent(getApplicationContext(), LandmarkHotel_Eng.class)); } elseif(textForSearch.equalsIgnoreCase("Jantekel Hotel")|| textForSearch.equalsIgnoreCase("Jantekel")){ startActivity(new Intent(getApplicationContext(), JantekleHotel_Eng.class)); } else{ AlertDialog.Builder builder=newAlertDialog.Builder(Hotel_Eng.this); builder.setMessage("Sorry! No Match is Foundn Please check the spelling."); builder.setCancelable(false); builder.setPositiveButton("Ok", new DialogInterface.OnClickListener() { @Override publicvoid onClick(DialogInterface dialog, int which) { Hotel_Eng.this.finish(); } }); AlertDialog alert=builder.create(); alert.show(); } } });
  • 83. TOURGONDAR CITY GUIDE MOBILE APPLICATION 75 } //Launching differen Activity by click on list item @Override publicvoid onItemClick(AdapterView<?> parent, View view, int position, long id) { //use switch statment to launch Activity switch(position) { case 0: startActivity(new Intent(getApplicationContext(), AgHotel_Eng.class)); break; case 1: startActivity(new Intent(getApplicationContext(), LShapeHotel_Eng.class)); break; case 2: startActivity(new Intent(getApplicationContext(), FloridaHotel_Eng.class)); break; case 3: startActivity(new Intent(getApplicationContext(), TayeBelayHotel_Eng.class)); break; case 4: startActivity(new Intent(getApplicationContext(), GohaHotel_Eng.class)); break; case 5: startActivity(new Intent(getApplicationContext(), QuaraHotel_Eng.class)); break; case 6: startActivity(new Intent(getApplicationContext(), NewFesicaHotel_Eng.class)); break; case 7: startActivity(new Intent(getApplicationContext(), YalewAykerHotel_Eng.class)); break; case 8: startActivity(new Intent(getApplicationContext(), LammergeyerHotel_Eng.class)); break;
  • 84. TOURGONDAR CITY GUIDE MOBILE APPLICATION 76 case 9: startActivity(new Intent(getApplicationContext(), FogeraHotel_Eng.class)); break; case 10: startActivity(new Intent(getApplicationContext(), CircleHotel_Eng.class)); break; case 11: startActivity(new Intent(getApplicationContext(), QueensHotel_Eng.class)); break; case 12: startActivity(new Intent(getApplicationContext(), LandmarkHotel_Eng.class)); break; case 13: startActivity(new Intent(getApplicationContext(), JantekleHotel_Eng.class)); break; default: break; } } // Response from Edit Product Activity @Override protectedvoid onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); // if result code 100 if (resultCode == 100) { // if result code 100 is received // means user edited/deleted product // reload this screen again Intent intent = getIntent(); finish(); startActivity(intent); } } //Background Async Task to Load all hotels by making HTTP Request class LoadHotels extends AsyncTask<String, String, String>{
  • 85. TOURGONDAR CITY GUIDE MOBILE APPLICATION 77 //Before starting background thread Show Progress Dialog protectedvoid onPreExecute() { super.onPreExecute(); pDialog=new ProgressDialog(Hotel_Eng.this); pDialog.setMessage("Loading Hotels ...please wait"); pDialog.setIndeterminate(false); pDialog.setCancelable(false); pDialog.show(); } //getting All Hotels from url @Override protected String doInBackground(String... args) { // Building Parameters List<NameValuePair> params = new ArrayList<NameValuePair>(); // getting JSON string from URL JSONObject json = jParser.makeHttpRequest(urlHotel, "GET", params); // Check your log cat for JSON reponse Log.d("All Hotels: ", json.toString()); //get json Array try { hotels=json.getJSONArray(TAG_HOTELS); // looping through All hotels for (int i = 0; i <hotels.length(); i++) { JSONObject c = hotels.getJSONObject(i); // Storing each json item in variable String TitleHotel = c.getString(TAG_TITLEHOTEL); String DescHotel = c.getString(TAG_DESCHOTEL); String ImageHotel=c.getString(TAG_IMAGEHOTEL); // creating new HashMap HashMap<String, Object> map=new HashMap<String, Object>(); // adding each child node to HashMap key => value map.put(TAG_TITLEHOTEL, TitleHotel);