Nativescript Application for Continuous Improvement of Software Engineer’S Skills
Total Page:16
File Type:pdf, Size:1020Kb
Masaryk University Faculty of Informatics NativeScript application for Continuous Improvement of Software Engineer’s skills Bachelor’s Thesis Lenka Šmitalová Brno, Spring 2017 Replace this page with a copy of the official signed thesis assignment anda copy of the Statement of an Author. Declaration Hereby I declare that this paper is my original authorial work, which I have worked out on my own. All sources, references, and literature used or excerpted during elaboration of this work are properly cited and listed in complete reference to the due source. Lenka Šmitalová Advisor: Mgr. Juraj Michálek i Acknowledgement I would like to thank my supervisor, Mgr. Juraj Michálek, for his time and helpful advises that he has offered me. Great thanks also goes to my friends and family for the great support they have always given me. iii Abstract The goal of this thesis is to design and implement mobile application supporting the continuous improvement of software engineer’s skills. The application is developed in NativeScript with the use of Angular2 and TypeScript. In order to create such an application, this thesis discusses the aspects of software engineer’s work as well as inspect the possibilities of motivating a person to improve his skills. Next, the term gamification is introduced and the possible uses of itin the application in order to increase motivation. Finally, the thesis describes the application design, the implementation and possible improvements for the future. iv Keywords gamification, NativeScript, mobile application, MongoDB, Loopback, StrongLoop, Angular2, TypeScript, Node.js v Contents 1 Introduction 1 2 Software engineer’s work analysis 3 2.1 System analysis ........................3 2.2 System design .........................4 2.3 System implementation and testing ..............4 2.4 System deployment and maintenance .............5 2.5 System evaluation .......................6 3 Motivation 7 3.1 Intrinsic motivation ......................7 3.2 Extrinsic motivation .....................8 4 Gamification 9 4.1 Game elements ........................9 4.2 Gamification usage ......................9 5 Technologies 11 5.1 NativeScript .......................... 11 5.2 Angular 2 with NativeScript ................. 12 5.3 Database ............................ 12 5.3.1 Firebase . 12 5.3.2 MongoDB . 13 5.4 Loopback framework ...................... 14 5.5 Node.js ............................ 14 5.6 Node Package Manager .................... 15 6 Application design 17 6.1 Use Case Diagram ...................... 17 6.2 Data models .......................... 18 6.3 Possible mini games ...................... 19 7 Implementation 23 7.1 Project structure ....................... 23 7.2 Application views ....................... 24 7.3 Memory consuption ...................... 26 vii 8 Conclusion 29 Bibliography 31 viii 1 Introduction In these days, many companies struggle with a problem of employees not improving their skills. After some time, they get too comfortable with their jobs and they tend to do things mechanically without really putting their minds and hearts in the job. Because of the speed of information technologies (IT) development, it is crucial that every developer keeps his skills up to date. However, when they are assigned to long-term projects when their daily job tends to be really similar, it is hard to motivate them to do so. The goal of my thesis is to create a mobile application that will mo- tivate and guide software engineers through the process of improving their skills in a longer period of time. The application is developed in NativeScript, a tool for building cross-platform mobile applications, using TypeScript and Angular 2. The introduction is followed by the software engineer’s work analy- sis. I present a basic job description, concrete aspects of work that need to be performed in order to fulfil their job description and identify those aspects, that could be improved with an application supporting the refinement of the skills. The third chapter defines the concept of motivation and introduces two different types of motivation. For each type, I introduce thefac- tors that can either enhance motivation or, on the contrary, diminish motivation. The fourth chapter introduces the term gamification. It suggests several ideas that can be used in application design in order to help increase one’s motivation. The fifth chapter describes the technologies I used for application development. The sixth chapter is focused on application design. The view of the system is presented by the use case diagram, where I identify functions of the system and how different types of roles within the system interacts with them. I also introduce the proposal of models stored in the database. The seventh chapter is concentrated on the implementation of the application. It describes the project structure as well as the views of the 1 1. Introduction final application. I also discuss main memory consumptions problems for each platform. In the conclusion, I discuss the final results as well as the potential improvements of the application in the future development. 2 2 Software engineer’s work analysis Behind each computer system is at least one software engineer that is involved in its creation. The basic job description of a software engineer is to apply principles of software engineering to the process of the software development, which has several phases. In following sections of this chapter, I describe selected phases of this process and identify those aspects of each phase, which could be improved by providing the application which supports learning new skills. My approach of the subject in this chapter is inspired by the book Systems Analysis and Design Methods 5e (Whitten; Bentley; Dittman [1], 2000) 2.1 System analysis The very first step in software development is to explore the system proposal. Software engineers must thoroughly determine whether creating a new system or improve an existing one is the best option. When creating a system proposal, they must consider and analyse several things: ∙ Identify problems and opportunities, negotiate the scope of the project and assess its worth. ∙ Analyze problems and opportunities, analyse system processes and establish system improvement objectives. ∙ Define, analyse and prioritise system and software require- ments. ∙ Identify user needs. In order to accomplish the most reasonable result, the possible solu- tions must be identified, analysed, and compared. The best solution is then recommended to the management which has to approve it before software engineers can start working on the detailed system design. 3 2. Software engineer’s work analysis 2.2 System design When designing an application, software engineers have to research technical criteria and options as well as consider requirements and ideas proposed by a client. They need to find a reasonable compromise between feasible proposals and the customer vision. In this phase of software development, software engineers have to design the application architecture, the system database, system and user interfaces. The application architecture is mainly concerned with the selection of components, their interactions, and the constraints on those that are necessary to provide a framework in which to satisfy the requirements and serve as a basis for the design[2]. In the system database design, a detailed model of a database, or databases if more than one is required, should be produced. It should contain all the information necessary to create the database, which means an engineer must determine the data to be stored and define the relationships between different data elements. When designing the system interface, one should identify following inputs and outputs: ∙ inputs from and outputs to other systems, ∙ highly automated inputs and outputs, ∙ inputs from and outputs to external databases. For more information about identifying system interfaces see Sys- tems Analysis and Design in a Changing World (Satzinger; Jackson; Burd [3], 2011)In user interface design, one need to specify the types of consumers using the system and what human-computer interaction will be necessary. 2.3 System implementation and testing After designing the system, the realisation of the proposal can finally begin. During the system implementation, the product is built accord- ing to the proposal defined in the previous phase. This stage includes following steps: ∙ building and testing the databases, 4 2. Software engineer’s work analysis ∙ writing the source code in the selected programming language and link it with the database, ∙ detailed testing. When building databases, an engineer must choose the appropriate type of database according to data necessary for storing. For exam- ple, this may be a relational database, an object-oriented database, a document-oriented database, etc. The process of writing the source code of the project is the main one where the application with the support of continuous improvement can help upgrade the skills of the software engineer. Written code should be efficient, well documented and with proper logging, espe- cially if there are more engineers working on the project. An efficient code should be understandable, bug-free, without code repetition, and well structured. A well-documented code is easier to understand and combined with good logging can help find and fix problems, if any occurred, much faster. The process of testing the system is an important part of system implementation. It can be accelerated with