Class AutoSave
- java.lang.Object
 - 
- org.apache.jackrabbit.vault.fs.io.AutoSave
 
 
- 
public class AutoSave extends java.lang.ObjectAutoSave... 
- 
- 
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description AutoSavecopy()intgetThreshold()Returns the thresholdbooleanisDryRun()voidmarkMissing(@NotNull java.lang.String path)Deprecated.voidmarkResolved(@NotNull java.lang.String path)Deprecated.booleanmodified(int num)AddsnummodifiedbooleanneedsSave()Returnstrueif more thangetThreshold()nodes are modified.voidsave(@Nullable javax.jcr.Session session)Same assave(Session, boolean)with the second argument beingtrue.voidsave(@Nullable javax.jcr.Session session, boolean isIntermediate)Saves the changes under the given node and resets the counter.voidsetDebugFailEach(int debugFailEach)Debug settings to allows to produce failures after eachdebugFailEachsave.voidsetDryRun(boolean dryRun)voidsetThreshold(int threshold)Sets the thresholdvoidsetTracker(@Nullable ProgressTracker tracker)java.lang.StringtoString() 
 - 
 
- 
- 
Method Detail
- 
copy
public AutoSave copy()
 
- 
setTracker
public void setTracker(@Nullable @Nullable ProgressTracker tracker) 
- 
isDryRun
public boolean isDryRun()
 
- 
setDryRun
public void setDryRun(boolean dryRun)
 
- 
setDebugFailEach
public void setDebugFailEach(int debugFailEach)
Debug settings to allows to produce failures after eachdebugFailEachsave.- Parameters:
 debugFailEach- cardinal indicating when to fail
 
- 
needsSave
public boolean needsSave()
Returnstrueif more thangetThreshold()nodes are modified.- Returns:
 trueif threshold reached.
 
- 
save
public void save(@Nullable @Nullable javax.jcr.Session session) throws javax.jcr.RepositoryExceptionSame assave(Session, boolean)with the second argument beingtrue.- Parameters:
 session-- Throws:
 javax.jcr.RepositoryException
 
- 
save
public void save(@Nullable @Nullable javax.jcr.Session session, boolean isIntermediate) throws javax.jcr.RepositoryExceptionSaves the changes under the given node and resets the counter.- Parameters:
 session- the session to save. can benullisIntermediate-falsewhen this is the final attempt, otherwisetrue.- Throws:
 javax.jcr.RepositoryException- if an error occurs.
 
- 
getThreshold
public int getThreshold()
Returns the threshold- Returns:
 - the threshold
 
 
- 
setThreshold
public void setThreshold(int threshold)
Sets the threshold- Parameters:
 threshold- the threshold
 
- 
modified
public boolean modified(int num)
Addsnummodified- Parameters:
 num- number of modified- Returns:
 trueif threshold is reached
 
- 
markMissing
@Deprecated public void markMissing(@NotNull @NotNull java.lang.String path)Deprecated.As not working reliably it is simply ignored.- Parameters:
 path-
 
- 
markResolved
@Deprecated public void markResolved(@NotNull @NotNull java.lang.String path)Deprecated.As not working reliably it is simply ignored.- Parameters:
 path-
 
- 
toString
public java.lang.String toString()
- Overrides:
 toStringin classjava.lang.Object
 
 - 
 
 -