koios.server
This package contains the main class containing the application entry point
KoiosServer.java
This file provides the spring boot entry point to initialize the server

koios.server.controllers
This package contains all the controllers that interact with the repositories which query sql data.
•	FitBitController.java
o	The FitBitController class provides an API end point to calculate the time awake of an individual user
•	QuestionController.java
o	The QuestionController class provides an API end point to retrieve the list of questions pertaining to a survey and the different versions of the survey questions
•	QuestionResponseController.java
o	The QuestionResponseController class provides an API end point to get the question response list and response count from a user response in a survey
•	StudyController.java
o	The StudyController class provides an API end point to get the study list or specific study
•	UsersController
o	The UsersController class provides an API end point to authenticate the login request from a user
koios.server.model
This package contains all the models pertaining to the server
•	FitbitHistory.java
o	The FitbitHistory class provides a model representing a fitbit history report within the database
•	Question.java
o	The Question class provides a model representing a question entry within the database
•	QuestionKey.java
o	The QuestionKey class provides a serializable implementation of a question entry
•	QuestionResponse
o	The QuestionResponse class provides a model representing a response entry within a survey in the database
•	QuestionResponseKey
o	The QuestionResponseKey class provides a serializable implementation of a response entry within a survey
•	Study.java
o	The Study class provides a model representing a study entry within the database
•	Survey.java
o	The Survey class provides a model representing a survey entry within the database
•	Surveykey.java
o	The SurveyKey class provides a serializable implementation of a Survey entry within the database
•	User.java
o	The User class provides a model representing a user entry within the database
koios.server.repository
This package contains all the repositories that handle access to database queries
•	FitbitRepository.java
o	The FitbitRepository provides query functionality to the database finding the data by its id
•	QuestionResponseRepository
o	The QuestionResponseRepository provides query functionality to the database finding the response list, total responses and maximum version
•	QuestionsRepository.java
o	The QuestionsRepository provides query functionality to the database finding the questions by id and survey questions by the survey id
•	StudyRepository.java
o	The StudyRepository provides query functionality tpo the database finding the data by id
•	SurveyRepository.java
o	The SurveyRepository gets the survey list by the study id
•	UserRepository.java
o	The UserRepository finds data by the user’s email

Koios web: Front end code

Src/
Contains the main react files and application entry-point
•	App.js
o	Contains the application entry-point
Src/layout
Contains reuseable layouts throughout the react web application
•	Navbar.js
o	Contains the react component for the site navigation
Src/pages
Contains pages that can be navigated through the application
•	Login.js
o	Contains the login page for the website
Src/pages/graphs
Contains all the graph pages pertaining to the web application
•	BarChartGraph.js
o	Contains the bar chart react component
Src/pages/study
Contains the study pages pertaining to the web application
•	Study.js
o	The individual description page of the website
•	StudyList.js
o	The page containing a list of available studies
Src/pages/surveys
Contains all the survey pages pertaining to the web application
•	SurveyList.js
o	The page containing all the surveys pertaining to the web application
Src/pages/surveys/questions
Contains all the question pages pertaining to the web application
•	QuestionList.js
o	The page containing a list of all questions in a survey
Src/sass
Contains all the sass files used throughout the web application
•	Main.scss
o	Contains all the sass imports used as the main compilation file to transpile sass to CSS
Src/sass/base
Contains all the base sass files used throughout the web application
•	_base.scss
o	Contains the base HTML design modifications
•	_colors.scss
o	Contains global values used for reusable colors
•	_typography.scss
o	Contains all the text styling used throughout the web application
Src/sass/pages
Contains all the reactcomponent styling and pages
•	_login.scss
o	Contains all the login page styling
•	_navbar.scss
o	Contains all the navigation bar component styling
•	_surveys.scss
o	Contains all the survey page styling

Mobile Application Directory Structure: 

.vscode

android: Contains andriod mobile code.
 -app
  -src
   -debug
    -AndroidManifest.xml
   -main
    -kotlin
     -com
      -mosaic
       -koios_log
        -MainActivity.kt
    -res
     -drawable
     -drawable-hdpi
     -drawable-hdpi-v11
     -drawable-mdpi
     -drawable-mdpi-v11
     -drawable-xhdpi
     -drawable-xhdpi-v11
     -drawable-xxhdpi
     -drawable-xxhdpi-v11
     -drawable-xxxhdpi
     -drawable-xxxhdpi-v11
     -mipmap-hdpi
     -mipmap-mdpi
     -mipmap-xhdpi
     -mipmap-xxhdpi
     -mipmap-xxxhdpi
     -values
    -AndroidManifest.xml
   -profile
  -build.gradle
  -google-services.json
 -gradle
 -.gitnore
 -build.gradle
 -gradle.properties
 -settings.gradle

assets:contains all images used in the mobile app
 -images

ios: Contains IOS mobile code.
 -Flutter:
  -AppFrameworkInfo.plist
  -Debug.xcconfig
  -Release.xcconfig
 -Runner:
  -Assets.xcassets
   -Applcon.appiconset
   -LaunchImage.imageset
   -Contents.json
  -Base.lproj
   -LaunchScreen.storyboard
   -Main.storyboard
  -AppDelegate.swift
  -Info.plist
  -Runner.entitlements
  -Runner-bridging-header.h
 -Runner.xcodeproj
 -Runner.xcworkspace
 -gitignore
 -GoogleService-Info.plist
 -Podfile
 -Podfile.lock

lib: contains all mobile code.
 -src
  -domain
   -study.dart
   -survey.dart
  -helpful_widgets
   -colors.dart
   -drawer.dart
   -failure_dialogue.dart
   -label_summary.dart
   -label_task.dart
   -success_dialog.dart
   -survey.dart
   -survey_list_item.dart
  -pages
   -authentication_page.dart
   -camera_page.dart
   -demographics.dart
   -directory.dart
   -email_login.dart
   -email_signup.dart
   -fitbit_integration_page.dart
   -graph.dart
   -graph1.dart
   -graph2.dart
   -graph3.dart
   -grid_dashboard.dart
   -invite_code_signup_page.dart
   -label_summary_list.dart
   -labeling_page.dart
   -main_tab_view_page.dart
   -notification_permission_needed_page.dart
   -single_study_survey_list.dart
   -studies_list.dart
   -study_details.dart
   -survey_body.dart
   -surveys_list.dart
   -verify_email.dart
  -RestAPI
   -dto_mappers
    -study_dto_mapper.dart
    -survey_dto_mapper.dart
   -KoiosAPI.dart
   -KoiosAPI.g.dart
  -utils
   -Koios_user_info.dart
  -main.dart

web: files that run as web in the localhost.
 -icons
 -favicon.png
 -index.html
 -manifest.json
.gitgnore
.metadata
GoogleService-Info.plist
pubsec.lock



Database instructions: run mysql workbench and make a schema called koios, import database into koios and set a password (REMEMBER THE PASSWORD).

