com.google.javascript.jscomp.deps
Class SimpleDependencyInfo

java.lang.Object
  extended by com.google.javascript.jscomp.deps.SimpleDependencyInfo
All Implemented Interfaces:
DependencyInfo

public class SimpleDependencyInfo
extends Object
implements DependencyInfo

A class to hold JS dependency information for a single .js file.


Constructor Summary
SimpleDependencyInfo(String srcPathRelativeToClosure, String pathOfDefiningFile, List<String> provides, List<String> requires)
          Constructs a DependencyInfo object with the given list of provides & requires.
 
Method Summary
 boolean equals(Object obj)
           
 String getName()
          Gets the unique name / path of this file.
 String getPathRelativeToClosureBase()
          Gets the path of this file relative to Closure's base.js file.
 Collection<String> getProvides()
          Gets the symbols provided by this file.
 Collection<String> getRequires()
          Gets the symbols required by this file.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleDependencyInfo

public SimpleDependencyInfo(String srcPathRelativeToClosure,
                            String pathOfDefiningFile,
                            List<String> provides,
                            List<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 String getName()
Description copied from interface: DependencyInfo
Gets the unique name / path of this file.

Specified by:
getName in interface DependencyInfo

getPathRelativeToClosureBase

public String getPathRelativeToClosureBase()
Description copied from interface: DependencyInfo
Gets the path of this file relative to Closure's base.js file.

Specified by:
getPathRelativeToClosureBase in interface DependencyInfo

getProvides

public Collection<String> getProvides()
Description copied from interface: DependencyInfo
Gets the symbols provided by this file.

Specified by:
getProvides in interface DependencyInfo

getRequires

public Collection<String> getRequires()
Description copied from interface: DependencyInfo
Gets the symbols required by this file.

Specified by:
getRequires in interface DependencyInfo

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object