Ios Application for Finding Halal Food, Mosque, Qibla Direction and Prayer TIME

Muslim sometimes has trouble when they travel to a new place for find where the location of the halal food and mosque near their location is. Other things that Muslim will have difficulty when they travel in to a new place are find the Qibla direction, pray time in local time and the mosque location near their location. From that problem MLH (Muslim Little Helper) want to help them to solve their problem. The process is carried out as follows: The app get the user location, send the location to the YELP API server and muslimshalat.com API to get the location of halal food, and mosque (using YELP) and for find the direction of Qibla and the prayer schedule (by using muslimshalat.com API). After the system get the data, then it will show on the Map (using apple map inside the app) and put the data as marker. For the Qibla direction and prayer time, it will show in arrow image and listview. This app will be use Swift for the development language. The test result shows that the YELP API can be use only in USA, and internet play as the main rule in this app, because to create connection to the server to pull the data, the system need internet to pass all the data to server.


INTRODUCTION
Halal is an Arabic word meaning lawful or permitted. The opposite of halal is haram, which means unlawful or prohibited. [2] Halal and haram are universal terms that apply to all facets of life but this discussion will be limited to food products, meat products, cosmetics, personal care products, pharmaceuticals, food ingredients, and food contact materials. Muslim sometimes has trouble when they travel to a new place for find where the location of the halal food near their location is.
Other things that Muslim will have difficulty when they travel in to a new place are find the Qibla direction, Pray time in local time, and the mosque location near their location. Qibla in Islam is points towards the city of Mecca and specifically to the Ka'abah. Muslim should face the Qibla direction when they pray, and this direction will be change depends on the location of them. Muslim prayer time also change depend on the condition of the Sun and geography. The time will change every day. From the entire problem that Muslim will have when they travel, Muslim Little Helper (MLH) is an IOS base app that will help them to solve their problem.

THEORY FOUNDATION
iOS iOS (originally iPhone OS) is a mobile operating system created and developed by Apple Inc. and distributed exclusively for Apple hardware. It is the operating system that presently powers many of the company's mobile devices, including the iPhone, iPad, and iPod touch. In October 2015, it was the most commonly used mobile operating system, in a few countries, such as in Canada, the United States, the United Kingdom, Norway, Sweden, Denmark, Japan, and Australia. While iOS is far behind Google's Android globally, iOS had a 19.7% share of the smartphone mobile operating system units shipped in the fourth quarter of 2014, behind Android with 76.6% [1]. However, on tablets, iOS is the most commonly used tablet operating system in the world [3].
The power of iOS can be felt with some of the following features provided as a part of the device, such as: This app will be using, accelerometer, Maps, GPS and some API for the development.

Apple Maps
Apple Maps is a web mapping service application developed by Apple Inc. for its iOS, OS X and watchOS operating systems. It allows turn-byturn navigation by car or walking including rerouting, and night mode. It is the default mapping application for iPhone, iPad and Apple computers. It can be controlled by voice with Siri. Introduced in 2012, it replaced Google Maps which had been the default mapping application on Apple iOS and OS X products. Its release was met with considerable criticism due to many mapping errors.

Accelerometer
As mentioned already, Apple devices typically come with a collection of onboard instruments suited to detect motion -namely, the accelerometer, the magnetometer, and the gyroscope. Much could be written about each of these instruments, but for our purposes I want to focus solely on the accelerometer and demonstrate how it is managed through Core Motion in iOS.
According to Apple, the accelerometer is used to measure device "acceleration along the three spatial axes at a moment of time." That means that we have available to us a data set that describes the hardware orientation (e.g. vertical and horizontal positions) at any given time. Our task then is to discover how to access that data and then do something useful with it.

GPS
The Global Positioning System (GPS) is a space-based navigation system that provides location and time information in all weather conditions, anywhere on or near the Earth where there is an unobstructed line of sight to four or more GPS satellites. The system provides critical capabilities to military, civil, and commercial users around the world. The United States government created the system, maintains it, and makes it freely accessible to anyone with a GPS receiver.
Location services provide a way to improve the app by enhancing the user experience. For a travel app, the app can base on the users' current location to search for nearby restaurants or hotels. The App can also find the location feature in most of the Photo apps that saves where the pictures are taken. With the GPS coordinate obtained, the app can make use of the API to decode the actual street or utilize the Map framework to further display the location on Map.

