test_class.declarator: compilationRule = new CompilationRule()
test_class.modifier: @Rule public
test_class.original_string: @Rule public CompilationRule compilationRule = new CompilationRule();
test_class.type: CompilationRule
test_class.var_name: compilationRule
test_class.file: compiler/src/test/java/dagger/internal/codegen/writer/ClassNameTest.java
test_class.identifier: ClassNameTest
test_case.body: @Test public void bestGuessForString_confusingInput() {
      try {
        ClassName.bestGuessFromString("com.test.$");
        fail();
      } catch (IllegalArgumentException expected) {}
      try {
        ClassName.bestGuessFromString("com.test.LooksLikeAClass.pkg");
        fail();
      } catch (IllegalArgumentException expected) {}
      try {
        ClassName.bestGuessFromString("!@#$gibberish%^&*");
        fail();
      } catch (IllegalArgumentException expected) {}
    }
test_case.class_method_signature: ClassNameTest.bestGuessForString_confusingInput()
test_case.full_signature: @Test public void bestGuessForString_confusingInput()
test_case.identifier: bestGuessForString_confusingInput
test_case.invocations: bestGuessFromString fail bestGuessFromString fail bestGuessFromString fail
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void bestGuessForString_confusingInput()
focal_class.declarator: fullyQualifiedName = null
focal_class.modifier: private
focal_class.original_string: private String fullyQualifiedName = null;
focal_class.type: String
focal_class.var_name: fullyQualifiedName
focal_class.declarator: packageName
focal_class.modifier: private final
focal_class.original_string: private final String packageName;
focal_class.type: String
focal_class.var_name: packageName
focal_class.declarator: enclosingSimpleNames
focal_class.modifier: private final
focal_class.original_string: private final ImmutableList<String> enclosingSimpleNames;
focal_class.type: ImmutableList<String>
focal_class.var_name: enclosingSimpleNames
focal_class.declarator: simpleName
focal_class.modifier: private final
focal_class.original_string: private final String simpleName;
focal_class.type: String
focal_class.var_name: simpleName
focal_class.declarator: ACCEPTABLE_NESTING_KINDS =
        Sets.immutableEnumSet(TOP_LEVEL, MEMBER)
focal_class.modifier: private static final
focal_class.original_string: private static final ImmutableSet<NestingKind> ACCEPTABLE_NESTING_KINDS =
        Sets.immutableEnumSet(TOP_LEVEL, MEMBER);
focal_class.type: ImmutableSet<NestingKind>
focal_class.var_name: ACCEPTABLE_NESTING_KINDS
focal_class.file: compiler/src/main/java/dagger/internal/codegen/writer/ClassName.java
focal_class.identifier: ClassName
focal_class.interfaces: implements TypeName, Comparable<ClassName>
focal_class.class_method_signature: ClassName.ClassName(String packageName, ImmutableList<String> enclosingSimpleNames,
        String simpleName)
focal_class.full_signature: private  ClassName(String packageName, ImmutableList<String> enclosingSimpleNames,
        String simpleName)
focal_class.identifier: ClassName
focal_class.modifiers: private
focal_class.parameters: (String packageName, ImmutableList<String> enclosingSimpleNames,
        String simpleName)
focal_class.signature:  ClassName(String packageName, ImmutableList<String> enclosingSimpleNames,
        String simpleName)
focal_class.class_method_signature: ClassName.packageName()
focal_class.full_signature: public String packageName()
focal_class.identifier: packageName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String packageName()
focal_class.class_method_signature: ClassName.enclosingSimpleNames()
focal_class.full_signature: public ImmutableList<String> enclosingSimpleNames()
focal_class.identifier: enclosingSimpleNames
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: ImmutableList<String>
focal_class.signature: ImmutableList<String> enclosingSimpleNames()
focal_class.class_method_signature: ClassName.enclosingClassName()
focal_class.full_signature: public Optional<ClassName> enclosingClassName()
focal_class.identifier: enclosingClassName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: Optional<ClassName>
focal_class.signature: Optional<ClassName> enclosingClassName()
focal_class.class_method_signature: ClassName.simpleName()
focal_class.full_signature: public String simpleName()
focal_class.identifier: simpleName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String simpleName()
focal_class.class_method_signature: ClassName.canonicalName()
focal_class.full_signature: public String canonicalName()
focal_class.identifier: canonicalName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String canonicalName()
focal_class.class_method_signature: ClassName.classFileName()
focal_class.full_signature: public String classFileName()
focal_class.identifier: classFileName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String classFileName()
focal_class.class_method_signature: ClassName.topLevelClassName()
focal_class.full_signature: public ClassName topLevelClassName()
focal_class.identifier: topLevelClassName
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: ClassName
focal_class.signature: ClassName topLevelClassName()
focal_class.class_method_signature: ClassName.nestedClassNamed(String memberClassName)
focal_class.full_signature: public ClassName nestedClassNamed(String memberClassName)
focal_class.identifier: nestedClassNamed
focal_class.modifiers: public
focal_class.parameters: (String memberClassName)
focal_class.return: ClassName
focal_class.signature: ClassName nestedClassNamed(String memberClassName)
focal_class.class_method_signature: ClassName.peerNamed(String peerClassName)
focal_class.full_signature: public ClassName peerNamed(String peerClassName)
focal_class.identifier: peerNamed
focal_class.modifiers: public
focal_class.parameters: (String peerClassName)
focal_class.return: ClassName
focal_class.signature: ClassName peerNamed(String peerClassName)
focal_class.class_method_signature: ClassName.fromTypeElement(TypeElement element)
focal_class.full_signature: public static ClassName fromTypeElement(TypeElement element)
focal_class.identifier: fromTypeElement
focal_class.modifiers: public static
focal_class.parameters: (TypeElement element)
focal_class.return: ClassName
focal_class.signature: ClassName fromTypeElement(TypeElement element)
focal_class.class_method_signature: ClassName.fromClass(Class<?> clazz)
focal_class.full_signature: public static ClassName fromClass(Class<?> clazz)
focal_class.identifier: fromClass
focal_class.modifiers: public static
focal_class.parameters: (Class<?> clazz)
focal_class.return: ClassName
focal_class.signature: ClassName fromClass(Class<?> clazz)
focal_class.class_method_signature: ClassName.getPackage(Element type)
focal_class.full_signature: private static PackageElement getPackage(Element type)
focal_class.identifier: getPackage
focal_class.modifiers: private static
focal_class.parameters: (Element type)
focal_class.return: PackageElement
focal_class.signature: PackageElement getPackage(Element type)
focal_class.class_method_signature: ClassName.bestGuessFromString(String classNameString)
focal_class.full_signature: public static ClassName bestGuessFromString(String classNameString)
focal_class.identifier: bestGuessFromString
focal_class.modifiers: public static
focal_class.parameters: (String classNameString)
focal_class.return: ClassName
focal_class.signature: ClassName bestGuessFromString(String classNameString)
focal_class.class_method_signature: ClassName.create(
        String packageName, List<String> enclosingSimpleNames, String simpleName)
