// Path: tweakable-annotations/src/main/java/com/jackwink/tweakable/exceptions/FailedToBuildPreferenceException.java
// public class FailedToBuildPreferenceException extends RuntimeException {
//     public static final long serialVersionUID = 0L;
// 
//     public FailedToBuildPreferenceException(String reason) {
//         super(reason);
//     }
// 
//     public FailedToBuildPreferenceException(String reason, Throwable rootCause) {
//         super(reason, rootCause);
//     }
// }


import android.content.SharedPreferences;
import com.jackwink.tweakable.exceptions.FailedToBuildPreferenceException;
import java.lang.reflect.Field;
package com.jackwink.tweakable.binders;




/**
 * Binds a String value to a given {@link Field}.
 */
public class StringValueBinder extends AbstractValueBinder<String> {

    public StringValueBinder(Field field) {
        mField = field;
    }

    @Override
    public Class<String> getType() {
        return String.class;
    }

    @Override
    public String getValue() {
        try {
            if (mField.getType().equals(String.class)) {
                return (String) mField.get(null);
            }
// Path: tweakable-annotations/src/main/java/com/jackwink/tweakable/exceptions/FailedToBuildPreferenceException.java
// public class FailedToBuildPreferenceException extends RuntimeException {
//     public static final long serialVersionUID = 0L;
// 
//     public FailedToBuildPreferenceException(String reason) {
//         super(reason);
//     }
// 
//     public FailedToBuildPreferenceException(String reason, Throwable rootCause) {
//         super(reason, rootCause);
//     }
// }


// Path: tweakable/src/main/java/com/jackwink/tweakable/binders/StringValueBinder.java
import android.content.SharedPreferences;
import com.jackwink.tweakable.exceptions.FailedToBuildPreferenceException;
import java.lang.reflect.Field;

package com.jackwink.tweakable.binders;




/**
 * Binds a String value to a given {@link Field}.
 */
public class StringValueBinder extends AbstractValueBinder<String> {

    public StringValueBinder(Field field) {
        mField = field;
    }

    @Override
    public Class<String> getType() {
        return String.class;
    }

    @Override
    public String getValue() {
        try {
            if (mField.getType().equals(String.class)) {
                return (String) mField.get(null);
            }
            throw new FailedToBuildPreferenceException(