Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 10e237e5 authored by Joe Onorato's avatar Joe Onorato Committed by Android (Google) Code Review
Browse files

Merge changes from topic 'incident_1'

* changes:
  First checkin of incident reporting.
  Add a native class to interact with DropBoxManager.
parents e298756b 1754d744
Loading
Loading
Loading
Loading
+39 −1
Original line number Original line Diff line number Diff line
@@ -38,7 +38,9 @@ ifneq ($(ANDROID_BUILD_EMBEDDED),true)
include $(CLEAR_VARS)
include $(CLEAR_VARS)


# FRAMEWORKS_BASE_SUBDIRS comes from build/core/pathmap.mk
# FRAMEWORKS_BASE_SUBDIRS comes from build/core/pathmap.mk
LOCAL_SRC_FILES := $(call find-other-java-files,$(FRAMEWORKS_BASE_SUBDIRS))
LOCAL_SRC_FILES := \
        $(call find-other-java-files,$(FRAMEWORKS_BASE_SUBDIRS)) \
        $(call all-proto-files-under, core/proto)


# EventLogTags files.
# EventLogTags files.
LOCAL_SRC_FILES += \
LOCAL_SRC_FILES += \
@@ -234,6 +236,9 @@ LOCAL_SRC_FILES += \
	core/java/android/os/IDeviceIdentifiersPolicyService.aidl \
	core/java/android/os/IDeviceIdentifiersPolicyService.aidl \
	core/java/android/os/IDeviceIdleController.aidl \
	core/java/android/os/IDeviceIdleController.aidl \
	core/java/android/os/IHardwarePropertiesManager.aidl \
	core/java/android/os/IHardwarePropertiesManager.aidl \
	core/java/android/os/IIncidentManager.aidl \
	core/java/android/os/IIncidentReportCompletedListener.aidl \
	core/java/android/os/IIncidentReportStatusListener.aidl \
	core/java/android/os/IMaintenanceActivityListener.aidl \
	core/java/android/os/IMaintenanceActivityListener.aidl \
	core/java/android/os/IMessenger.aidl \
	core/java/android/os/IMessenger.aidl \
	core/java/android/os/INetworkActivityListener.aidl \
	core/java/android/os/INetworkActivityListener.aidl \
@@ -528,6 +533,10 @@ LOCAL_STATIC_JAVA_LIBRARIES := \
    android.hardware.thermal@1.0-java-constants         \
    android.hardware.thermal@1.0-java-constants         \
    android.hardware.health@1.0-java-constants          \
    android.hardware.health@1.0-java-constants          \


LOCAL_PROTOC_OPTIMIZE_TYPE := stream
LOCAL_PROTOC_FLAGS := \
    -Iexternal/protobuf/src

LOCAL_MODULE := framework
LOCAL_MODULE := framework


LOCAL_JACK_FLAGS := --multi-dex native
LOCAL_JACK_FLAGS := --multi-dex native
@@ -1385,6 +1394,35 @@ endif


include $(BUILD_JAVA_LIBRARY)
include $(BUILD_JAVA_LIBRARY)


# ====  c++ proto host library  ==============================
include $(CLEAR_VARS)
LOCAL_MODULE := libplatformprotos
LOCAL_PROTOC_OPTIMIZE_TYPE := full
LOCAL_PROTOC_FLAGS := \
    --include_source_info \
    -Iexternal/protobuf/src
LOCAL_SRC_FILES := \
    $(call all-proto-files-under, core/proto) \
    $(call all-proto-files-under, libs/incident/proto)
LOCAL_C_INCLUDES := \
    $(call generated-sources-dir-for,STATIC_LIBRARIES,libplatformprotos,)/proto
LOCAL_EXPORT_C_INCLUDES := \
    $(call generated-sources-dir-for,STATIC_LIBRARIES,libplatformprotos,)/proto
include $(BUILD_HOST_SHARED_LIBRARY)


# ====  java proto host library  ==============================
include $(CLEAR_VARS)
LOCAL_MODULE := platformprotos
LOCAL_PROTOC_OPTIMIZE_TYPE := full
LOCAL_PROTOC_FLAGS := \
    -Iexternal/protobuf/src
LOCAL_SOURCE_FILES_ALL_GENERATED := true
LOCAL_SRC_FILES := \
    $(call all-proto-files-under, core/proto) \
    $(call all-proto-files-under, libs/incident/proto)
include $(BUILD_HOST_JAVA_LIBRARY)



