public class ERXInlineTemplate extends ERXNonSynchronizingComponent
The content which would usually go into the ".html" file within a WOComponent's bundle, is specified using the "html" binding, the ".wod" part is specified by the "wod" binding.
When using WOOgnl with "ognl.helperFunctions = true" and "ognl.inlineBindings = true", you can leave out the
WOD part.
When keys are accessed, the component first determines the first element of the path (e.g. key "foo" for path
"foo.bar") and looks, if there is a binding with that key.
If there is such a binding, the value is retrieved and the rest of the keyPath applied to it
(valueForBinding("foo").valueForKeyPath("bar")).
If there is no binding with that name and "proxyParent" is true, the keyPath is resolved against the parent component.
Otherwise, dynamicBindings (ERXComponent.dynamicBindings()) are used.
You can switch off the usage of dynamicBindings by setting the binding "defaultToDynamicBindings" to false.
Then a warning will be logged for unknown keys.
When an error occurs, an error message is displayed. The message can be altered using the "errorTemplate" binding.
Optionally, a "cacheKey" (String) can be specified, under which the parsed WOElement will be cached. To allow updating, a "cacheVersion" (Object) is available. When the version changes, the value is recalculated.
| Name | Description |
|---|---|
html | HTML-part of the component (required) |
wod | WOD-part of the component (optional) |
cacheKey | Key under which to cache the WOElement (optional) |
cacheVersion | Hint to determine if the cached object is up-to-date (optional) |
errorTemplate | Template to use for displaying error messages. Uses {@link ERXSimpleTemplateParser} for display. Method name and HTML-escaped message are provided by the "method" and "message" keys. (optional) |
proxyParent | whether to proxy key path lookup to the parent (default is false) |
defaultToDynamicBindings | whether to use dynamicBindings for unknown keys (default is true) |
| Modifier and Type | Class and Description |
|---|---|
static class |
ERXInlineTemplate.Error |
com.webobjects.appserver.WOComponent._EventLoggingEnabler, com.webobjects.appserver.WOComponent.Eventcom.webobjects.foundation.NSKeyValueCodingAdditions.DefaultImplementation, com.webobjects.foundation.NSKeyValueCodingAdditions.Utilitycom.webobjects.foundation.NSKeyValueCoding._BooleanFieldBinding, com.webobjects.foundation.NSKeyValueCoding._BooleanMethodBinding, com.webobjects.foundation.NSKeyValueCoding._FieldBinding, com.webobjects.foundation.NSKeyValueCoding._ForwardingBinding, com.webobjects.foundation.NSKeyValueCoding._KeyBinding, com.webobjects.foundation.NSKeyValueCoding._KeyBindingCreation, com.webobjects.foundation.NSKeyValueCoding._MethodBinding, com.webobjects.foundation.NSKeyValueCoding._NumberFieldBinding, com.webobjects.foundation.NSKeyValueCoding._NumberMethodBinding, com.webobjects.foundation.NSKeyValueCoding._ReflectionKeyBindingCreation, com.webobjects.foundation.NSKeyValueCoding.ErrorHandling, com.webobjects.foundation.NSKeyValueCoding.MapImplementation, com.webobjects.foundation.NSKeyValueCoding.Null<T>, com.webobjects.foundation.NSKeyValueCoding.UnknownKeyException, com.webobjects.foundation.NSKeyValueCoding.ValueAccessorcom.webobjects.foundation.NSValidation._MethodBinding, com.webobjects.foundation.NSValidation._ValidationBinding, com.webobjects.foundation.NSValidation.DefaultImplementation, com.webobjects.foundation.NSValidation.Utility, com.webobjects.foundation.NSValidation.ValidationException| Modifier and Type | Field and Description |
|---|---|
protected ERXInlineTemplate.Error |
_deferredError |
_dynamicBindings_Extension, _IsEventLoggingEnabled, _keyAssociations| Constructor and Description |
|---|
ERXInlineTemplate(com.webobjects.appserver.WOContext context) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendToResponse(com.webobjects.appserver.WOResponse woresponse,
com.webobjects.appserver.WOContext wocontext)
Calls
ERXNonSynchronizingComponent.resetCachedBindingsInStatefulComponent() prior to super.appendToResponse. |
boolean |
defaultToDynamicBindings() |
String |
errorTemplate() |
boolean |
proxyParent() |
void |
takeValueForKey(Object obj,
String s) |
void |
takeValueForKeyPath(Object value,
String keyPath) |
com.webobjects.appserver.WOElement |
template() |
Object |
valueForKey(String s) |
Object |
valueForKeyPath(String keyPath) |
invokeAction, resetCachedBindingsInStatefulComponent, synchronizesVariablesWithBindings, takeValuesFromRequest_awakeInContext, _checkAccess, _frameworkName, _includeCSSResources, _includeJavascriptResources, additionalCSSFiles, additionalJavascriptFiles, arrayValueForBinding, arrayValueForBinding, booleanValueForBinding, booleanValueForBinding, booleanValueForBinding, browser, checkAccess, clickToOpenEnabled, componentName, defaultCSSPath, defaultJavascriptPath, dynamicBindings, floatValueForBinding, intValueForBinding, isPageAccessAllowed, localizer, objectValueForBinding, objectValueForBinding, pageWithName, postAppendToResponse, preAppendToResponse, primaryCSSFile, primaryJavascriptFile, reset, shouldCheckAccess, stringValueForBinding, stringValueForBinding, useDefaultComponentCSS, useDefaultComponentJavascript__valueForBinding, _associationWithName, _childTemplate, _cleanUpStatelessComponent, _componentDefinition, _componentUnroll, _isPage, _setContext, _setIsPage, _setParent, _setSubcomponent, _sleepInContext, _subcomponentForElementWithID, _templateNameForClass, _unroll, application, awake, baseURL, bindingKeys, canAccessFieldsDirectly, canGetValueForBinding, canSetValueForBinding, clone, context, debugString, descriptionForResponse, ensureAwakeInContext, frameworkName, generateResponse, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hasBinding, hasSession, isCachingEnabled, isEventLoggingEnabled, isStateless, logString, name, pageWithName, parent, path, pathURL, performParentAction, pullValuesFromParent, pushValuesToParent, session, set_componentUnroll, set_unroll, setCachingEnabled, setValueForBinding, setVariableValueForName, sleep, templateWithHTMLString, templateWithHTMLString, templateWithHTMLString, templateWithName, toString, unableToSetNullForKey, validateTakeValueForKeyPath, validateValueForKey, validationFailedWithException, valueForBinding, valueForBooleanBinding, valueForIntegerBinding, valueForNSArrayBindings, valueForNSDictionaryBindings, valueForNumberBinding, valueForStringBinding, variableValueForName, variableWithNameprotected ERXInlineTemplate.Error _deferredError
public ERXInlineTemplate(com.webobjects.appserver.WOContext context)
public void appendToResponse(com.webobjects.appserver.WOResponse woresponse,
com.webobjects.appserver.WOContext wocontext)
ERXNonSynchronizingComponentERXNonSynchronizingComponent.resetCachedBindingsInStatefulComponent() prior to super.appendToResponse.appendToResponse in class ERXNonSynchronizingComponentworesponse - to which we are appendingwocontext - context of the responsepublic String errorTemplate()
public boolean proxyParent()
public boolean defaultToDynamicBindings()
public void takeValueForKeyPath(Object value, String keyPath)
takeValueForKeyPath in interface com.webobjects.foundation.NSKeyValueCodingAdditionstakeValueForKeyPath in class com.webobjects.appserver.WOComponentpublic Object valueForKeyPath(String keyPath)
valueForKeyPath in interface com.webobjects.foundation.NSKeyValueCodingAdditionsvalueForKeyPath in class com.webobjects.appserver.WOComponentpublic void takeValueForKey(Object obj, String s)
takeValueForKey in interface com.webobjects.foundation.NSKeyValueCodingtakeValueForKey in class com.webobjects.appserver.WOComponentpublic Object valueForKey(String s)
valueForKey in interface com.webobjects.foundation.NSKeyValueCodingvalueForKey in class com.webobjects.appserver.WOComponentpublic com.webobjects.appserver.WOElement template()
template in class com.webobjects.appserver.WOComponentCopyright © 2002 – 2020 Project Wonder.