Search in sources :

Example 1 with ResourceFileData

use of org.jetbrains.android.util.ResourceFileData in project android by JetBrains.

the class AndroidAptValidityState method save.

@Override
public void save(DataOutput out) throws IOException {
    out.writeInt(SIGNATURE);
    out.writeByte(VERSION);
    out.writeUTF(myPackageName);
    out.writeInt(myResources.size());
    for (Map.Entry<String, ResourceFileData> entry : myResources.entrySet()) {
        out.writeUTF(entry.getKey());
        final ResourceFileData fileData = entry.getValue();
        final List<ResourceEntry> resources = fileData.getValueResources();
        out.writeInt(resources.size());
        for (ResourceEntry resource : resources) {
            out.writeUTF(resource.getType());
            out.writeUTF(resource.getName());
            out.writeUTF(resource.getContext());
        }
        out.writeLong(fileData.getTimestamp());
    }
    out.writeInt(myManifestElements.size());
    for (ResourceEntry manifestElement : myManifestElements) {
        out.writeUTF(manifestElement.getType());
        out.writeUTF(manifestElement.getName());
        out.writeUTF(manifestElement.getContext());
    }
    out.writeInt(myLibRTxtFilesAndPackages.size());
    for (Pair<String, String> pair : myLibRTxtFilesAndPackages) {
        out.writeUTF(pair.getFirst());
        out.writeUTF(pair.getSecond());
    }
    out.writeUTF(myProguardOutputCfgFile);
    out.writeUTF(myRTxtOutputDir);
    out.writeBoolean(myLibrary);
    out.writeInt(myValueResourceFilesTimestamps.size());
    for (Object key : myValueResourceFilesTimestamps.keys()) {
        final String strKey = (String) key;
        out.writeUTF(strKey);
        out.writeLong(myValueResourceFilesTimestamps.get(strKey));
    }
}
Also used : ResourceFileData(org.jetbrains.android.util.ResourceFileData) ResourceEntry(org.jetbrains.android.util.ResourceEntry) HashMap(com.intellij.util.containers.HashMap) TObjectLongHashMap(gnu.trove.TObjectLongHashMap)

Aggregations

HashMap (com.intellij.util.containers.HashMap)1 TObjectLongHashMap (gnu.trove.TObjectLongHashMap)1 ResourceEntry (org.jetbrains.android.util.ResourceEntry)1 ResourceFileData (org.jetbrains.android.util.ResourceFileData)1