public final class JsfResourceUtils
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static java.net.URL |
addResourceToProject(java.net.URL resourceURL,
Context context,
java.lang.String promptMessage,
java.lang.String promptDialogTitle,
java.lang.String saveDialogTitle,
java.lang.String defaultLibrary) |
static java.net.URL |
addResourceToProject(java.net.URL resourceURL,
Context context,
java.lang.String promptMessage,
java.lang.String promptDialogTitle,
java.lang.String saveDialogTitle,
java.lang.String defaultLibrary,
boolean toMetaInf) |
static java.net.URL |
chooseResource(boolean forceResourceURL,
URLFilter resourceFilter,
Context context,
java.lang.String selectDialogTitle,
java.lang.String defaultLibrary)
Lets user choose a resource.
|
static java.net.URL |
chooseResource(boolean forceResourceURL,
URLFilter resourceFilter,
Context context,
java.lang.String promptMessage,
java.lang.String promptDialogTitle,
java.lang.String saveDialogTitle,
java.lang.String selectDialogTitle,
java.lang.String defaultLibrary)
Lets user choose a resource
|
static java.net.URL |
getResourceLibrary(Context context,
java.lang.String library) |
static java.lang.String |
getResourceLibrary(Context context,
java.net.URL url) |
static URLChooser |
getResourceLibraryURLChooser(Context context) |
static URLChooser |
getResourceURLChooser(Context context,
URLFilter resourceFilter,
java.lang.String defaultLibrary,
boolean chooseOnlyExisting) |
static boolean |
isLibraryVersion(java.net.URL url) |
static boolean |
isResourceLibrary(Context context,
java.net.URL url) |
static boolean |
isResourceLibrary(java.net.URL jsfResourcesRoot,
java.net.URL url) |
static boolean |
isResourceURL(java.net.URL url,
java.lang.String[] resourceExtensions) |
static boolean |
isResourceVersion(java.net.URL url,
java.lang.String[] resourceExtensions) |
public static java.net.URL addResourceToProject(java.net.URL resourceURL, Context context, java.lang.String promptMessage, java.lang.String promptDialogTitle, java.lang.String saveDialogTitle, java.lang.String defaultLibrary)
public static java.net.URL addResourceToProject(java.net.URL resourceURL, Context context, java.lang.String promptMessage, java.lang.String promptDialogTitle, java.lang.String saveDialogTitle, java.lang.String defaultLibrary, boolean toMetaInf)
public static java.net.URL chooseResource(boolean forceResourceURL, URLFilter resourceFilter, Context context, java.lang.String selectDialogTitle, java.lang.String defaultLibrary)
forceResourceURL
- Set to true if user must choose a file under "resources" folder,
or save the selected file under "resources" folder.context
- selectDialogTitle
- Title of the "select resource" dialog.defaultLibrary
- Name of the default library to search resource at, and save the resource to.public static java.net.URL chooseResource(boolean forceResourceURL, URLFilter resourceFilter, Context context, java.lang.String promptMessage, java.lang.String promptDialogTitle, java.lang.String saveDialogTitle, java.lang.String selectDialogTitle, java.lang.String defaultLibrary)
forceResourceURL
- Set to true if user must choose a file under "resources" folder,
or save the selected file under "resources" folder.context
- promptMessage
- Message to prompt user when saving the file under resources "resources" folder.promptDialogTitle
- Title of the resource location warning prompt.selectDialogTitle
- Title of the "select resource" dialog.saveDialogTitle
- Title of the "save resource" dialog.defaultLibrary
- Name of the default library to search resource at, and save the resource to.public static URLChooser getResourceURLChooser(Context context, URLFilter resourceFilter, java.lang.String defaultLibrary, boolean chooseOnlyExisting)
context
- resourceFilter
- chooseOnlyExisting
- public static URLChooser getResourceLibraryURLChooser(Context context)
public static java.lang.String getResourceLibrary(Context context, java.net.URL url)
public static boolean isResourceLibrary(Context context, java.net.URL url)
public static boolean isResourceLibrary(java.net.URL jsfResourcesRoot, java.net.URL url)
public static java.net.URL getResourceLibrary(Context context, java.lang.String library)
public static boolean isResourceURL(java.net.URL url, java.lang.String[] resourceExtensions)
public static boolean isLibraryVersion(java.net.URL url)
public static boolean isResourceVersion(java.net.URL url, java.lang.String[] resourceExtensions)