Class JavaScriptBuilderElementBuilder
java.lang.Object
fiftyone.pipeline.javascriptbuilder.flowelements.JavaScriptBuilderElementBuilder
Builder for the
JavaScriptBuilderElement-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionJavaScriptBuilderElementBuilder(org.slf4j.ILoggerFactory loggerFactory) Construct a new instance. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Build theJavaScriptBuilderElementsetContextRoot(String contextRoot) Set the evidence value for the context rootsetEnableCookies(boolean enableCookies) Set whether the client JavaScript stores results of client side processing in cookies.setEndpoint(String endpoint) Set the endpoint which will be queried on the host.Set the host that the client JavaScript should query for updates.setObjectName(String objName) The default name of the object instantiated by the client JavaScript.setProtocol(String protocol) The protocol that the client JavaScript will use when querying for updates.
-
Field Details
-
ENABLE_COOKIES
public static final boolean ENABLE_COOKIES- See Also:
-
host
-
endpoint
-
protocol
-
contextRoot
-
objName
-
-
Constructor Details
-
JavaScriptBuilderElementBuilder
public JavaScriptBuilderElementBuilder(org.slf4j.ILoggerFactory loggerFactory) Construct a new instance.- Parameters:
loggerFactory- theILoggerFactoryto use when creating loggers for the element
-
-
Method Details
-
setHost
@DefaultValue("The host from the request") public JavaScriptBuilderElementBuilder setHost(String host) Set the host that the client JavaScript should query for updates.By default, the host from the request will be used.
- Parameters:
host- the hostname- Returns:
- this builder
-
setEndpoint
Set the endpoint which will be queried on the host. e.g /api/v4/jsonBy default, this value is an empty string
- Parameters:
endpoint- the endpoint- Returns:
- this builder
-
setContextRoot
@DefaultValue("Value from evidence server.contextroot") public JavaScriptBuilderElementBuilder setContextRoot(String contextRoot) Set the evidence value for the context rootDefault is value from evidence "server.contextroot"
- Parameters:
contextRoot-- Returns:
- this builder
-
setProtocol
@DefaultValue("The protocol from the request") public JavaScriptBuilderElementBuilder setProtocol(String protocol) The protocol that the client JavaScript will use when querying for updates.By default, the protocol from the request will be used.
- Parameters:
protocol- The protocol to use (http / https)- Returns:
- this builder
-
setObjectName
The default name of the object instantiated by the client JavaScript.Default is "fod"
- Parameters:
objName- the object name to use- Returns:
- this builder
-
setEnableCookies
@DefaultValue(booleanValue=true) public JavaScriptBuilderElementBuilder setEnableCookies(boolean enableCookies) Set whether the client JavaScript stores results of client side processing in cookies. If set to false, the JavaScript will not populate any cookies, and will instead use session storage.This can also be set per request, using the "query.fod-js-enable-cookies" evidence key. For more details on personal data policy, see http://51degrees.com/terms/client-services-privacy-policy/
Default is true
- Parameters:
enableCookies- should enable cookies?- Returns:
- this builder
-
build
Build theJavaScriptBuilderElement- Returns:
- new
JavaScriptBuilderElementinstance
-