<commit_before>package com.healthlife.util;

public class SensorController {

	public SensorController() {
		// TODO ԶɵĹ캯
	}
	
}<commit_msg>add class sensor controller<commit_after>package com.healthlife.util;

import android.content.Context;
import android.hardware.Sensor;
import android.hardware.SensorManager;

public class SensorController {

	private SensorManager sensorManager;
	private Sensor linearAcc,rotationVct,gyroscope;
	
	public void initSensors(int type,Context context) {
		
	
		getSensorManager(context);	
		
		//get specific sensors counting on the sportsmode
		switch(type){
		
			case 0 : 	linearAcc = sensorManager.getDefaultSensor(Sensor.TYPE_LINEAR_ACCELERATION); break;
			
			case 1 :    rotationVct = sensorManager.getDefaultSensor(Sensor.TYPE_GAME_ROTATION_VECTOR); break;
			
			case 2 :	linearAcc = sensorManager.getDefaultSensor(Sensor.TYPE_LINEAR_ACCELERATION); 
						rotationVct = sensorManager.getDefaultSensor(Sensor.TYPE_GAME_ROTATION_VECTOR); 
						break;
			
			case 3 :	linearAcc = sensorManager.getDefaultSensor(Sensor.TYPE_LINEAR_ACCELERATION); break;
			
			default: System.out.println("unknown mode"); 
		}

	}

	public void record ()
	{
		
	}
	
	private void getSensorManager(Context ctx){
		sensorManager = (SensorManager)ctx.getSystemService(Context .SENSOR_SERVICE);
	}
	
	
}
{'fraction_non_alphanumeric': 0.08377358490566038, 'fraction_numerical': 0.0030188679245283017, 'mean_word_length': 4.666666666666667, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5316386', 'n_tokens_mistral': 470, 'n_tokens_neox': 425, 'n_words': 78}