|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.google.template.soy.tofu.SoyTofuOptions
public class SoyTofuOptions
Compilation options for the Tofu backend.
| Constructor Summary | |
|---|---|
SoyTofuOptions()
|
|
| Method Summary | |
|---|---|
SoyTofuOptions |
clone()
|
void |
setUseCaching(boolean useCaching)
Sets whether the resulting SoyTofu instance should cache intermediate results after substitutions from the SoyMsgBundle and the SoyCssRenamingMap. |
boolean |
useCaching()
Returns whether the resulting SoyTofu instance should cache intermediate results after substitutions from the SoyMsgBundle and the SoyCssRenamingMap. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SoyTofuOptions()
| Method Detail |
|---|
public void setUseCaching(boolean useCaching)
Specifically, if this param is set to true, then
(a) The first time the SoyTofu is used with a new combination of SoyMsgBundle and
SoyCssRenamingMap, the render will be slower. (Note that this first-render slowness can
be eliminated by calling the method SoyTofu.addToCache(com.google.template.soy.msgs.SoyMsgBundle, com.google.template.soy.shared.SoyCssRenamingMap) to prime the cache.)
(b) The subsequent times the SoyTofu is used with an already-seen combination of
SoyMsgBundle and SoyCssRenamingMap, the render will be faster.
The cache will use memory proportional to the number of distinct combinations of
SoyMsgBundle and SoyCssRenamingMap your app uses (note most apps have at most one
SoyCssRenamingMap). If you find memory usage to be a problem, you can manually control the
contents of the cache. See SoyTofu.Renderer.setDontAddToCache(boolean) for details.
useCaching - The value to set.public boolean useCaching()
public SoyTofuOptions clone()
clone in class Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||