Package com.atlassian.gadgets
Class GadgetRequestContext.Builder
java.lang.Object
com.atlassian.gadgets.GadgetRequestContext.Builder
- Enclosing class:
- GadgetRequestContext
A builder that facilitates construction of
GadgetRequestContext objects. The final GadgetRequestContext
is created by calling the build() method-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Returns the final constructedGadgetRequestContext.debug(boolean debug) Sets whether debugging should be enabled when rendering the gadget.static GadgetRequestContext.BuilderGet a new GadgetRequestContext Builder.ignoreCache(boolean ignoreCache) Set the cache setting of theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.Set theLocaleof theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.Sets the current user.Set the current view of theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
gadgetRequestContext
Get a new GadgetRequestContext Builder.- Returns:
- the new builder
-
build
Returns the final constructedGadgetRequestContext.- Returns:
- the
GadgetRequestContext
-
locale
Set theLocaleof theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.- Parameters:
locale- theLocaleto use for theGadgetRequestContext- Returns:
- this builder to allow for further construction
-
ignoreCache
Set the cache setting of theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.- Parameters:
ignoreCache- the cache setting of thisGadgetRequestContext- Returns:
- this builder to allow for further construction
-
view
Set the current view of theGadgetRequestContextunder construction and return thisBuilderto allow further construction to be done.- Parameters:
view- view in which the dashboard item is rendering- Returns:
- this builder to allow for further construction
-
user
Sets the current user.- Parameters:
user- the current user.- Returns:
- this builder to allow for further construction.
-
debug
Sets whether debugging should be enabled when rendering the gadget. When debugging is enabled, the JavaScript for the features used by the gadget will be served in non-minimized, making it easier to debug.- Parameters:
debug- enable or disable debugging- Returns:
- this builder to allow for further construction
-