|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.bowstreet.builders.webapp.ImportedPageBuilder
public class ImportedPageBuilder
ImportedPage WebApp builder.
Nested Class Summary | |
---|---|
static interface |
ImportedPageBuilder.STATICS
|
Field Summary | |
---|---|
static java.lang.String |
ABSOLUTE_CONTENT_URL_PARM
|
static java.lang.String |
CONTEXT_PATH_PARM
|
static java.lang.String |
FORM_METHOD_ATTRIBUTE
|
static java.lang.String |
FULLY_PARSE_PARM
|
static java.lang.String |
INPUT_LOCALIZEURL
|
static java.lang.String |
INPUT_URL
|
Constructor Summary | |
---|---|
ImportedPageBuilder()
|
Method Summary | |
---|---|
void |
doBuilderCall(GenContext genContext,
WebApp webApp,
BuilderCall builderCall,
BuilderInputs builderInputs)
doBuilderCall - WebApp builders do their regen work here, getting inputs from builderInputs and adding/modifying elements in the WebApp. |
static void |
doWork(GenContext genContext,
WebApp webApp,
BuilderCall builderCall,
BuilderInputs builderInputs)
Do the actual work for the ImportedPage builder's doBuilderCall method. |
static java.lang.String |
getApplicationContextPath(GenContext genContext)
Get the current servlet application context - will return null if called at design time. |
static java.util.List |
getDependencies()
Get the list of dependencies. |
static java.lang.String |
getServerURL(GenContext genContext)
Calculate a reasonable server URL if possible. |
static java.lang.String |
getServerURL(GenContext genContext,
boolean omitAppContext,
boolean absoluteURLs)
Calculate a reasonable server URL if possible. |
static boolean |
getUseURLMapperForContextURL()
Determine if we should use simple code (request.getContextPath()) to compute the context URL, or if we have to use the URLMapper machinery. |
static java.lang.String |
getValidEncodingForJSP(java.lang.String encoding)
Is this character encoding one that can be used for writing JSPs? |
static IXml |
importPage(java.lang.String url,
java.lang.String serverURL,
boolean absoluteURLs,
boolean omitAppContext,
boolean useCode,
boolean addBase,
boolean parseFully,
java.lang.String userName,
java.lang.String password,
java.lang.Object linkProcessor,
java.lang.String encoding,
java.util.List dependencies)
Fetch the specified page data. |
static IXml |
importPage(java.lang.String url,
java.lang.String serverURL,
java.lang.String appContext,
boolean modifyURLs,
boolean absoluteURLs,
boolean omitAppContext,
boolean useCode,
boolean addBase,
boolean parseFully,
java.lang.String userName,
java.lang.String password,
java.lang.Object linkProcessor,
java.lang.String encoding,
java.util.List dependencies)
Fetch the specified page data. |
static IXml |
importPage(java.lang.String url,
java.lang.String serverURL,
java.lang.String appContext,
boolean absoluteURLs,
boolean omitAppContext,
boolean useCode,
boolean addBase,
boolean parseFully,
java.lang.String userName,
java.lang.String password,
java.lang.Object linkProcessor,
java.lang.String encoding,
java.util.List dependencies)
Fetch the specified page data. |
java.lang.Object |
newInstance()
IExemplar implementation |
static java.lang.String |
prepareUrl(java.lang.String base,
java.lang.String localePath,
java.lang.String url)
Create an import URL that doesn't contain duplicate path separators. |
static void |
reparseNodeFully(IXml node)
The normal process to parse some HTML is to partially parse some of it, putting pieces we don't think are "important" inside HTMLContent nodes with CDATA wrappers. |
static void |
setDependencies(java.util.List dependencies)
Called to set a list of files the imported HTML refers to. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ABSOLUTE_CONTENT_URL_PARM
public static final java.lang.String CONTEXT_PATH_PARM
public static final java.lang.String FORM_METHOD_ATTRIBUTE
public static final java.lang.String FULLY_PARSE_PARM
public static final java.lang.String INPUT_LOCALIZEURL
public static final java.lang.String INPUT_URL
Constructor Detail |
---|
public ImportedPageBuilder()
Method Detail |
---|
public void doBuilderCall(GenContext genContext, WebApp webApp, BuilderCall builderCall, BuilderInputs builderInputs)
doBuilderCall
in interface WebAppBuilder
genContext
- The GenContext for this regenwebApp
- The WebApp under constructionbuilderCall
- Use this to set errors, get BuilderDef, etc.builderInputs
- The inputs for this builder callpublic static void doWork(GenContext genContext, WebApp webApp, BuilderCall builderCall, BuilderInputs builderInputs)
genContext
- The GenContext for this regenwebApp
- The WebApp under constructionbuilderCall
- Use this to set errors, get BuilderDef, etc.builderInputs
- The inputs for this builder callpublic static java.lang.String getApplicationContextPath(GenContext genContext)
public static java.util.List getDependencies()
public static java.lang.String getServerURL(GenContext genContext)
public static java.lang.String getServerURL(GenContext genContext, boolean omitAppContext, boolean absoluteURLs)
public static boolean getUseURLMapperForContextURL()
public static java.lang.String getValidEncodingForJSP(java.lang.String encoding)
public static IXml importPage(java.lang.String url, java.lang.String serverURL, boolean absoluteURLs, boolean omitAppContext, boolean useCode, boolean addBase, boolean parseFully, java.lang.String userName, java.lang.String password, java.lang.Object linkProcessor, java.lang.String encoding, java.util.List dependencies) throws java.lang.Exception
url
- urlserverURL
- server urlabsoluteURLs
- boolean specifying whether to use absolute urls (true) or relative (false)omitAppContext
- boolean specifying whether to omit the app contextuseCode
- boolean specifying whether to use JSP code to generate URLsaddBase
- boolean specifying whether to add a base URL to the pageparseFully
- boolean specifying whether to fully parse the pageuserName
- username for accessing HTTP basic-auth protected pages.password
- password for accessing HTTP basic-auth protected pages.linkProcessor
- link processor (not typically used, pass null instead).encoding
- encoding for the specified pagedependencies
- list of dependencies
java.lang.Exception
public static IXml importPage(java.lang.String url, java.lang.String serverURL, java.lang.String appContext, boolean modifyURLs, boolean absoluteURLs, boolean omitAppContext, boolean useCode, boolean addBase, boolean parseFully, java.lang.String userName, java.lang.String password, java.lang.Object linkProcessor, java.lang.String encoding, java.util.List dependencies) throws java.lang.Exception
url
- urlserverURL
- server urlappContext
- application contextmodifyURLs
- boolean specifying whether to modify URLs found in the page dataabsoluteURLs
- boolean specifying whether to use absolute urls (true) or relative (false)omitAppContext
- boolean specifying whether to omit the app contextuseCode
- boolean specifying whether to use JSP code to generate URLsaddBase
- boolean specifying whether to add a base URL to the pageparseFully
- boolean specifying whether to fully parse the pageuserName
- username for accessing HTTP basic-auth protected pages.password
- password for accessing HTTP basic-auth protected pages.linkProcessor
- link processor (not typically used, pass null instead).encoding
- encoding for the specified pagedependencies
- list of dependencies
java.lang.Exception
public static IXml importPage(java.lang.String url, java.lang.String serverURL, java.lang.String appContext, boolean absoluteURLs, boolean omitAppContext, boolean useCode, boolean addBase, boolean parseFully, java.lang.String userName, java.lang.String password, java.lang.Object linkProcessor, java.lang.String encoding, java.util.List dependencies) throws java.lang.Exception
url
- urlserverURL
- server urlappContext
- application contextabsoluteURLs
- boolean specifying whether to use absolute urls (true) or relative (false)omitAppContext
- boolean specifying whether to omit the app contextuseCode
- boolean specifying whether to use JSP code to generate URLsaddBase
- boolean specifying whether to add a base URL to the pageparseFully
- boolean specifying whether to fully parse the pageuserName
- username for accessing HTTP basic-auth protected pages.password
- password for accessing HTTP basic-auth protected pages.linkProcessor
- link processor (not typically used, pass null instead).encoding
- encoding for the specified pagedependencies
- list of dependencies
java.lang.Exception
public java.lang.Object newInstance()
newInstance
in interface IExemplar
public static java.lang.String prepareUrl(java.lang.String base, java.lang.String localePath, java.lang.String url)
base
- base url stringlocalePath
- locale pathurl
- url pathpublic static void reparseNodeFully(IXml node) throws com.bowstreet.util.parser.ParserException
node
- IXml portion of a page which you want to be fully parsed.
com.bowstreet.util.parser.ParserException
public static void setDependencies(java.util.List dependencies)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |