Loading apex/blobstore/service/java/com/android/server/blob/BlobStoreConfig.java +9 −4 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,11 @@ class BlobStoreConfig { public static final int CURRENT_XML_VERSION = 1; public static final int CURRENT_XML_VERSION = 1; private static final String ROOT_DIR_NAME = "blobstore"; private static final String BLOBS_DIR_NAME = "blobs"; private static final String SESSIONS_INDEX_FILE_NAME = "sessions_index.xml"; private static final String BLOBS_INDEX_FILE_NAME = "blobs_index.xml"; @Nullable @Nullable public static File prepareBlobFile(long sessionId) { public static File prepareBlobFile(long sessionId) { final File blobsDir = prepareBlobsDir(); final File blobsDir = prepareBlobsDir(); Loading Loading @@ -60,7 +65,7 @@ class BlobStoreConfig { @NonNull @NonNull private static File getBlobsDir(File blobsRootDir) { private static File getBlobsDir(File blobsRootDir) { return new File(blobsRootDir, "blobs"); return new File(blobsRootDir, BLOBS_DIR_NAME); } } @Nullable @Nullable Loading @@ -69,7 +74,7 @@ class BlobStoreConfig { if (blobStoreRootDir == null) { if (blobStoreRootDir == null) { return null; return null; } } return new File(blobStoreRootDir, "sessions_index.xml"); return new File(blobStoreRootDir, SESSIONS_INDEX_FILE_NAME); } } @Nullable @Nullable Loading @@ -78,7 +83,7 @@ class BlobStoreConfig { if (blobsStoreRootDir == null) { if (blobsStoreRootDir == null) { return null; return null; } } return new File(blobsStoreRootDir, "blobs_index.xml"); return new File(blobsStoreRootDir, BLOBS_INDEX_FILE_NAME); } } @Nullable @Nullable Loading @@ -93,6 +98,6 @@ class BlobStoreConfig { @NonNull @NonNull public static File getBlobStoreRootDir() { public static File getBlobStoreRootDir() { return new File(Environment.getDataSystemDirectory(), "blobstore"); return new File(Environment.getDataSystemDirectory(), ROOT_DIR_NAME); } } } } Loading
apex/blobstore/service/java/com/android/server/blob/BlobStoreConfig.java +9 −4 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,11 @@ class BlobStoreConfig { public static final int CURRENT_XML_VERSION = 1; public static final int CURRENT_XML_VERSION = 1; private static final String ROOT_DIR_NAME = "blobstore"; private static final String BLOBS_DIR_NAME = "blobs"; private static final String SESSIONS_INDEX_FILE_NAME = "sessions_index.xml"; private static final String BLOBS_INDEX_FILE_NAME = "blobs_index.xml"; @Nullable @Nullable public static File prepareBlobFile(long sessionId) { public static File prepareBlobFile(long sessionId) { final File blobsDir = prepareBlobsDir(); final File blobsDir = prepareBlobsDir(); Loading Loading @@ -60,7 +65,7 @@ class BlobStoreConfig { @NonNull @NonNull private static File getBlobsDir(File blobsRootDir) { private static File getBlobsDir(File blobsRootDir) { return new File(blobsRootDir, "blobs"); return new File(blobsRootDir, BLOBS_DIR_NAME); } } @Nullable @Nullable Loading @@ -69,7 +74,7 @@ class BlobStoreConfig { if (blobStoreRootDir == null) { if (blobStoreRootDir == null) { return null; return null; } } return new File(blobStoreRootDir, "sessions_index.xml"); return new File(blobStoreRootDir, SESSIONS_INDEX_FILE_NAME); } } @Nullable @Nullable Loading @@ -78,7 +83,7 @@ class BlobStoreConfig { if (blobsStoreRootDir == null) { if (blobsStoreRootDir == null) { return null; return null; } } return new File(blobsStoreRootDir, "blobs_index.xml"); return new File(blobsStoreRootDir, BLOBS_INDEX_FILE_NAME); } } @Nullable @Nullable Loading @@ -93,6 +98,6 @@ class BlobStoreConfig { @NonNull @NonNull public static File getBlobStoreRootDir() { public static File getBlobStoreRootDir() { return new File(Environment.getDataSystemDirectory(), "blobstore"); return new File(Environment.getDataSystemDirectory(), ROOT_DIR_NAME); } } } }