public class ModuleLibraryOrderEntryImpl extends java.lang.Object implements LibraryOrderEntry, ClonableOrderEntry
OrderEntryUtil.isModuleLibraryOrderEntry(OrderEntry)
to check whether an
entry corresponds to a module-level library.Disposable.Parent
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ENTRY_TYPE |
protected DependencyScope |
myScope |
EMPTY_ARRAY
Modifier and Type | Method and Description |
---|---|
<R> R |
accept(RootPolicy<R> policy,
R initialValue)
Accepts the specified order entries visitor.
|
OrderEntry |
cloneEntry(ModifiableRootModel rootModel,
ProjectRootManagerImpl projectRootManager,
VirtualFilePointerManager filePointerManager) |
int |
compareTo(OrderEntry orderEntry) |
void |
dispose()
Usually not invoked directly, see class javadoc.
|
boolean |
equals(java.lang.Object obj) |
VirtualFile [] |
getFiles(OrderRootType type)
Returns list of root
VirtualFile s of given type for this entry. |
Library |
getLibrary() |
java.lang.String |
getLibraryLevel() |
java.lang.String |
getLibraryName() |
Module |
getOwnerModule()
Returns the module to which the entry belongs.
|
java.lang.String |
getPresentableName()
Returns the user-visible name of this OrderEntry.
|
VirtualFile [] |
getRootFiles(OrderRootType type) |
RootModelImpl |
getRootModel() |
protected RootProvider |
getRootProvider() |
java.lang.String [] |
getRootUrls(OrderRootType type) |
DependencyScope |
getScope() |
java.lang.String [] |
getUrls(OrderRootType type)
Returns list of roots of given type for this entry.
|
int |
hashCode() |
protected void |
init() |
boolean |
isDisposed() |
boolean |
isExported() |
boolean |
isModuleLevel() |
boolean |
isSynthetic() |
boolean |
isValid()
Checks whether this order entry is invalid for some reason.
|
void |
setExported(boolean value) |
void |
setScope(DependencyScope scope) |
java.lang.String |
toString() |
void |
writeExternal(Element rootElement) |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getRootFiles, getRootUrls
getFiles, getOwnerModule, getUrls
public static final java.lang.String ENTRY_TYPE
protected DependencyScope myScope
protected RootProvider getRootProvider()
public Library getLibrary()
getLibrary
in interface LibraryOrderEntry
public boolean isModuleLevel()
isModuleLevel
in interface LibraryOrderEntry
public java.lang.String getLibraryName()
getLibraryName
in interface LibraryOrderEntry
public java.lang.String getLibraryLevel()
getLibraryLevel
in interface LibraryOrderEntry
public java.lang.String getPresentableName()
OrderEntry
getPresentableName
in interface OrderEntry
public boolean isValid()
OrderEntry
isValid
in interface OrderEntry
public <R> R accept(RootPolicy<R> policy, R initialValue)
OrderEntry
accept
in interface OrderEntry
policy
- the visitor to accept.initialValue
- the default value to be returned by the visit process.public boolean isSynthetic()
isSynthetic
in interface Synthetic
public OrderEntry cloneEntry(ModifiableRootModel rootModel, ProjectRootManagerImpl projectRootManager, VirtualFilePointerManager filePointerManager)
cloneEntry
in interface ClonableOrderEntry
public void writeExternal(Element rootElement) throws WriteExternalException
WriteExternalException
public boolean isExported()
isExported
in interface ExportableOrderEntry
public void setExported(boolean value)
setExported
in interface ExportableOrderEntry
public DependencyScope getScope()
getScope
in interface ExportableOrderEntry
public void setScope(DependencyScope scope)
setScope
in interface ExportableOrderEntry
protected final void init()
public VirtualFile [] getFiles(OrderRootType type)
OrderEntry
VirtualFile
s of given type for this entry.
Those files should be traversed in order they are returned in.
Note that actual OrderEntry (as seen in UI) may also contain invalid roots.
If you want to get list of all roots, use OrderEntry.getUrls(OrderRootType)
method. getFiles
in interface OrderEntry
type
- required root type.OrderEntry.getUrls(OrderRootType)
public java.lang.String [] getUrls(OrderRootType type)
OrderEntry
VirtualFileManager.findFileByUrl(String)
getUrls
in interface OrderEntry
type
- the type of roots which should be returned.public VirtualFile [] getRootFiles(OrderRootType type)
getRootFiles
in interface LibraryOrSdkOrderEntry
public java.lang.String [] getRootUrls(OrderRootType type)
getRootUrls
in interface LibraryOrSdkOrderEntry
public final Module getOwnerModule()
OrderEntry
getOwnerModule
in interface OrderEntry
public void dispose()
Disposable
dispose
in interface Disposable
public int compareTo(OrderEntry orderEntry)
compareTo
in interface java.lang.Comparable<OrderEntry>
public final boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public final int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public RootModelImpl getRootModel()
public boolean isDisposed()