package com.crossbowffs.remotepreferences;

/**
 * Represents a single preference file and the information needed to
 * access that preference file.
 */
public class RemotePreferenceFile {
    private final String mFileName;
    private final boolean mIsDeviceProtected;

    /**
     * Initializes the preference file information. If you are targeting Android
     * N or above and the preference needs to be accessed before the first unlock,
     * set {@code isDeviceProtected} to {@code true}.
     *
     * @param fileName Name of the preference file.
     * @param isDeviceProtected {@code true} if the preference is device protected,
     *                          {@code false} if it is credential protected.
     */
    public RemotePreferenceFile(String fileName, boolean isDeviceProtected) {
        mFileName = fileName;
        mIsDeviceProtected = isDeviceProtected;
    }

    /**
     * Another constructor for the object.
     * Uses the credential protected context by default.
     * @param name Name of the preference file.
     */
    public RemotePreferenceFile(String name) {
        this(name, false);
    }

    /**
     * Returns the name of the preference file.
     */
    public String getFileName() {
        return mFileName;
    }

    /**
     * Returns whether the preferences are located in device protected storage.
     */
    public boolean isDeviceProtected() {
        return mIsDeviceProtected;
    }

    /**
     * Converts an array of preference file names to {@link RemotePreferenceFile}
     * objects. Assumes all preference files are NOT in device protected storage.
     *
     * @param prefFileNames The names of the preference files to expose.
     * @return An array of {@link RemotePreferenceFile} objects.
     */
    public static RemotePreferenceFile[] fromFileNames(String[] prefFileNames) {
        RemotePreferenceFile[] prefFiles = new RemotePreferenceFile[prefFileNames.length];
        for (int i = 0; i < prefFileNames.length; i++) {
            prefFiles[i] = new RemotePreferenceFile(prefFileNames[i]);
        }
        return prefFiles;
    }
}

@@ -613,16 +613,21 @@
 ference 
+file 
 is devic
@@ -906,59 +906,98 @@
   * 
-Another constructor for the object.%0A     * Uses the
+Initializes the preference file information. Assumes the preferences are%0A     * located in
  cre
@@ -1018,27 +1018,23 @@
 ted 
-context by default.
+storage.%0A     *
 %0A   
@@ -1044,17 +1044,21 @@
  @param 
-n
+fileN
 ame Name
@@ -1129,17 +1129,21 @@
 (String 
-n
+fileN
 ame) %7B%0A 
@@ -1154,17 +1154,21 @@
    this(
-n
+fileN
 ame, fal
@@ -1227,32 +1227,87 @@
 reference file.%0A
+     *%0A     * @return The name of the preference file.%0A
      */%0A    publ
@@ -1449,24 +1449,163 @@
 ed storage.%0A
+     *%0A     * @return %7B@code true%7D if the preference file is device protected,%0A     *         %7B@code false%7D if it is credential protected.%0A
      */%0A    

Fix Javadoc warnings