2 * Copyright (C) 2014 The Android Open Source Project
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 #ifndef __OUTPUT_SET_H
18 #define __OUTPUT_SET_H
21 #include <utils/Errors.h>
22 #include <utils/String8.h>
23 #include <utils/StrongPointer.h>
30 OutputEntry(const android::String8& path, const android::sp<const AaptFile>& file)
31 : mPath(path), mFile(file) {}
33 inline const android::sp<const AaptFile>& getFile() const {
37 inline const android::String8& getPath() const {
41 bool operator<(const OutputEntry& o) const { return getPath() < o.mPath; }
42 bool operator==(const OutputEntry& o) const { return getPath() == o.mPath; }
45 android::String8 mPath;
46 android::sp<const AaptFile> mFile;
49 class OutputSet : public virtual android::RefBase {
51 virtual const std::set<OutputEntry>& getEntries() const = 0;
53 virtual ~OutputSet() {}
56 #endif // __OUTPUT_SET_H