Home | History | Annotate | Download | only in testing
      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 
     17 package com.android.documentsui.testing;
     18 
     19 import com.android.documentsui.MenuManager.SelectionDetails;
     20 
     21 /**
     22  * Test copy of SelectionDetails, everything default to false
     23  */
     24 public class TestSelectionDetails implements SelectionDetails {
     25 
     26     public int size;
     27     public boolean canRename;
     28     public boolean canDelete;
     29     public boolean containPartial;
     30     public boolean containDirectories;
     31     public boolean containFiles;
     32     public boolean canPasteInto;
     33     public boolean canExtract;
     34     public boolean canOpenWith;
     35     public boolean canViewInOwner;
     36 
     37     @Override
     38     public boolean containsPartialFiles() {
     39         return containPartial;
     40     }
     41 
     42     @Override
     43     public boolean containsFiles() {
     44         return containFiles;
     45     }
     46 
     47     @Override
     48     public boolean containsDirectories() {
     49         return containDirectories;
     50     }
     51 
     52     @Override
     53     public boolean canRename() {
     54         return canRename;
     55     }
     56 
     57     @Override
     58     public boolean canDelete() {
     59         return canDelete;
     60     }
     61 
     62     @Override
     63     public boolean canExtract() {
     64         return canExtract;
     65     }
     66 
     67     @Override
     68     public boolean canPasteInto() {
     69         return canPasteInto;
     70     }
     71 
     72     @Override
     73     public boolean canOpenWith() {
     74         return canOpenWith;
     75     }
     76 
     77     @Override
     78     public boolean canViewInOwner() {
     79         return canViewInOwner;
     80     }
     81 
     82     @Override
     83     public int size() {
     84         return size;
     85     }
     86  }
     87