Class ClasspathEntry


  • public class ClasspathEntry
    extends java.lang.Object
    Classpath entry specification for the classpath. This information comes from Eclipse and is simplified in order not to use Inclusion and Exclusion patterns, Access rules or Extra attributes. This could be added later.
    Author:
    Christopher Mindus
    • Nested Class Summary

      Nested Classes 
      Modifier and TypeClassDescription
      static class ClasspathEntry.Type
      The enumeration for the ClasspathEntry type.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and TypeMethodDescription
      booleanequals​(java.lang.Object o)
      Checks for two equals.
      static ClasspathEntryfromString​(java.lang.String string)
      Creates a new instance of ClasspathEntry from a string that came from toString().
      inthashCode()
      Gets the hash code.
      java.lang.StringtoString()
      Creates a string out of the entry that later can be used to create a new instance of the ClasspathEntry using fromString(String).
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • path

        public final java.lang.String path
        The path entry.
    • Constructor Detail

      • ClasspathEntry

        public ClasspathEntry​(ClasspathEntry.Type type,
                              java.lang.String path)
        Constructor.
        Parameters:
        type - Type of entry.
        path - The path entry.
        Throws:
        java.lang.NullPointerException - if type or path is null.
    • Method Detail

      • fromString

        public static ClasspathEntry fromString​(java.lang.String string)
        Creates a new instance of ClasspathEntry from a string that came from toString().
        Parameters:
        string - The string.
        Returns:
        A new ClasspathEntry instance.
        Throws:
        java.lang.IllegalArgumentException - If the string format is invalid.
      • toString

        public java.lang.String toString()
        Creates a string out of the entry that later can be used to create a new instance of the ClasspathEntry using fromString(String).
        Overrides:
        toString in class java.lang.Object
        Returns:
        A string as TYPE=path.
      • equals

        public boolean equals​(java.lang.Object o)
        Checks for two equals.
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Gets the hash code.
        Overrides:
        hashCode in class java.lang.Object