focal_class.full_signature: public static ClassName create(
        String packageName, List<String> enclosingSimpleNames, String simpleName)
focal_class.identifier: create
focal_class.modifiers: public static
focal_class.parameters: (
        String packageName, List<String> enclosingSimpleNames, String simpleName)
focal_class.return: ClassName
focal_class.signature: ClassName create(
        String packageName, List<String> enclosingSimpleNames, String simpleName)
focal_class.class_method_signature: ClassName.create(String packageName, String simpleName)
focal_class.full_signature: public static ClassName create(String packageName, String simpleName)
focal_class.identifier: create
focal_class.modifiers: public static
focal_class.parameters: (String packageName, String simpleName)
focal_class.return: ClassName
focal_class.signature: ClassName create(String packageName, String simpleName)
focal_class.class_method_signature: ClassName.toString()
focal_class.full_signature: @Override public String toString()
focal_class.identifier: toString
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String toString()
focal_class.class_method_signature: ClassName.write(Appendable appendable, Context context)
focal_class.full_signature: @Override public Appendable write(Appendable appendable, Context context)
focal_class.identifier: write
focal_class.modifiers: @Override public
focal_class.parameters: (Appendable appendable, Context context)
focal_class.return: Appendable
focal_class.signature: Appendable write(Appendable appendable, Context context)
focal_class.class_method_signature: ClassName.equals(Object obj)
focal_class.full_signature: @Override public boolean equals(Object obj)
focal_class.identifier: equals
focal_class.modifiers: @Override public
focal_class.parameters: (Object obj)
focal_class.return: boolean
focal_class.signature: boolean equals(Object obj)
focal_class.class_method_signature: ClassName.hashCode()
focal_class.full_signature: @Override public int hashCode()
focal_class.identifier: hashCode
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int hashCode()
focal_class.class_method_signature: ClassName.compareTo(ClassName o)
focal_class.full_signature: @Override public int compareTo(ClassName o)
focal_class.identifier: compareTo
focal_class.modifiers: @Override public
focal_class.parameters: (ClassName o)
focal_class.return: int
focal_class.signature: int compareTo(ClassName o)
focal_class.class_method_signature: ClassName.referencedClasses()
focal_class.full_signature: @Override public Set<ClassName> referencedClasses()
focal_class.identifier: referencedClasses
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Set<ClassName>
focal_class.signature: Set<ClassName> referencedClasses()
focal_method.body: public static ClassName bestGuessFromString(String classNameString) {
      checkNotNull(classNameString);
      List<String> parts = Splitter.on('.').splitToList(classNameString);
      int firstClassPartIndex = -1;
      for (int i = 0; i < parts.size(); i++) {
        String part = parts.get(i);
        checkArgument(SourceVersion.isIdentifier(part));
        char firstChar = part.charAt(0);
        if (Ascii.isLowerCase(firstChar)) {
          // looks like a package part
          if (firstClassPartIndex >= 0) {
            throw new IllegalArgumentException("couldn't make a guess for " + classNameString);
          }
        } else if (Ascii.isUpperCase(firstChar)) {
          // looks like a class part
          if (firstClassPartIndex < 0) {
            firstClassPartIndex = i;
          }
        } else {
          throw new IllegalArgumentException("couldn't make a guess for " + classNameString);
        }
      }
      int lastIndex = parts.size() - 1;
      return new ClassName(
          Joiner.on('.').join(parts.subList(0, firstClassPartIndex)),
          firstClassPartIndex == lastIndex
              ? ImmutableList.<String>of()
              : ImmutableList.copyOf(parts.subList(firstClassPartIndex, lastIndex)),
          parts.get(lastIndex));
    }
focal_method.class_method_signature: ClassName.bestGuessFromString(String classNameString)
focal_method.full_signature: public static ClassName bestGuessFromString(String classNameString)
focal_method.identifier: bestGuessFromString
focal_method.invocations: checkNotNull splitToList on size get checkArgument isIdentifier charAt isLowerCase isUpperCase size join on subList of copyOf subList get
focal_method.modifiers: public static
focal_method.parameters: (String classNameString)
focal_method.return: ClassName
focal_method.signature: ClassName bestGuessFromString(String classNameString)