mirror of
https://github.com/f-droid/fdroidclient.git
synced 2026-06-23 07:10:11 -04:00
move ".net.bluetooth" into ".nearby" package
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
package org.fdroid.fdroid.net.bluetooth;
|
||||
package org.fdroid.fdroid.nearby;
|
||||
|
||||
import android.bluetooth.BluetoothSocket;
|
||||
import org.fdroid.fdroid.Utils;
|
||||
@@ -1,4 +1,4 @@
|
||||
package org.fdroid.fdroid.net.bluetooth;
|
||||
package org.fdroid.fdroid.nearby;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
package org.fdroid.fdroid.net.bluetooth.httpish.headers;
|
||||
|
||||
import org.fdroid.fdroid.net.bluetooth.FileDetails;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
public class ContentLengthHeader extends Header {
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
package org.fdroid.fdroid.net.bluetooth.httpish.headers;
|
||||
|
||||
import org.fdroid.fdroid.net.bluetooth.FileDetails;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
public class ETagHeader extends Header {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package org.fdroid.fdroid.net.bluetooth;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
public class FileDetails {
|
||||
|
||||
@@ -13,11 +13,11 @@ public class FileDetails {
|
||||
return fileSize;
|
||||
}
|
||||
|
||||
public void setFileSize(int fileSize) {
|
||||
void setFileSize(int fileSize) {
|
||||
this.fileSize = fileSize;
|
||||
}
|
||||
|
||||
public void setCacheTag(String cacheTag) {
|
||||
void setCacheTag(String cacheTag) {
|
||||
this.cacheTag = cacheTag;
|
||||
}
|
||||
}
|
||||
@@ -1,14 +1,12 @@
|
||||
package org.fdroid.fdroid.net.bluetooth.httpish.headers;
|
||||
|
||||
import org.fdroid.fdroid.net.bluetooth.FileDetails;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
import java.util.Locale;
|
||||
|
||||
public abstract class Header {
|
||||
|
||||
private static final Header[] VALID_HEADERS = {
|
||||
new ContentLengthHeader(),
|
||||
new ETagHeader(),
|
||||
new ContentLengthHeader(),
|
||||
new ETagHeader(),
|
||||
};
|
||||
|
||||
protected abstract String getName();
|
||||
@@ -1,7 +1,7 @@
|
||||
package org.fdroid.fdroid.net.bluetooth.httpish;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
import org.fdroid.fdroid.Utils;
|
||||
import org.fdroid.fdroid.net.bluetooth.BluetoothConnection;
|
||||
import org.fdroid.fdroid.nearby.BluetoothConnection;
|
||||
|
||||
import java.io.ByteArrayOutputStream;
|
||||
import java.io.IOException;
|
||||
@@ -1,10 +1,8 @@
|
||||
package org.fdroid.fdroid.net.bluetooth.httpish;
|
||||
package org.fdroid.fdroid.nearby.httpish;
|
||||
|
||||
import android.util.Log;
|
||||
import org.fdroid.fdroid.Utils;
|
||||
import org.fdroid.fdroid.net.bluetooth.BluetoothConnection;
|
||||
import org.fdroid.fdroid.net.bluetooth.FileDetails;
|
||||
import org.fdroid.fdroid.net.bluetooth.httpish.headers.Header;
|
||||
import org.fdroid.fdroid.nearby.BluetoothConnection;
|
||||
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.IOException;
|
||||
@@ -87,7 +85,7 @@ public class Response {
|
||||
|
||||
/**
|
||||
* Extracts meaningful headers from the response into a more useful and safe
|
||||
* {@link org.fdroid.fdroid.net.bluetooth.FileDetails} object.
|
||||
* {@link FileDetails} object.
|
||||
*/
|
||||
public FileDetails toFileDetails() {
|
||||
FileDetails details = new FileDetails();
|
||||
@@ -5,11 +5,11 @@ import android.support.annotation.Nullable;
|
||||
import android.util.Log;
|
||||
import org.apache.commons.io.input.BoundedInputStream;
|
||||
import org.fdroid.fdroid.Utils;
|
||||
import org.fdroid.fdroid.net.bluetooth.BluetoothClient;
|
||||
import org.fdroid.fdroid.net.bluetooth.BluetoothConnection;
|
||||
import org.fdroid.fdroid.net.bluetooth.FileDetails;
|
||||
import org.fdroid.fdroid.net.bluetooth.httpish.Request;
|
||||
import org.fdroid.fdroid.net.bluetooth.httpish.Response;
|
||||
import org.fdroid.fdroid.nearby.BluetoothClient;
|
||||
import org.fdroid.fdroid.nearby.BluetoothConnection;
|
||||
import org.fdroid.fdroid.nearby.httpish.FileDetails;
|
||||
import org.fdroid.fdroid.nearby.httpish.Request;
|
||||
import org.fdroid.fdroid.nearby.httpish.Response;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
||||
Reference in New Issue
Block a user