// Path: processor/src/main/java/net/yslibrary/simplepreferences/processor/exception/ProcessingException.java
// public class ProcessingException extends Exception {
// 
//   public final Element element;
// 
//   public ProcessingException(Element element, String message, Object... args) {
//     super(String.format(message, args));
// 
//     this.element = element;
//   }
// }


import com.google.common.base.Strings;
import net.yslibrary.simplepreferences.annotation.Key;
import net.yslibrary.simplepreferences.annotation.Preferences;
import net.yslibrary.simplepreferences.processor.exception.ProcessingException;
import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import javax.lang.model.element.PackageElement;
import javax.lang.model.element.TypeElement;
import javax.lang.model.element.VariableElement;
import javax.lang.model.util.Elements;
package net.yslibrary.simplepreferences.processor;





/**
 * Created by yshrsmz on 2016/02/21.
 */
public class PreferenceAnnotatedClass {

  public final static String DEFAULT_PREFS = "net.yslibrary.simplepreferences.default_name";
  private final static String SUFFIX = "Prefs";

  public final TypeElement annotatedElement;

  // used as SharedPreferences' name
  public final String preferenceName;

  // generated class name
  public final String preferenceClassName;
  public final String qualifiedPreferenceClassName;

  public final String packageName;

  public final List<KeyAnnotatedField> keys = new ArrayList<>();

  public final boolean needCommitMethodForClear;

  public final boolean shouldBeExposed;

  public PreferenceAnnotatedClass(TypeElement element, Elements elementUtils)
// Path: processor/src/main/java/net/yslibrary/simplepreferences/processor/exception/ProcessingException.java
// public class ProcessingException extends Exception {
// 
//   public final Element element;
// 
//   public ProcessingException(Element element, String message, Object... args) {
//     super(String.format(message, args));
// 
//     this.element = element;
//   }
// }


// Path: processor/src/main/java/net/yslibrary/simplepreferences/processor/PreferenceAnnotatedClass.java
import com.google.common.base.Strings;
import net.yslibrary.simplepreferences.annotation.Key;
import net.yslibrary.simplepreferences.annotation.Preferences;
import net.yslibrary.simplepreferences.processor.exception.ProcessingException;
import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import javax.lang.model.element.PackageElement;
import javax.lang.model.element.TypeElement;
import javax.lang.model.element.VariableElement;
import javax.lang.model.util.Elements;

package net.yslibrary.simplepreferences.processor;





/**
 * Created by yshrsmz on 2016/02/21.
 */
public class PreferenceAnnotatedClass {

  public final static String DEFAULT_PREFS = "net.yslibrary.simplepreferences.default_name";
  private final static String SUFFIX = "Prefs";

  public final TypeElement annotatedElement;

  // used as SharedPreferences' name
  public final String preferenceName;

  // generated class name
  public final String preferenceClassName;
  public final String qualifiedPreferenceClassName;

  public final String packageName;

  public final List<KeyAnnotatedField> keys = new ArrayList<>();

  public final boolean needCommitMethodForClear;

  public final boolean shouldBeExposed;

  public PreferenceAnnotatedClass(TypeElement element, Elements elementUtils)
      throws IllegalStateException, ProcessingException {