• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2010 The Android Open Source Project
3  *
4  * Licensed under the Eclipse Public License, Version 1.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.eclipse.org/org/documents/epl-v10.php
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.ide.common.layout;
17 
18 import com.android.ide.common.api.IAttributeInfo;
19 
20 /** Test/mock implementation of {@link IAttributeInfo} */
21 public class TestAttributeInfo implements IAttributeInfo {
22     private final String mName;
23     private final Format[] mFormats;
24     private final String mDefinedBy;
25     private final String[] mEnumValues;
26     private final String[] mFlagValues;
27     private final String mJavadoc;
28 
TestAttributeInfo(String name)29     public TestAttributeInfo(String name) {
30         this(name, null, null, null, null, null);
31     }
32 
TestAttributeInfo(String name, Format[] formats, String definedBy, String[] enumValues, String[] flagValues, String javadoc)33     public TestAttributeInfo(String name, Format[] formats, String definedBy,
34             String[] enumValues, String[] flagValues, String javadoc) {
35         super();
36         this.mName = name;
37         this.mFormats = formats;
38         this.mDefinedBy = definedBy;
39         this.mEnumValues = enumValues;
40         this.mFlagValues = flagValues;
41         this.mJavadoc = javadoc;
42     }
43 
getDeprecatedDoc()44     public String getDeprecatedDoc() {
45         return null;
46     }
47 
getEnumValues()48     public String[] getEnumValues() {
49         return mEnumValues;
50     }
51 
getFlagValues()52     public String[] getFlagValues() {
53         return mFlagValues;
54     }
55 
getFormats()56     public Format[] getFormats() {
57         return mFormats;
58     }
59 
getJavaDoc()60     public String getJavaDoc() {
61         return mJavadoc;
62     }
63 
getName()64     public String getName() {
65         return mName;
66     }
67 
getDefinedBy()68     public String getDefinedBy() {
69         return mDefinedBy;
70     }
71 }