1 /* 2 * Copyright (C) 2007 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 17 package com.android.ide.eclipse.adt.internal.resources; 18 19 /** 20 * A repository of resources. This allows access to the resource by {@link ResourceType}. 21 */ 22 public interface IResourceRepository { 23 24 /** 25 * Returns the present {@link ResourceType}s in the project. 26 * @return an array containing all the type of resources existing in the project. 27 */ getAvailableResourceTypes()28 public abstract ResourceType[] getAvailableResourceTypes(); 29 30 /** 31 * Returns an array of the existing resource for the specified type. 32 * @param type the type of the resources to return 33 */ getResources(ResourceType type)34 public abstract ResourceItem[] getResources(ResourceType type); 35 36 /** 37 * Returns whether resources of the specified type are present. 38 * @param type the type of the resources to check. 39 */ hasResources(ResourceType type)40 public abstract boolean hasResources(ResourceType type); 41 42 /** 43 * Returns whether the repository is a system repository. 44 */ isSystemRepository()45 public abstract boolean isSystemRepository(); 46 47 } 48