Professional Documents
Culture Documents
Smart Complaint Registeration For Government Bodies by Nasar
Smart Complaint Registeration For Government Bodies by Nasar
2011-2012
CHAPTER 1 INTRODUCTION
The proposed mobile natural language based interface system emulates the functionality of the web portal based complaint filing system. The architecture of the system is shown in Figure 1.1. The users use the mobile phone and do not need to access the web portal interface directly to file their complaint. The user downloads an application onto his mobile phone. The user runs the application on his phone to get a welcome screen. The system allows the user to compose his complaint in 160 characters.
Page 1
2011-2012
Once these information has been inferred by the system, it sends the information to the Muncipal complaint handling system in a compatible format as a HTTP request. The response of the Muncipal complaint handling portal is fetched and is parsed to determine the complaint number. This complaint number is then received by the user on his mobile phone.
In the event the complaint is incomplete in the sense of not having all the information that is mandatorily required to generate a complaint number at the Muncipal portal; the system gets into an interaction. In this mode, the system generates a set of dynamically generated queries to seek the required information from the user through menu choices. Once the system has all the required information, it send to the Muncipal complaint handling.
Page 2
2011-2012
Features
Smart Complaint Register for Government bodies have following features: (a) it requires no change in the already existing web portal to lodge complaints. (b) doesnt require the citizen to remember any specific information to lodge their complaint.
(c) the mobile channel makes active citizen participation possible because of the higher penetration of mobile phones in India.
1.2
Problem statement
Municipal corporation (MC) of a city is a local governing body which takes care of the functioning of the city. Among many other things one of the chief responsibilities of an MC includes addressing the complaints that the residents of the city might have. Maintenance of a large city requires that the MC be aware of any shortcomings either through surveillance (sensors/cameras) or by allowing the citizens to report them. The second option is usually preferred because there is a sense of belonging. A mechanism to accept complaints from citizens 24 7 would be the expectation from both the citizens and the MC. The MC allows its citizens to place their complaints through several channels.
The chief modes of complaint registration is (a) A visit to the ward office where a person in charge listens to the complaint and asks for some personal details and put it across into an electronic form for other departments within the MC to handle the complaint.
(b) Through a contact center over a telephone - where the complaint is registered by an call center agent by typing the complaint into the system and more recently.
(c) Through a web portal. Dept of CS&E, Vemana Institute of Technology Page 3
2011-2012
1.3
Objective
Project propose a natural English enabled mobile interface which can be used to lodge complaints. The essential idea is to make use of the existing web portal infrastructure and provide an easy, cheap and quick (complain as you see) mode of complaint registration around the clock. The proposed system enables and assists citizens to lodge compliant and seek redressal through their mobile phone in natural language
Page 4
2011-2012
Page 5
2011-2012
Android is a software stack for mobile devices that includes an operating system, middleware and key applications. Android is a software platform and operating system for mobile devices based on the Linux operating system and developed by Google and the Open Handset Alliance. It allows developers to write managed code in a Java-like language that utilizes Google-developed Java libraries, but does not support programs developed in native code. The unveiling of the Android platform on 5 November 2007 was announced with the founding of the Open Handset Alliance, a consortium of 34 hardware, software and telecom companies devoted to advancing open standards for mobile devices. When released in 2008, most of the Android platform will be made available under the Apache free-software and opensource license.
Open - Android allows to access core mobile device functionality through standard API calls. All applications are equal - Android does not differentiate between the phone's basic and third-party applications -- even the dialer or home screen can be replaced. Breaking down boundaries - Combine information from the web with data on the phone -- such as contacts or geographic location -- to create new user experiences. Fast and easy development - The SDK contains what need to build and run Android applications, including a true device emulator and advanced debugging tools.
Page 6
2011-2012
On 5 November 2007, the Open Handset Alliance, a consortium of several companies which include Google, HTC, Intel, Motorola, Qualcomm, T-Mobile, Sprint Nextel and NVIDIA, was unveiled with the goal to develop open standards for mobile devices. Along with the formation of the Open Handset Alliance, the OHA also unveiled their first product, Android, an open source mobile device platform based on the Linux operating system.
2.2.3 Hardware
Google has unveiled at least three prototypes for Android, at the Mobile World Congress on February 12, 2008. One prototype at the ARM booth displayed several basic Google applications. Ad-pad' control zooming of items in the dock with a relatively quick response.
Application framework enabling reuse and replacement of components Dalvik virtual machine optimized for mobile devices Integrated browser based on the open source WebKit engine Optimized graphics powered by a custom 2D graphics library; 3D graphics based on the OpenGL ES 1.0 specification (hardware acceleration optional)
SQLite for structured data storage Media support for common audio, video, and still image formats (MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, GIF)
GSM Telephony (hardware dependent) Bluetooth, EDGE, 3G, and Wi-Fi (hardware dependent) Camera, GPS, compass, and accelerometer (hardware dependent)
Page 7
2011-2012
Rich development environment including a device emulator, tools for debugging, memory and performance profiling, and a plug-in for the Eclipse IDE.
2.4.1APPLICATION FRAMEWORK
Developers have full access to the same framework APIs used by the core applications. The application architecture is designed to simplify the reuse of components; any application can publish its capabilities and any other application may then make use of those capabilities (subject to security constraints enforced by the framework). This same mechanism allows components to Dept of CS&E, Vemana Institute of Technology Page 8
Smart Complaint Register for Govt Bodies be replaced by the user. Underlying all applications is a set of services and systems, including:
2011-2012
A rich and extensible set of Views that can be used to build an application, including lists, grids, text boxes, buttons, and even an embeddable web browser.
Content Providers that enable applications to access data from other applications (such as Contacts), or to share their own data.
A Resource Manager, providing access to non-code resources such as localized strings, graphics, and lat files.
A Notification Manager that enables all applications to display custom alerts in the status bar.
An Activity Manager that manages the life cycle of applications and provides a common navigation back stack.
2.4.1 LIBRARIES
Android includes a set of C/C++ libraries used by various components of the Android system. These capabilities are exposed to developers through the Android application framework. Some of the core libraries are listed below: System C library - a BSD-derived implementation of the standard C system library (libc), tuned for embedded Linux-based devices. Media Libraries - based on Packet Videos Open CORE; the libraries support playback and recording of many popular audio and video formats, as well as static image files, including MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG. Surface Manager - manages access to the display subsystem and seamlessly composites 2D and 3D graphic layers from multiple applications.
Page 9
2011-2012
LibWebCore - a modern web browser engine which powers both the Android browser and an embeddable web view.
SGL - the underlying 2D graphics engine. 3D libraries - an implementation based on OpenGL ES 1.0 APIs; the libraries use either hardware 3D acceleration (where available) or the included, highly optimized 3D software rasterizer.
Free Type - bitmap and vector font rendering. SQLite - a powerful and lightweight relational database engine available to all applications.
Android includes a set of core libraries that provides most of the functionality available in the core libraries of the Java programming language. Every Android application runs in its own process, with its own instance of the Dalvik virtual machine. Dalvik has been written so that a device can run multiple VMs efficiently. The Dalvik VM executes files in the Dalvik Executable (.dex) format which is optimized for minimal memory footprint. The VM is register-based, and runs classes compiled by a Java language compiler that have been transformed into the .dex format by the included "dx" tool. The Dalvik VM relies on the Linux kernel for underlying functionality such as threading and low-level memory management.
At the same level there is Android Runtime, where the main component Dalvik Virtual Machine is located. It was designed specifically for Android running in limited environment, where the limited battery, CPU, memory and data storage are the main issues. Android gives an integrated tool dx, which converts generated byte code from .jar to .dex file, after this byte code becomes much more efficient to run on the small processors.
Page 10
2011-2012
Figure 2.2: Conversion from .java to .dex file As the result, it is possible to have multiple instances of Dalvik virtual machine running on the single device at the same time. The Core libraries are written in Java language and contains of the collection classes, the utilities, IO and other tools.
1. WCDMA/HSUPA and EGPRS network support 2. Bluetooth 1.2 and Wi-Fi support 3. Digital audio support for mp3 and other formats 4. Support for Linux and other third-party operating systems 5. Java hardware acceleration and support for Java applications 6. Qcamera up to 6.0 megapixels
Page 11
2011-2012
Page 12
2011-2012
Page 13
2011-2012
Figure 2.4: Android Execution Environment Following these guidelines, its possible to integrate existing Java source code, packages and libraries piecemeal. Special care will be needed in the integration phase of such code but the potential savings offered by such integration far outweighs the cost of rewriting well-coded, Dept of CS&E, Vemana Institute of Technology Page 14
2011-2012
well-documented and well-tested libraries ready for use. Furthermore, it is expected that has Apache Harmony matures, more and more compatibility issues will be resolved further increasing the pool of available Java code that will be able to execute unmodified under the Android platform.
The Dalvik virtual machine is an interpreter only machine optimized for use on low powered, low memory devices like phones. Notably, Dalvik does not make use of just in time (JIT) Compilation to improve the performance of an application at runtime. Furthermore, Dalvik is not a Java virtual machine. This is because Dalvik is unable to read Java bytecode34; instead it uses its own bytecode format called dex. Google claims this format allows battery power to be better-conserved at all different stages of execution of an application. This means that standard Java SE applications and libraries cannot be used directly on the Android Dalvik virtual machine. Dalvik however stands at the centre of the Android value proposition. Its low electrical power consumption, rich libraries, and unified, non-fragmented application programming interfaces make it stand out, or so Google hopes, over the fragmented ecosystem that is Java ME35 today. Furthermore, since Dalvik uses the Java programming language but not the Java execution environment (JVM), Google is free to develop Android without the need to license or obtain certification from Sun Microsystems Inc, the legal owner of the Java trademark and brands.
An important and unusual feature of Android is that an application process's lifetime is not directly controlled by the application itself. Instead, it is determined by the system through a combination of the parts of the application that the system knows are running, how important these things are to the user, and how much overall memory is available in the system. Dept of CS&E, Vemana Institute of Technology Page 15
2011-2012
It is important that application developers understand how different application components (in particular Activity, Service, and IntentReceiver) impact the lifetime of the application's process. Not using these components correctly can result in the system killing the application's process while it is doing important work.
A common example of a process life-cycle bug is an IntentReceiver that starts a thread when it receives an Intent in its onReceiveIntent() method, and then returns from the function. Once it returns, the system considers that IntentReceiver to be no longer active, and thus its hosting process no longer needed (unless other application components are active in it). Thus, it may kill the process at any time to reclaim memory, terminating the spawned thread that is running in it. The solution to this problem is to start a Service from the IntentReceiver, so the system knows that there is still active work being done in the process. To determine which processes should be killed when low on memory, Android places them into an "importance hierarchy" based on the components running in them and the state of those components. These are, in order of importance:
1. A foreground process is one holding an Activity at the top of the screen that the user is interacting with (its onResume () method has been called) or an IntentReceiver that is currently running (its onReceiveIntent () method is executing). There will only ever be a few such processes in the system, and these will only be killed as a last resort if memory is so low that not even these processes can continue to run. Generally at this point the device has reached a memory paging state, so this action is required in order to keep the user interface responsive.
2. A visible process is one holding an Activity that is visible to the user on-screen but not in the foreground (its onPause() method has been called). This may occur, for example, if the foreground activity has been displayed with a dialog appearance that allows the previous activity to be seen behind it. Such a process is considered extremely important and will not be killed unless doing so is required to keep all foreground processes running.
Page 16
2011-2012
Page 17
2011-2012
3. A service process is one holding a Service that has been started with the startService() method. Though these processes are not directly visible to the user, they are generally doing things that the user cares about (such as background mp3 playback or background network data upload or download), so the system will always keep such processes running unless there is not enough memory to retain all foreground and visible process.
4. A background process is one holding an Activity that is not currently visible to the user (its onStop() method has been called). These processes have no direct impact on the user experience. Provided they implement their activity life cycle correctly (see Activity for more details), the system can kill such processes at any time to reclaim memory for one of the three previous processes types. Usually there are many of these processes running, so they are kept in
5.
An empty process is one that doesn't hold any active application components. The
only reason to keep such a process around is as a cache to improve start-up time the next time a component of its application needs to run. As such, the system will often kill these processes in order to balance overall system resources between these empty cached processes and the underlying kernel caches. When deciding how to classify a process, the system picks the most important level of all the components currently active in the process.
Smart Complaint Register for Govt Bodies gives an incredible boost in developing Android applications:
2011-2012
It gives access to other Android development tools from inside the Eclipse IDE. For example, ADT lets access the many capabilities of the DDMS tool taking screenshots, managing port-forwarding, setting breakpoints, and viewing thread and process information directly from Eclipse.
It provides a New Project Wizard, which helps quickly create and set up all of the basic files will need for a new Android application. It automates and simplifies the process of building are Android application. It provides an Android code editor that helps write valid XML for are Android manifest and resource files. Dalvik Debug Monitor Service (DDMS) Integrated with Dalvik, the Android platform's custom VM, this tool lets manage processes on an emulator or device and assists in debugging. Can use it to kill processes, select a specific process to debug, generate trace data, view heap and thread information, take screenshots of the emulator or device, and more. Android Debug Bridge (ADB) The ADB tool lets install applications .apk files on an emulator or device and access the emulator or device from a command line. This is also used to link a standard debugger to application code running on an Android emulator or device. Android Asset Packaging Tool (AAPT) The AAPT tool lets create .apk files containing the binaries and resources of Android applications.
Android Interface Description Language (AIDL) AIDL lets to generate code for an interprocess interface, such as what a service might use. Included as a convenience, this tool lets access the SQLite data files created and used by Android applications.
Trace view This tool produces graphical analysis views of trace log data that can generate from our
Page 19
2011-2012
Helps create a disk image that can use with the emulator, to simulate the presence of an external storage card (such as an SD card). The dx tool rewrites .class bytecode into Android bytecode (stored in .dex files.) activityCreator A script that generates build files that can use to compile our Android applications. If we are developing on Eclipse with the ADT plugin, we wont need to use this script.
2011-2012
an integrated application that includes anti-virus, anti-spam, firewall and other mobile protection is up and ready to run on the Android operating system. Currently, the main problem is availability for viruses to pose as an application and do things like dial phone numbers, send text messages or multi-media messages or make connections to the Internet during normal device use. It is possible for somebody to use the GPS feature to track a persons location without their knowledge. Hence SMobile Systems is ready to notify and block these secure alerts. But the truth is that it is not possible to secure r mobile device or personal computer completely, as it connects to the internet. And neither the Android phone nor other devices will prove to be the exception.
This will unleash a new round of creativity in the mobile space. Android is open to all: industry, developers and users Participating in many of the successful open source projects Aims to be as easy to build for as the web. Google Android is stepping into the next level of Mobile Internet
The aim of this phase is to develop the application using necessary development tools according to the system requirements specifications. All the functionalities specified in the requirements document should be implemented. All the non functional requirements should also be considered during the implementation phase. The implementation should exactly follow the Dept of CS&E, Vemana Institute of Technology Page 21
Smart Complaint Register for Govt Bodies design guidelines which are documented in design document. Following tools has been used for development: 1. Eclipse IDE for Java developers 2. JDK 1.6 32-bit 3. Android Development Tool (ADT) plugin for eclipse 4. Android SDK 2.2 (Froyo) 5. Windows 7 64-bit operating system.
2011-2012
The XML parsing process operates in three phases: 1. XML input processing. In this stage, the application parses and validates the source document recognizes and searches for relevant information based on its location or its tagging in the source document; extracts the relevant information when it is located; and, optionally, maps and binds the retrieved information to business objects.
2. Business logic handling. This is the stage in which the actual processing of the input information takes place. It might result in the generation of output information. Dept of CS&E, Vemana Institute of Technology Page 22
2011-2012
3. XML output processing. In this stage, the application constructs a model of the document to be generated with the Document Object Model (DOM). It then either applies XSLT style sheets or directly serializes to XML. An application that implements such a processing model is called an XML parser. You can integrate an XML parser into your Java applications with the Java API for XML Processing (JAXP). JAXP allows applications to parse and transform XML documents using an API that is independent of any particular XML processor implementation. Through a plug-in scheme, developers can change XML processor implementations without altering their applications.
The Global Positioning System (GPS) is a space-based global navigation satellite system that provides reliable location and time information in all weather and at all times and anywhere on or near the Earth where there is an unobstructed line of sight to four or more GPS satellites. It is maintained by the United States government and is freely accessible by anyone with a GPS receiver.
The GPS consists of three parts: the space segment, the control segment, and the user segment. The U.S. Air Force develops, maintains, and operates the space and control segments. GPS satellites broadcast signals from space, which each GPS receiver uses to calculate its threedimensional location (latitude, longitude, and altitude) plus the current time. The space segment is composed of 24 to 32 satellites in medium Earth orbit and also includes the boosters required to launch them into orbit. The control segment is composed of a master control station, an alternate master control station, and a host of dedicated and shared ground antennas and monitor stations. The user segment is composed of hundreds of thousands of U.S. and allied military users of the secure GPS Precise Positioning Service, and tens of millions of civil, commercial, and scientific users of the Standard Positioning Service (see GPS navigation devices). Dept of CS&E, Vemana Institute of Technology Page 23
2011-2012
GPS has become a widely used aid to navigation worldwide, and a useful tool for mapmaking, land surveying, commerce, scientific uses, tracking and surveillance, and hobbies such as geo caching and way marking. The precise time reference provided by GPS is used in many applications including the scientific study of earthquakes and as a time synchronization source for cellular network protocols. In addition, GPS has, in the words of the website gps.gov, become a mainstay of transportation systems worldwide, providing navigation for aviation, ground, and maritime operations. Disaster relief and emergency services depend upon GPS for location and timing capabilities in their life-saving missions. The accurate timing provided by GPS facilitates everyday activities such as banking, mobile phone operations, and even the control of power grids. Farmers, surveyors, geologists and countless others perform their work more efficiently, safely, economically, and accurately using the free and open GPS signal.
Using Location based services (LBS) LBS different technologies used to find a devices current location Two main LBS elements Location Manager provides hooks to the LBS Location Providers represents a different location-finding technology used to determine the devices current location. Using Location Manager, Obtain current location Track movement Set proximity alerts Find available Location Providers Selecting a Location Provider Depending on device, there may be several technologies that Android can use to determine the current location with different capabilities(power consumption, monetary cost, accuracy and ability to determine altitude, speed etc..) To get an instance of a specific provider, Dept of CS&E, Vemana Institute of Technology Page 24
Smart Complaint Register for Govt Bodies String providerName = LocationManager.GPS_PROVIDER; LocationProvider gpsProvider = locationManager.getProvider(providerName);
2011-2012
This is useful to determine abilities of a particular provider. Two common Location providers LocationManager.GPS_PROVIDER LocationManager.NETWORK_PROVIDER
Finding your location Access to the location-based service is handled by Location Manager system service. LocationManager locationManager = (LocationManager)
getSystemService(LOCATION_SERVICE); Add one or more uses-permissions in manifest. <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION/> <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION/> To find the last location fix determined by a particular provider, Location location =
locationManager.getLastKnownLocation(LocationManager.GPS_PROVIDER); Location object contains all the position information which can be retrieved using get methods. getLastKnownLocation() does not ask the provider to update the current position.
2.7.2 GPRS
General packet radio service (GPRS) is a packet oriented mobile data service on the 2G and 3G cellular communication systems global system for mobile communications (GSM). The service is available to users in over 200 countries. GPRS was originally standardized by European Telecommunications Standards Institute (ETSI) in response to the earlier CDPD and imode packet-switched cellular technologies. It is now maintained by the 3rd Generation Partner. Dept of CS&E, Vemana Institute of Technology Page 25
2011-2012
GPRS usage charging is based on volume of data, either as part of a bundle or on a payas-you-use basis. An example of a bundle is up to 5 GB per month for a fixed fee. Usage above the bundle cap is either charged for per megabyte or disallowed. The pay as you use charging is typically per megabyte of traffic. This contrasts with circuit switching data, which is typically billed per minute of connection time, regardless of whether or not the user transfers data during that period.
GPRS is a best-effort service, implying variable throughput and latency that depend on the number of other users sharing the service concurrently, as opposed to circuit switching, where a certain quality of service (QoS) is guaranteed during the connection. In 2G systems, GPRS provides data rates of 56-114 kbit/second. 2G cellular technology combined with GPRS is sometimes described as 2.5G, that is, a technology between the second (2G) and third (3G) generations of mobile telephony. It provides moderate-speed data transfer, by using unused time division multiple access (TDMA) channels in, for example, the GSM system. GPRS is integrated into GSM Release 97 and newer releases.
Page 26
2011-2012
Language Enhancement
Microsoft Visual Basic, Microsoft C++, and Microsoft Jscript have all been updated to meet your development needs. Additionally, a new language, Microsoft C#, has been introduced. These languages leverage the functionality .NET framework, which provides access to key technologies that simplify the development of ASP web applications and XML web services.
Visual Basic
Visual Basic has been updated to include too many new and improved language features that make it powerful object-oriented programming language. These features include inheritance, interfaces and overloading, among others. Visual Basic also now supports structured exception handling and custom attributes. In addition, Visual Basic supports multithreading. Multithreading is the ability to individual task to separate processing threads. For more Dept of CS&E, Vemana Institute of Technology Page 27
2011-2012
information, see whats new in the visual language and introduction to objects in visual basic.
C#
Visual C#, pronounced C sharp, is a new object-oriented programming is just some of the enhancements made to the C++, providing a simple and type-safe language for developing application. For more information, see visual C## language.
C++
Managed extensions for C++ and attributed programming are just some of the enhancement made to the c++ language. Managed extensions simplify the task of migrating existing C++ applications to the new .NET framework. Attributes are designed to provide a quick and efficient method to simplify COM programming with visual C++. For more information, see extensions for C++ programming and attributed programming.
JScript
Jscript has been updated to be a class-based, object-oriented scripting language that maintains full backwards compatibility with previous versions of jscript now provides classbased objects, typed variables, true complied code and cross-language support through Common Language Specifications (CLS) compliance. The primary role of jscript is development of websites with ASP .NET and customization of application with script for the .NET framework. For more information, see whats new in jscript .NET.
Web Forms
Web Forms are an ASP.NET technology that uses to create programmable web pages. Web Forms render themselves as browser-compatible HTML and script, which allows any browser on any platform to view the pages. Using web forms you create web pages by dragging Dept of CS&E, Vemana Institute of Technology Page 28
2011-2012
and dropping controls on to the designer and then adding code, similar to the way that you create visual basic forms. For more information, see introduction to web form pages.
Windows Forms
Windows Forms is the new platform for Microsoft windows application development, based on the .NET framework. This framework provides a clear, object-oriented, extensible set of classes that enables you to develop a rich windows application. Additionally, windows forms can act as the local user interface in a multi-tier distributed solution. For more information see, introduction to windows forms.
XML Support
Extensible Markup Language (XML) provides a method for describing structured data. XML is a subset of SGML that is optimized for delivery over the web. The World Wide Web consortium (W3C) defines XML standards so that structured data will be uniform and independent of applications. Visual Studio .NET fully supports XML providing the XML designer to make it easier to edit XML and create XML schemas. For more information, see XML schemas and Data and XML Designer.
Page 29
2011-2012
Page 30
2011-2012
ASP .NET
ASP.NET builds on the programming classes of the .NET Framework, providing a web application model with a set of controls and infrastructure that make it simple to build ASP web application. ASP.NET includes a set of controls that encapsulate common HTML user interface as HTML to the browser. On the server, the controls expose an object-oriented programming model that brings the richness of object-oriented programming to the web developer. ASP.NET also provides infrastructure services, such as session state management and process recycling that further reduce the amount of code a developer must write and increase application reliability. In addition, ASP.NET uses these same concepts to enable developers to deliver software as a service. Using XML web services features, ASP.NET developers can write their business logic and use the ASP.Net infrastructure to deliver that service via SOAP. For more information see SOAP community links.
Enterprise Templates
Visual Studio.NET provides several project templates that you can use to get a jump start on developing distributed applications. Enterprise templates define the initial structure of a distributed application and also provide architectural and technological guidance for application design. In addition to pr-defined enterprise templates, you can also create custom templates that can be used by developers in team environment. For more information, see creating an Enterprise applications initial structure and advantages of using enterprise Templates to create Distributed Application.
2011-2012
development tool such as Visual C#, Visual Basic, and Visual C++, as well as a number of additional technologies to simplify team-based design, development and deployment of your solutions.Visual Studio supports the .NET framework, which provides a common language runtime and unified programming classes; ASP.NET uses these components to create ASP web applications and XML web services. Also included is the MSDN library, which contains all the documentation see overview of the .NET framework, and programming the web with XML web services.
Application Templates
Visual studio provides application architectural guidance through templates.
Enterprise Templates
Visual Studio.NET provides several templates that software architects can use to reduce the complexity and cost of developing distributed applications. Using Enterprise Dept of CS&E, Vemana Institute of Technology Page 32
2011-2012
Templates, you can define the initial structure of a distributed application and provide architectural and technological guidance to development teams. In addition to pre-defined Enterprise Templates, you can also create custom templates. For more information, you can also create custom templates. For more information, see Enterprise Templates for distributed Applications and Advantages of using Enterprise Templates to create Distributed Applications.
MVC Architecture
The goal of the MVC design pattern is to separate the application object (model) from the way it is represented to the user (view) from the way in which the user controls it (controller). The Model object knows about all the data that need to be displayed. It also knows about all the operations that can be applied to transform that object. However, it knows nothing whatever about the Web UI, the manner in which the data are to be displayed, nor the Web UI actions that are used to manipulate data. Data are accessed and manipulated through methods that are independent of Web UI.
The model represents enterprise data and the business rules that govern access to and updates of this data. Often the model serves as a software approximation to a real-world process, so simple real-world modeling techniques apply when defining the model. The View object refers to the model. It uses the query methods of the model to obtain data from the model and then displays the information. A view renders the contents of a model. It accesses enterprise data through the model and specifies how that data should be presented. It is the view's responsibility to maintain consistency in its presentation when the model changes. The Controller object knows about the physical means by which users manipulate data within the model. A controller translates interactions with the view into actions to be performed by the model. In this, user interactions could be button clicks or Open applications which appear as GET and POST HTTP requests. The actions performed by the model include activating business processes or changing the state of the model. Based on the user interactions and the outcome of the model actions, the controller responds by selecting an appropriate view.In Web user interfaces, views and Dept of CS&E, Vemana Institute of Technology Page 33
2011-2012
controllers often work very closely together. For example, a controller is responsible for updating a particular parameter in the model that is then displayed by a view. In some cases a single object may function as both a controller and a view with only one model, however a particular model can have many view-controller pairs. Advantages: The MVC architecture has the following benefits: 1) Multiple views using the same model: The separation of model and view allows multiple views to use the same enterprise model. Consequently, an enterprise application's model components are easier to implement, test, and maintain, since all access to the model goes through these components. 2) Easier support for new types of clients: To support a new type of client, you simply write a view and controller for it and wire them into the existing enterprise model. 3) Clarity of design: By glancing at the model's public method list, it should be easy to understand how to control the model's behavior. When designing the application, this trait makes the entire program easier to implement and maintain. 4) Efficient modularity: of the design allows any of the components to be swapped in and out as the user or programmer desires - even the model! Changes to one aspect of the program aren't coupled to other aspects, eliminating many nasty debugging situations. Also, development of the various components can progress in parallel, once the interface between the components is clearly defined. 5) Ease of growth: Controllers and views can grow as the model grows; and older versions of the views and controllers can still be used as long as a common interface is maintained. 6) Distributable: With a couple of proxies one can easily distribute any MVC application by only altering the startup method of the application.
Page 34
2011-2012
Page 35
2011-2012
2011-2012
x86, MIPS R4000, and Toshiba SH4 instruction sets. One unique aspect of .NET executable files is that the executable files are written for an instruction set not tied to a specific CPU family. This is the IL instruction set, which stands for 'Intermediate Language.' It has other names, including Microsoft Intermediate Language (MSIL), and Common Intermediate Language (CIL), the name used in the submission as an ECMA standard.
2011-2012
originates in manufacturing to refer to last minute delivery of required parts. With IL, JITting is done on a per method basis on both the desktop and the Compact Framework. By having this fine level of granularity, only the specific methods which are called get converted; methods that never get called are never JITted, saving both processing time and storage space. Once a method has been converted from IL to native instructions, the native code version of the method stays in RAM. The collection of JITted native code is referred to as the native image cache. This means that the cost incurred for the JITting can get amortized for methods which are called often. Native methods are not locked into memory, but rather the memory they occupy is subject to reclamation by the garbage collector just like unreachable data objects.
2011-2012
can be allocated and then abandoned and it gets reclaimed. No explicit operation is needed to free such objects. In some cases, however, you may want to explicitly free an object because it contains one or more references to a resource which does, in fact, require some cleanup. This might be a file that needs to be closed, a network connection that needs to be logged out, or an unmanaged library that needs to free some Win32 objects. In such cases, you implement a pair of cleanup methods to handle automatic (Finalize) cleanup, or manual (Dispose) cleanup.
The word 'common,' which appears often in .NET terms, has many meanings including 'plain' and 'ordinary.' That is not what 'common' means in .NET. A better word might be 'standard,' because these elements define a set of standards that allow a wide range of programming languages to interoperate with each other. The Common Language Specification (CLS), in particular, refers to a set of standards that were created to promote interoperability between different programming languages. This is very important architectural feature of the .NET initiative. It opens up the possibility that existing code libraries can more easily be made available as managed code libraries. It also allows programmers a wider range of programming languages instead of restricting them to just a few. In the world before .NET, the Win32 API was primarily available to C and C++ programs. Visual Basic programs were second-class citizens, because aspects of Win32 and COM were difficult if not impossible to access from Visual Basic. As Microsoft shipped new versions of VB, the gap got narrower and narrower between what a C programmer and a VB programmer could do, but it never really went away entirely in unmanaged code. In the world of managed code programming, however, that gap essentially disappears.
In .NET, because it supports the Common Language Specification, Visual Basic .NET is a first-class citizen. .NET both languages use the same runtime (the Common Language Runtime), and both support a common set of types (as defined in the Common Type System). A library written in VB .NET can be called from a C# program, and vice-versa. The common standards used by .NET-compatible languages are what enable this interoperability. An even larger set of programming languages is available on the desktop .NET Framework. The desktop Dept of CS&E, Vemana Institute of Technology Page 39
2011-2012
supports C# and VB .NET, just like the Compact Framework. There is, in addition, a .NETcompatible version of the C++ compiler that supports a .NET-compatible mode known as "Managed C++." At the initial .NET announcement, there was a demonstration of a .NETcompatible web site that was written in COBOL. Other .NET languages that we know of include: Dyalog APL, Eiffel, Fortran (Salford FTN95), J++, JScript .NET, Mercury, Mondrian, Oberon, Pascal, Perl, Python, SmallTalk, and Standard ML.
Page 40
2011-2012
CHAPTER 3 REQUIREMENTS
In this chapter we define all the requirements of this project and at the end of this chapter scope of this project are explained.
1. Client is on android platform using android devlopment kit integrated with eclipse 3.5 or higher sun jdk 5 or higher, written in java language. 2. Server side is written in dotnet language using visual studio 2008 integrated with sql server 2000. Visual studio is used to create homepage containing login for admin and user. 3. SQL server contains the queries and table for maintaing database 4. Complaints are categorywise and in chronological order with a unique 36 charachter complaint ID & mobile number. 5. Description of complaint is limited to 160 characters. 6. If user fail to fill any of the required specification on client, error is genrated. 7. For augmenting position GPS of phone is used. For linking GPS to project we need to obtain the secret key from Code.google.com by regestring ourself with MAP ADT. 8. This gives us facility to get exact loacation by calculating longitude and latitude.
9. This numeric values of GPS are sent to server using REST service. On Server,google Map is drawn and position is displayed using flags. Dept of CS&E, Vemana Institute of Technology Page 41
2011-2012
10. To avoid duplicate complaints and redundancy minimum 25 meter difference is maintained and complaint must be made in 5 minutes gap. 11. Here image manipulation is important as we use different megapixel camera devices which may create error while sending and require high bandwidth sometime. Application crop and convert the image in base 64 format. 12. Members of client side or third party can see details on website but cannot modify only add comments. 13. Members of category admin can only update the status but cannot delete the entry. 14. Memebers of administrators group can delete entry on database. 15. The server domain is bought from the nettgritty domain provider, which has also provide us with response SMS sent to the client.
3.1.2.1 Usability
1. The application should be very responsive and should not hang at any point of time. 2. Display area should be used efficiently. As android is open platform and there are numerous devices from different vendors having different display sizes and resolutions the application should be adaptable to different screen resolutions. 3. Input gestures like single tap, double tab should be processed seamlessly without any delay. 4. The application should never crash and create a bad user experience. 5. The application should be able to run smoothly across devices irrespective of the device hardware capabilities. 6. The UI design should follow Android UI guidelines and Android paradigm.
Page 42
2011-2012
Reliability:
The client application can work on android phone its compatible to all versions of it and with minimum hardware requirements. Client requires 64kb/s 2G databandwidth for sending the data. Failure rate are possible in augumenting the longitude and latitude if GPS is not conneted.
Usability:
Complaint can be written in natural language. Symbol with government body name given as option. Can take snap directly no need to turn on camera seprately.
Security:
Autentication: for everytime a complaint is requested user mobile number is sent and displayed so no fake complaint is possible. Maintainability: APIs are open so modification can be done on client as well on server part. Changing the sim card or changing the device wont create ambiguity as phone send only own user number.
Portability:
Portability possible for android phone but not for any os phone like symbian, bada or meego as their APIs are not open to third party.
Page 43
2011-2012
CHAPTER 4 ANALYSIS
4.1 Existing System
The chief modes of registering complaint is (a)A visit to the ward office person in charge listens to the complaint and asks for some personal details and put it across into an electronic form for other departments (b)Through a contact center over a telephone - where the complaint is registered by an call center agent by typing the complaint into the system and more recently (c) Through a web portal.
User can take a snap shot of the activity i.e.: water leakage. The application will augment the current position of picture taken. The priority of the complaint would be raised if the numbers of the are considerably more in an area.. The map of city is drawn; here it is colored with red, yellow or green flag respectively ward wise, depending upon the no. of complaints received in and area. Statistical information is maintained such as the no. of complaints received ward wise, no. of them solved. The pictures are also displayed to the general public on a discussion forum where they can post their comments.
Page 44
2011-2012
CHAPTER 5 DESIGN
Page 45
2011-2012
5.2 Flowchart
START
Display Complaint Activity by passing category name which user has selected [Take picture, Remark, Register ]
Get Handle of Location Manager Find out Location Providers available on device
Y Use Network Provider If Network Provider avaialable? N Y Use GPS Provider If GPS Provider avaialable?
Page 46
2011-2012
Request Location Manager about the location updates for every 5 mins for minimum distance as 25m.
Get the users Mobile Number
If Take Picture Button Clicked Y 1) Device camera is accessed to take the picture 2) encode the Image(Base64 Format) Type the Remark
N Display
toast Once the Register Button is clicked, Display dialog with options 1) High 2) low 3) medium priorities
Get latitude and longitude, date & time Send the following Data to the server via HTTP 1)Mobile number 2)Lat & Long 3)Date & time 4)Category 5)Priority 6)Image
Page 47
2011-2012
Page 48
2011-2012
Page 49
2011-2012
ComplaintInfo
CompTags
Page 50
2011-2012
SmartAdmin
Smartcategory
SmartUploads
Smartusers
Dept of CS&E, Vemana Institute of Technology Page 51
2011-2012
Page 52
2011-2012
CHAPTER 6 IMPLEMENTATION
6.1 SYSTEM IMPLEMENTATION
Implementation is the stage of the project where the theoretical design is turned into a working system. At this stage the main work load, the greatest upheaval and the major impact on the existing system shifts to the user department. If the implementation is not carefully planned an controlled it can cause chaos and confusion. Implementation includes all those activities that take place to convert from the old system to the new one. The new system may be totally new, replacing an existing manual or automated system or it may be a major modification to an existing system. Proper implementation is essential to provide a reliable system to meet the organization requirements. Successful implementation may not guarantee improvement in the organization using the new system, but improper installation will prevent it. The process of putting the developed system in actual use is called system implementation. This includes all those activities that take place to convert from the old system to the new system. The system can be implemented only after thorough testing is done and if it is found to be working according to the specifications. The system personnel check the feasibility of the system.
The implementation stage involves following tasks. Careful planning. Investigation of system and constraints. Design of methods to achieve the changeover. Training of the staff in the changeover phase. Evaluation of the changeover method.
The most crucial stage is achieving a new successful system and giving confidence on the new system for the user that it will work efficiently and effectively. It involves careful planning, Dept of CS&E, Vemana Institute of Technology Page 53
2011-2012
investigation of the current system and its constraints on implementation, design of methods to achieve the changeover. The more complex the system being implemented, the more involved will be the system analysis an the design effort required just for implementation. The system implementation has three main aspects. They are education and training, system testing and changeover.
Implementation Procedures
Implementation of software refers to the final installation of the package in its real environment, to the satisfaction of the intended users and the operation of the system. In many organizations some one who will not be operating it, will commission the software development project. The people who are not sure that the software is meant to make their job easier. In the initial stage, they doubt about the software but we have to ensure that the resistance does not build up as one has to make sure that The active user must be aware of the benefits of using the system Their confidence in the software is built up Proper guidance is imparted to the user so that he is comfortable in using the application.
Before going ahead and viewing the system, the user must know that for viewing the result, the server program should be running in the server. If the server object is not up running on the server, the actual processes wont take place.
User Training
To achieve the objectives and benefits expected from computer based system, it is essential for the people who will be involved to be confident of their role in the new system. As systems become more complex, the need for education an training is more and more important.
Education is complementary to training. It brings life to formal training by explaining the background to the resources for them. Education involves creating the right atmosphere and Dept of CS&E, Vemana Institute of Technology Page 54
2011-2012
motivating user staff. Education sections should encourage participation from all staff with protection for individuals for group criticism. Education should start will before any
development work to enable users to maintain or to regain the ability to participate in the development of their system.
Education information can make training more interesting and more understandable. The aim should always be to make individual feel that they can still make all important contributions, to explain how they participate in making system changes, and to show that the computer and computer staff do not operate in isolation, but are of the same organization.
After providing the necessary basic training on the computer awareness the users will have to be trained on the new application software. This will give the underlying philosophy of the use of the new system such as the screen flow, screen design, type of help on the screen, type of errors while entering the data the corresponding validation check at each entry and the ways to correct the data entered. It should then cover information needed by the specific user/groups to use the system or part of the system while imparting the training of the program on the application. This training may be different across different user groups and across different levels of hierarchy.
Operational Documentation
Once the implementation plan is decided, it is essential that the user of the system is made familiar and comfortable with the environment. Education involves right atmosphere & motivating the user. A documentation providing the whole operations of the system is being developed. The system is developed in such a way that the user can work with it in a well consistent way. The system is developed user friendly so that the user can work the system from the tips given in the application itself. Useful tips and guidance is given inside the application itself to help the user. Users have to be made aware that what can be achieved with the new system and how it increases the performance of the system. The user of the system should be Dept of CS&E, Vemana Institute of Technology Page 55
Smart Complaint Register for Govt Bodies given a general idea of the system before he uses the system.
2011-2012
System Maintenance
The maintenance phase of the software cycle is the time in which a Software product performs useful work. After a system is successfully implemented, it should be maintained in a proper manner. System maintenance is an important aspect in the software development life cycle. The need for system maintenance is for it to make adaptable to the changes in the system environment. There may be social, technical and other environmental changes, which affects a system, which is being implemented. Software product enhancements may involve providing new functional capabilities, improving user displays and mode of interaction, upgrading the performance characteristics of the system. So only through proper system maintenance procedures, the system can be adapted to cope up with these changes. Software maintenance is of course, far more than finding mistakes. We may define maintenance by describing four activities that are undertaken to after a program is released for use. The first maintenance activity occurs because it is unreasonable to assume that software testing will uncover all latent errors in a large software system. During the use of any large program, errors will occur and be reported to the developer. The process that includes the diagnosis and correction of one or more errors is called corrective maintenance. The second activity that contributes to a definition of maintenance occurs because of the rapid change that is encountered in every aspect of computing. Therefore, adaptive maintenance- an activity that modifies software to properly interfere with a changing environment is both necessary and commonplace. The third activity that may be applied to a definition of maintenance occurs when a software package is successful. As the software is used, recommendations for new capabilities, modifications to existing functions, and general enhancements are received from users. To satisfy requests in this category, perfective maintenance is performed. This activity accounts for the majority of all effort expended on software maintenance.
Page 56
2011-2012
CHAPTER 7 TESTING
7.1 SYSTEM TESTING
Taking various kinds of data plays a vital role in system testing. After preparing the test data, the system under steady is tested using the test data. While testing errors are again uncovered and corrected by using the above steps and corrections are also noted for future use. The system has been verified and validated by running the test data and live data. First the system is tested with some sample test data that are generated with knowledge of the possible range of values that are required to hold by the fields the system runs successfully for the given test data and for the live data.
Types of Testing
Unit Testing
Here we test each module individually and integrate the overall system. Unit testing focuses verification efforts even in the smallest unit of software design in each module. This is also known as module testing.. The modules of the system are tested separately. This testing is carried out in the programming style itself. In this testing each module is focused to work satisfactorily as regard to expected output from the module there are some validation checks for the fields.
Integration testing
Data can be lost across an interface, one module can have an adverse effect on the other sub functions, when combined may not produce the desired functions. Integrated testing is the systematic testing to uncover the errors with an interface. This testing is done with simple data and developed system has run successfully with this simple data. The need for integrated system is to find the overall system performance. Dept of CS&E, Vemana Institute of Technology Page 57
2011-2012
Modules are integrated by moving downward through the control hierarchy, beginning with the main program module.
2. Bottom up Integration
Bottom up Integration is implemented with the following steps: Low-level modules are combined into clusters into clusters that perform a specific Software sub-function. A driver (i.e.,) the control program for testing is written to coordinate test case input and output. The cluster is tested. Drivers are removed and clusters are combined moving upward in the program structure.
Validation testing
At the culmination of black box testing, software is completely assembled s a package. Interfacing errors have been uncovered and the correct and final series of tests, i.e., validation tests begins. Validation test is defined with a simple definition that validation succeeds when the software function in a manner that can be reasonably accepted by the customer.
Output Testing
After performing validation testing, the next step is output testing of the proposed system. Since the system cannot be useful if it does not produce the required output. Asking the user about the format in which the system s required tests the output displayed or generated by the system under consideration. Here the output format is considered in two ways one is on screen format and the other one is a printed format the output format on the screen is found to be Dept of CS&E, Vemana Institute of Technology Page 58
Smart Complaint Register for Govt Bodies corrected as the format was designed in the system has according to the user needs.
2011-2012
Test data and Output: Taking various kind soft data plays a vital role in system testing. After preparing the test data system under study is tested using the test data. While testing, errors are again uncovered and corrected by using the above steps and corrections are also noted for future use. The system has been verified and validated by running test data and live data.
User acceptance testing of the system is the key factor for the success of any system. A system under consideration is tested for user acceptance by constantly keeping in touch with the prospective system at the time of development and making change whenever required. This is done with regard to the input screen design and output screen design.
Page 59
2011-2012
CHAPTER 8 CONCLUSION
8.1 Conclusion
In current system, complaint registrations for government bodies i.e.: BWSSB, KPTCL, etc are offline. The seriousness of the problem is often not known by offline means. Even reporting some of the unsocial activities to police department have ended up in imagination based the eye witness to draw a sketch of the accused. The application solves all these problems. It offers below services 1. User can take a snap shot of the particular activity i.e.: water leakage, power cable hanging around, tree fall, unsocial activity etc. 2. The application will augment the current position where the picture is taken. 3. The above augmented picture is sent to the concerned authority. 4. The priority of the complaint would be raised if the numbers of them are considerably more in an area. 5. The map of Bangalore is drawn; here it is colored with red, yellow or green flags respectively ward wise, depending upon the no. of complaints received in an area. 6. Statistical information is maintained such as the no. of complaints received ward wise, no. of them solved, a graph to provide The pictures are also displayed to the general public on a discussion forum, where they can post their comments.
Page 60
2011-2012
CHAPTER 9 SNAPSHOTS
Page 61
2011-2012
Page 62
2011-2012
Page 63
2011-2012
REFERENCES
1. http://developer.android.com/sdk/api_diff/9/changes/android.location.LocationMa nager.html
2. http://java.sun.com/javase/downloads/index.jsp
3. http://www.eclipse.org/downloads/Eclipse
4. http://www.google.com
5. http://msdn.microsoft.com/en-us/library/ms123401.aspx 6. The C# Complete Reference 2.0, Herbert Schildt, Fourth edition, Tata McGraw Hill publication.
Page 64
2011-2012
APPENDIX A: ACRONYMS
Bluetooth: It is a wireless networking protocol designed to replace cable network technology for devices within 30 feet. Like IEEE 802.11b, Bluetooth also operates in unlicensed 2.4GHz spectrum, but it only supports data rates up to 1 Mbps. CDPD: Cellular Digital Packet Data is a wireless standard providing two way data transmission at 19.2 kbps over existing cellular phone systems. CDMA: Code Division Multiple Access, also known as CDMA-ONE or IS-95 is a spread spectrum communication technology that allows many users to communicate simultaneously using the same frequency spectrum. Communication between users are differentiated by using a unique code for each user. This method allows more users to share the spectrum at the same time than alternative technologies. CDMA-2000: Sometimes also known as IS-136 and IMT-CDMA multicarrier (1X/3X) is an evolution of narrowband radio transmission technology known as CDMA-ONE (also called CDMA or IS-95), to third generation. 1X refers to the use of 1.25 Mhz channel while 3X refers to 5 Mhz channel. DAWN: Advanced technologies including smart antenna and flexible modulation are keys to optimize this wireless version of reconfigurable adhoc networks. DSSS: In Direct Sequence Spread Spectrum, the data stream to be transmitted is divided into small pieces, each of which allocated a frequency channel. Then the data signal is combined with a higher data rate bit sequence known as chipping code that divides the data according to a spreading ratio thus allowing a resistance from interference during transmission. EDGE: Enhanced Data rates for Global Evolution technology gives GSM and TDMA the capability to handle 3rd generation mobile phone services with speeds upto 384 kbps. Since it uses the TDMA infrastructure, a smooth transition from TDMA based systems such as GSM to EDGE is expected. FHSS: In Frequency Hopping Spread Spectrum a broad slice of bandwidth spectrum is divided into many possible broadcast frequencies to be used by the transmitted signal.
GPRS: General Packet Radio Service provides data rates upto 115 kbps for wireless Internet and Dept of CS&E, Vemana Institute of Technology Page 65
Smart Complaint Register for Govt Bodies other types of data communications using packet data services.
2011-2012
GSM: Global Systems for Mobile Communication is a world-wide standard for digital wireless mobile phone systems. The standard was oroginated by the European Conference of Postal and Telecommunications Administrations (CEPT) who was responsible for the creation of ETSI. Currently ETSI is responsible for the development of GSM standard. Mobile phones: Mobile communication systems that uses radio communication and conventional telephone switching to allow communication to and from mobile users. Photonic networks: A network of computers made up using photonic devices based on optics. The devices include photonic switches, gateways and routers. PSTN: Public Switched Telephone Network is a regular voice telephone network. Spread Spectrum: It is a form of wireless communication in which the frequency of the transmitted signal is deliberately varied over a wide range. This results in a higher bandwidth of the signal than the one without varied frequency. TDMA: Time Division Multiple Access is a technology for sharing a medium by several users by dividing into different time slots transmitting at the same frequency. UMTS: Universal Mobile Telecommunications System is the third generation mobile telephone standard in Europe that was proposed by ETSI. WAP: Wireless Application Protocol defines the use of TCP/IP and web browsing for mobile systems. WCDMA: Wideband CDMA is a technology for wideband digital radio communications of multimedia and other capacity demanding applications. It is adopted by ITU under the name IMT-2000 direct spread. WDM: Wavelength Division Multiplexing allows many independent signals to be transmitted simultaneously on one fiber, with each signal located at a different wavelength. Routing and detection of these signals require devices that are wavelength selective, allowing for the transmission, recovery, or routing of specific wavelengths in photonic networks. WWWW: A world wide wireless web is capable of supporting a comprehensive wireless based web application that includes full graphics and multimedia capability at beyond 4G speeds
Page 66