Class SimpleDependencyInfo
- java.lang.Object
-
- com.google.javascript.jscomp.deps.SimpleDependencyInfo
-
- All Implemented Interfaces:
DependencyInfo
public class SimpleDependencyInfo extends java.lang.Object implements DependencyInfo
A class to hold JS dependency information for a single .js file.
-
-
Constructor Summary
Constructors Constructor Description SimpleDependencyInfo(java.lang.String srcPathRelativeToClosure, java.lang.String pathOfDefiningFile, java.util.List<java.lang.String> provides, java.util.List<java.lang.String> requires)
Constructs a DependencyInfo object with the given list of provides & requires.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
java.lang.String
getName()
Gets the unique name / path of this file.java.lang.String
getPathRelativeToClosureBase()
Gets the path of this file relative to Closure's base.js file.java.util.Collection<java.lang.String>
getProvides()
Gets the symbols provided by this file.java.util.Collection<java.lang.String>
getRequires()
Gets the symbols required by this file.java.lang.String
toString()
-
-
-
Constructor Detail
-
SimpleDependencyInfo
public SimpleDependencyInfo(java.lang.String srcPathRelativeToClosure, java.lang.String pathOfDefiningFile, java.util.List<java.lang.String> provides, java.util.List<java.lang.String> requires)
Constructs a DependencyInfo object with the given list of provides & requires. This does *not* copy the given lists, but uses them directly.- Parameters:
srcPathRelativeToClosure
- The closure-relative path of the file associated with this DependencyInfo.pathOfDefiningFile
- The path to the file from which this dependency information was extracted.provides
- List of provided symbols.requires
- List of required symbols.
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from interface:DependencyInfo
Gets the unique name / path of this file.- Specified by:
getName
in interfaceDependencyInfo
-
getPathRelativeToClosureBase
public java.lang.String getPathRelativeToClosureBase()
Description copied from interface:DependencyInfo
Gets the path of this file relative to Closure's base.js file.- Specified by:
getPathRelativeToClosureBase
in interfaceDependencyInfo
-
getProvides
public java.util.Collection<java.lang.String> getProvides()
Description copied from interface:DependencyInfo
Gets the symbols provided by this file.- Specified by:
getProvides
in interfaceDependencyInfo
-
getRequires
public java.util.Collection<java.lang.String> getRequires()
Description copied from interface:DependencyInfo
Gets the symbols required by this file.- Specified by:
getRequires
in interfaceDependencyInfo
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-