• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2014 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 
18 package com.android.camera.stats;
19 
20 import android.content.Context;
21 import android.graphics.Rect;
22 
23 import com.android.camera.exif.ExifInterface;
24 import com.android.camera.ui.TouchCoordinate;
25 
26 import java.util.HashMap;
27 import java.util.List;
28 
29 public class UsageStatistics {
30     public static final long VIEW_TIMEOUT_MILLIS = 0;
31     public static final int NONE = -1;
32 
33     private static UsageStatistics sInstance;
34 
instance()35     public static UsageStatistics instance() {
36         if (sInstance == null) {
37             sInstance = new UsageStatistics();
38         }
39         return sInstance;
40     }
41 
initialize(Context context)42     public void initialize(Context context) {
43     }
44 
mediaInteraction(String ref, int interactionType, int cause, float age)45     public void mediaInteraction(String ref, int interactionType, int cause, float age) {
46     }
47 
mediaView(String ref, long modifiedMillis, float zoom)48     public void mediaView(String ref, long modifiedMillis, float zoom) {
49     }
50 
foregrounded(int source, int mode, boolean isKeyguardLocked, boolean isKeyguardSecure, boolean startupOnCreate, long controlTime)51     public void foregrounded(int source, int mode, boolean isKeyguardLocked,
52                              boolean isKeyguardSecure, boolean startupOnCreate,
53                              long controlTime) {
54     }
55 
backgrounded()56     public void backgrounded() {
57     }
58 
cameraFrameDrop(double deltaMs, double previousDeltaMs)59     public void cameraFrameDrop(double deltaMs, double previousDeltaMs) {
60     }
61 
jankDetectionEnabled()62     public void jankDetectionEnabled() {
63     }
64 
storageWarning(long storageSpace)65     public void storageWarning(long storageSpace) {
66     }
67 
videoCaptureDoneEvent(String ref, long durationMsec, boolean front, float zoom, int width, int height, long size, String flashSetting, boolean gridLinesOn)68     public void videoCaptureDoneEvent(String ref, long durationMsec, boolean front,
69                                       float zoom, int width, int height, long size,
70                                       String flashSetting, boolean gridLinesOn) {
71     }
72 
photoCaptureDoneEvent(int mode, String fileRef, ExifInterface exifRef, boolean front, boolean isHDR, float zoom, String flashSetting, boolean gridLinesOn, Float timerSeconds, Float processingTime, TouchCoordinate touch, Boolean volumeButtonShutter, List<Camera2FaceProxy> faces, Float lensDistance, Rect activeSensorSize )73     public void photoCaptureDoneEvent(int mode, String fileRef, ExifInterface exifRef,
74                                       boolean front, boolean isHDR, float zoom,
75                                       String flashSetting, boolean gridLinesOn,
76                                       Float timerSeconds, Float processingTime,
77                                       TouchCoordinate touch, Boolean volumeButtonShutter,
78                                       List<Camera2FaceProxy> faces, Float lensDistance,
79                                       Rect activeSensorSize
80     ) {
81     }
82 
cameraFailure(int cause, String info, int agentAction, int agentState)83     public void cameraFailure(int cause, String info, int agentAction, int agentState) {
84     }
85 
changeScreen(int newScreen, Integer interactionCause)86     public void changeScreen(int newScreen, Integer interactionCause) {
87     }
88 
controlUsed(int control)89     public void controlUsed(int control) {
90     }
91 
tapToFocus(TouchCoordinate touch, Float duration)92     public void tapToFocus(TouchCoordinate touch, Float duration) {
93     }
94 
reportMemoryConsumed(HashMap memoryData, String reportType)95     public void reportMemoryConsumed(HashMap memoryData, String reportType) {
96     }
97 }
98