# Include subdirectory makefiles
# Include subdirectory makefiles
# ============================================================
# ============================================================
+21 −0
Original line number Original line Diff line number Diff line
@@ -31734,6 +31734,27 @@ package android.os {
    method public abstract android.os.IBinder asBinder();
    method public abstract android.os.IBinder asBinder();
  }
  }
  public class IncidentManager {
    method public void reportIncident(android.os.IncidentReportArgs);
    method public void reportIncident(java.lang.String, byte[]);
  }
  public final class IncidentReportArgs implements android.os.Parcelable {
    ctor public IncidentReportArgs();
    ctor public IncidentReportArgs(android.os.Parcel);
    method public void addHeader(byte[]);
    method public void addSection(int);
    method public boolean containsSection(int);
    method public int describeContents();
    method public boolean isAll();
    method public static android.os.IncidentReportArgs parseSetting(java.lang.String) throws java.lang.IllegalArgumentException;
    method public void readFromParcel(android.os.Parcel);
    method public int sectionCount();
    method public void setAll(boolean);
    method public void writeToParcel(android.os.Parcel, int);
    field public static final android.os.Parcelable.Creator<android.os.IncidentReportArgs> CREATOR;
  }
  public final class LocaleList implements android.os.Parcelable {
  public final class LocaleList implements android.os.Parcelable {
    ctor public LocaleList(java.util.Locale...);
    ctor public LocaleList(java.util.Locale...);
    method public int describeContents();
    method public int describeContents();
+21 −0
Original line number Original line Diff line number Diff line
@@ -29307,6 +29307,27 @@ package android.os {
    method public abstract android.os.IBinder asBinder();
    method public abstract android.os.IBinder asBinder();
  }
  }
  public class IncidentManager {
    method public void reportIncident(android.os.IncidentReportArgs);
    method public void reportIncident(java.lang.String, byte[]);
  }
  public final class IncidentReportArgs implements android.os.Parcelable {
    ctor public IncidentReportArgs();
    ctor public IncidentReportArgs(android.os.Parcel);
    method public void addHeader(byte[]);
    method public void addSection(int);
    method public boolean containsSection(int);
    method public int describeContents();
    method public boolean isAll();
    method public static android.os.IncidentReportArgs parseSetting(java.lang.String) throws java.lang.IllegalArgumentException;
    method public void readFromParcel(android.os.Parcel);
    method public int sectionCount();
    method public void setAll(boolean);
    method public void writeToParcel(android.os.Parcel, int);
    field public static final android.os.Parcelable.Creator<android.os.IncidentReportArgs> CREATOR;
  }
  public final class LocaleList implements android.os.Parcelable {
  public final class LocaleList implements android.os.Parcelable {
    ctor public LocaleList(java.util.Locale...);
    ctor public LocaleList(java.util.Locale...);
    method public int describeContents();
    method public int describeContents();
+48 −0
Original line number Original line Diff line number Diff line
# Copyright (C) 2016 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)

LOCAL_SRC_FILES := \
        main.cpp

LOCAL_MODULE := incident

LOCAL_SHARED_LIBRARIES := \
        libbase \
        libbinder \
        libcutils \
        liblog \
        libutils \
        libincident

LOCAL_CFLAGS += \
        -Wall -Werror -Wno-missing-field-initializers -Wno-unused-variable -Wunused-parameter

LOCAL_MODULE_CLASS := EXECUTABLES
gen_src_dir := $(local-generated-sources-dir)

gen := $(gen_src_dir)/incident_sections.cpp
$(gen): $(HOST_OUT_EXECUTABLES)/incident-section-gen
$(gen): PRIVATE_CUSTOM_TOOL = \
    $(HOST_OUT_EXECUTABLES)/incident-section-gen > $@
$(gen): $(HOST_OUT_EXECUTABLES)/incident-section-gen
	$(transform-generated-source)
LOCAL_GENERATED_SOURCES += $(gen)

gen_src_dir:=
gen:=

include $(BUILD_EXECUTABLE)
+29 −0
Original line number Original line Diff line number Diff line
/*
 * Copyright (C) 2016 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef INCIDENT_SECTIONS_H
#define INCIDENT_SECTIONS_H

struct IncidentSection
{
    int id;
    char const* name;
};

extern IncidentSection const INCIDENT_SECTIONS[];
extern const int INCIDENT_SECTION_COUNT;

#endif // INCIDENT_SECTIONS_H
Loading