Skip to content

Commit

Permalink
chore: apply spotless on java files
Browse files Browse the repository at this point in the history
  • Loading branch information
Bambooin committed Feb 18, 2024
1 parent c30ec0c commit 94dae82
Show file tree
Hide file tree
Showing 8 changed files with 54 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ public WriteTextFileCallable(
@WorkerThread
@Override
public Unit call()
throws IOException, StreamNotFoundException, ShellNotRunningException,
throws IOException,
StreamNotFoundException,
ShellNotRunningException,
IllegalArgumentException {
OutputStream outputStream;
File destFile = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ public class EncryptDecryptUtils {

public static final String DECRYPT_BROADCAST = "decrypt_broadcast";
private static final Logger LOG = LoggerFactory.getLogger(EncryptDecryptUtils.class);

/**
* Queries database to map path and password. Starts the encryption process after database query
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,7 @@ public class MainActivity extends PermissionsActivity
private UtilsHandler utilsHandler;
private CloudHandler cloudHandler;
private CloudLoaderAsyncTask cloudLoaderAsyncTask;

/**
* This is for a hack.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ public class ProcessViewerFragment extends Fragment {
private int accentColor;
private final LineData lineData = new LineData();
private ProcessparentBinding binding = null;

/** Time in seconds just for showing to the user. No guarantees. */
private long looseTimeInSeconds = 0L;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,13 @@ public class ProgressHandler {
* (see Java Language Specification 17.7)
*/
private volatile long writtenSize = 0L;

/** total number of source files to be processed */
private volatile int sourceFiles = 0;

/** number of source files processed so far */
private volatile int sourceFilesProcessed = 0;

/** file name currently being processed */
private volatile String fileName;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,11 @@ static void addUsbOtgDevice(Activity activity) {

@RequiresApi(Build.VERSION_CODES.LOLLIPOP)
static void configureUsbDevice(UsbDevice device)
throws NoSuchMethodException, ClassNotFoundException, InvocationTargetException,
InstantiationException, IllegalAccessException {
throws NoSuchMethodException,
ClassNotFoundException,
InvocationTargetException,
InstantiationException,
IllegalAccessException {
UsbConfiguration usbConfiguration = callUsbConfigurationConstructor(0, "", 0, 0);
configureUsbConfiguration(usbConfiguration);

Expand All @@ -91,8 +94,11 @@ static void configureUsbDevice(UsbDevice device)

@RequiresApi(Build.VERSION_CODES.LOLLIPOP)
static void configureUsbConfiguration(UsbConfiguration usbConfiguration)
throws NoSuchMethodException, ClassNotFoundException, InvocationTargetException,
InstantiationException, IllegalAccessException {
throws NoSuchMethodException,
ClassNotFoundException,
InvocationTargetException,
InstantiationException,
IllegalAccessException {
UsbInterface usbInterface =
callUsbInterfaceConstructor(01, 0, "", USB_CLASS_MASS_STORAGE, 0, 0);

Expand All @@ -103,8 +109,11 @@ static void configureUsbConfiguration(UsbConfiguration usbConfiguration)

@RequiresApi(Build.VERSION_CODES.KITKAT)
static Parcelable[] configureUsbDevice()
throws ClassNotFoundException, NoSuchMethodException, InvocationTargetException,
InstantiationException, IllegalAccessException {
throws ClassNotFoundException,
NoSuchMethodException,
InvocationTargetException,
InstantiationException,
IllegalAccessException {
UsbInterface usbInterface =
(UsbInterface) callUsbInterfaceConstructor(01, USB_CLASS_MASS_STORAGE, 0, 0, null);

Expand All @@ -123,8 +132,11 @@ static UsbDevice callUsbDeviceConstructor(
@Nullable String productName,
@NonNull String version,
@Nullable String serialNumber)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbDevice> clazz = (Class<UsbDevice>) Class.forName("android.hardware.usb.UsbDevice");
Constructor<UsbDevice> constructor =
Expand Down Expand Up @@ -164,8 +176,11 @@ static UsbDevice callUsbDeviceConstructor(
@Nullable String manufacturerName,
@Nullable String productName,
@Nullable String serialNumber)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbDevice> clazz = (Class<UsbDevice>) Class.forName("android.hardware.usb.UsbDevice");
Constructor<UsbDevice> constructor =
Expand Down Expand Up @@ -201,8 +216,11 @@ static UsbDevice callUsbDeviceConstructor(
int subClass,
int protocol,
@NonNull Parcelable[] interfaces)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbDevice> clazz = (Class<UsbDevice>) Class.forName("android.hardware.usb.UsbDevice");
Constructor<UsbDevice> constructor =
Expand All @@ -222,8 +240,11 @@ static UsbDevice callUsbDeviceConstructor(
@RequiresApi(Build.VERSION_CODES.LOLLIPOP)
static UsbConfiguration callUsbConfigurationConstructor(
int id, @Nullable String name, int attributes, int maxPower)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbConfiguration> clazz =
(Class<UsbConfiguration>) Class.forName("android.hardware.usb.UsbConfiguration");
Expand All @@ -236,8 +257,11 @@ static UsbConfiguration callUsbConfigurationConstructor(
@RequiresApi(Build.VERSION_CODES.LOLLIPOP)
static UsbInterface callUsbInterfaceConstructor(
int id, int alternateSetting, @Nullable String name, int usbClass, int subClass, int protocol)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbInterface> clazz =
(Class<UsbInterface>) Class.forName("android.hardware.usb.UsbInterface");
Expand All @@ -250,8 +274,11 @@ static UsbInterface callUsbInterfaceConstructor(
@RequiresApi(Build.VERSION_CODES.KITKAT)
static UsbInterface callUsbInterfaceConstructor(
int id, int usbClass, int subClass, int protocol, @Nullable Parcelable[] endpoints)
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException, InstantiationException {
throws ClassNotFoundException,
NoSuchMethodException,
IllegalAccessException,
InvocationTargetException,
InstantiationException {

Class<UsbInterface> clazz =
(Class<UsbInterface>) Class.forName("android.hardware.usb.UsbInterface");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
/** Base Codec class. */
abstract class CoderBase {
private final Class<?>[] acceptableOptions;

/**
* @param acceptableOptions types that can be used as options for this codec.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
package com.amaze.filemanager.shadows.jcifs.smb;

import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
Expand Down

0 comments on commit 94dae82

Please sign in to comment.