• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2016 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 package com.android.loganalysis.item;
17 
18 import java.util.Arrays;
19 import java.util.HashSet;
20 import java.util.Set;
21 
22 /**
23  * An {@link IItem} used to store Activity Service Dumps
24  */
25 public class ActivityServiceItem extends GenericItem {
26 
27     /** Constant for JSON output */
28     public static final String LOCATION_DUMPS = "LOCATION";
29 
30     private static final Set<String> ATTRIBUTES = new HashSet<String>(Arrays.asList(
31             LOCATION_DUMPS));
32 
33     /**
34      * The constructor for {@link ActivityServiceItem}.
35      */
ActivityServiceItem()36     public ActivityServiceItem() {
37         super(ATTRIBUTES);
38     }
39 
40     /**
41      * Get the location dump
42      */
getLocationDumps()43     public LocationDumpsItem getLocationDumps() {
44         return (LocationDumpsItem) getAttribute(LOCATION_DUMPS);
45     }
46 
47     /**
48      * Set the location dump
49      */
setLocationDumps(LocationDumpsItem location)50     public void setLocationDumps(LocationDumpsItem location) {
51         setAttribute(LOCATION_DUMPS, location);
52     }
53 }
54