java.lang.Object | |
↳ | com.microstrategy.utils.CustomizationInfo |
This class represents the customization information within a Customization folder.
It provides methods to identify if a file is customized, if a resource (i.e. a file within the classpath)
is customized, and a ClassLoader
that loads only those classes/resources
inside its folder.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
CustomizationInfo(String name, String rootFolderPath)
Base Constructor.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
URL |
findResource(String resourceName)
Returns the URL for a given resource.
| ||||||||||
ClassLoader |
getClassLoader()
Returns a
ClassLoader that loads classes/resources only within
this customization WEB-INF/classes subfolder, and jar files inside
WEB-INF/lib subfolder. | ||||||||||
String |
getCustomPath(String appRelativePath)
Returns the path that the given file would have within this customization folder.
| ||||||||||
String |
getName()
The name of this customization instance.
| ||||||||||
String |
getPath()
The absolute path to the root folder of this customization.
| ||||||||||
boolean |
isFileCustomized(String appRelativePath)
Returns
true if a file with the given relative
path exists inside this customization. | ||||||||||
boolean |
isResourceCustomized(String resourceName)
Returns
true if a file with the given name exists
inside this customization's WEB-INF/classes folder or within one of the
jar files inside its WEB-INF/lib folder. | ||||||||||
String | toString() |
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String[] |
getJarFiles()
Returns an array with the names of all jar files inside the
WEB-INF/lib subfolder. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Base Constructor. Creates a new instance.
name | The name to assign to the new instance. Mainly for information purpose. |
---|---|
rootFolderPath | The root folder where the files of the customization are to be found. |
Returns the URL for a given resource. If the resource is not found, it returns null.
Returns a ClassLoader
that loads classes/resources only within
this customization WEB-INF/classes
subfolder, and jar files inside
WEB-INF/lib
subfolder.
Returns the path that the given file would have within this customization folder.
This method will return the path relative to the application's root folder, without
checking if the specified path exists or is valid.
appRelativePath
is always assumed to be relative to the
application's root folder, for example: "/jsp/mstrWeb.jsp"
The name of this customization instance. Mainly for information purpose.
The absolute path to the root folder of this customization.
Returns true
if a file with the given relative
path exists inside this customization. appRelativePath
is always assumed to be relative to the
application's root folder, for example:
"/jsp/mstrWeb.jsp"
Returns true
if a file with the given name exists
inside this customization's WEB-INF/classes
folder or within one of the
jar files inside its WEB-INF/lib
folder.
Returns an array with the names of all jar files inside the WEB-INF/lib
subfolder.