Swift
Swift is a new programming language for iOS and OS X apps that builds on the best of C and Objective-C, without the constraints of C compatibility. Swift adopts safe programming patterns and adds modern features to make programming easier, more flexible, and more fun. Swift's clean slate, backed by the mature and much-loved Cocoa and Cocoa Touch frameworks, is an opportunity to reimagine how software development works.
Swift has been years in the making. Apple laid the foundation for Swift by advancing our existing compiler, debugger, and framework infrastructure. We simplified memory management with Automatic Reference Counting (ARC). Our framework stack, built on the solid base of Foundation and Cocoa, has been modernized and standardized throughout. Objective-C itself has evolved to support blocks, collection literals, and modules, enabling framework adoption of modern language technologies without disruption. Thanks to this groundwork, we can now introduce a new language for the future of Apple software development [4].
Swift feels familiar to Objective-C developers. It adopts the readability of Objective-C's named parameters and the power of Objective-C's dynamic object model. It provides seamless access to existing Cocoa frameworks and mix-and-match interoperability with Objective-C code. Building from this common ground, Swift introduces many new features and unifies the procedural and object-oriented portions of the language.
Swift is friendly to new programmers. It is the first industrial-quality systems programming language that is as expressive and enjoyable as a scripting language. It supports playgrounds, an innovative feature that allows programmers to experiment with Swift code and see the results immediately, without the overhead of building and running an app.
Swift combines the best in modern language thinking with wisdom from the wider Apple engineering culture. The compiler is optimized for performance, and the language is optimized for development, without compromising on either. It's designed to scale from "hello, world" to an entire operating system. All this makes Swift a sound future investment for developers and for Apple.

Yelp API
Yelp is an American multinational corporation headquartered in San Francisco, California. It develops, hosts and markets Yelp.com and the Yelp mobile app, which publish crowd-sourced reviews about local businesses, as well as the online reservation service SeatMe and online food-delivery service Eat24. The company also trains small businesses in how to respond to reviews, hosts social events for reviewers, and provides data about businesses, including health inspection scores.
Yelp was founded in 2004 by former PayPal employees, Russel Simmons and Jeremy Stoppelman. Yelp grew quickly and raised several rounds of funding. By 2010 it had $30 million in revenues and the website had published more than 4.5 million crowd-sourced reviews. From 2009-2012, Yelp expanded throughout Europe and Asia. In 2009 it entered several negotiations with Google for a potential acquisition. Yelp became a public company in March 2012 and became profitable for the first time two years later. As of 2014, Yelp.com has 135 million monthly visitors and 71 million reviews. The company's revenues come from businesses advertising.
The Yelp APIs are RESTful APIs and users can retrieve business review and rating, information for a particular geographic region or location.display review information for a particular business, determine accurate neighborhood name information for a particular location, track recent reviews for a particular business, display pictures of highly rated local businesses and of the top reviewers for that business, determine a particular business' review and rating information based on the phone number for that business. The default output is JSON. This output format was chosen due to the availability of JSON parsers in many languages. The Yelp v2.0 API enables access to more relevant search results that more closely match the results on Yelp. It uses a standard and secure authorization protocol (OAuth 1.0a, xAuth) [5].

Muslimshalat.com API
Muslimshalat.com is a website that serves data and API for the Prayer time and Qibla location. This API will send back a JSON file when the app send a request. JSON (JavaScript Object Notation) is a lightweight data-interchange format. It is easy for humans to read and write. It is easy for machines to parse and generate.

Usecase diagram of Muslim Little Helper App.
Use case diagram is an overview of the interaction between components a system to be built. Use case diagrams can also be documenting system requirements well. Here is a picture of use case has been identified ( Figure 1). This usecase diagram system will be devided into 3 activity diagram that is Halal Food Location activity diagram, Qibla direction & prayer time activity diagram, and Mosque Location activity diagram.

Mosque Location Activity Diagram
In mosque location activity diagram, it describes the flow what user and system did in mosque location Activity. Mosque location activity diagram can be seen in the Figure 4. Mosque Location Activity Diagram. In the end of this activity diagram, the system will moved the activity from mosque location to the apple map apps to show the location of the mosque location and give user the direction from their point to the mosque location.

Yelp API
To pull data from Yelp API, the app need to implement class BDBO Auth 1 Request Operation Manager. This class needed to make a oauth request to Yelp Server. Because this app need to make Oauth request, this app need Yelp customer secret, Yelp customer key, Yelp token, Yelp token secret, and Yelp signature method. After that, this app need a function inside the implementation class that send the query to the Yelp Server. The code of that function can be seen on Segment Program 1. if location != nil { parameters = ["term": term, "ll": location, "radius": "1"] } else { parameters = ["term": term, "ll": "40.7460424,-74.0068579", "radius":

Qibla direction and prayer time
This activity will show the direction of qibla, and the list of prayer time for that day. When user moves their phone, the arrow will change the direction to where the qibla is.

Halal Food Activity
Basically this activity similar to the mosque activity, the different between these two activities is in Halal food, you can search for the Halal Food name. And there is no Go button but there is detail button.   The get direction button has the same function with the Go button in the mosque location activity.

CONCLUSION
Base on the testing process, there are a few things that we can conclude base on this app:  Yelp API just available on US.  Internet connection plays the main rule in this app, because without internet connection the app can pull data from the API.