Package org.apache.wicket.util.diff
Class DeleteDelta
- java.lang.Object
-
- org.apache.wicket.util.diff.ToString
-
- org.apache.wicket.util.diff.Delta
-
- org.apache.wicket.util.diff.DeleteDelta
-
public class DeleteDelta extends Delta
Holds a delete-delta between to revisions of a text.- Version:
- $Id: DeleteDelta.java,v 1.1 2006/03/12 00:24:21 juanca Exp $
- Author:
- Juanco Anez
- See Also:
Delta,Diff,Chunk
-
-
Constructor Summary
Constructors Constructor Description DeleteDelta(Chunk orig)Construct.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(RevisionVisitor visitor)Accepts a visitor.voidapplyTo(java.util.List<java.lang.Object> target)Applies this delta as a patch to the given text.voidtoRCSString(java.lang.StringBuilder s, java.lang.String EOL)Converts this delta into its RCS style string representation.voidtoString(java.lang.StringBuilder s)Converts this delta into its Unix diff style string representation.voidverify(java.util.List<java.lang.Object> target)Verifies that this delta can be used to patch the given text.-
Methods inherited from class org.apache.wicket.util.diff.Delta
getOriginal, getRevised, init, newDelta, patch, toRCSString
-
Methods inherited from class org.apache.wicket.util.diff.ToString
arrayToString, arrayToString, stringToArray, toString
-
-
-
-
Constructor Detail
-
DeleteDelta
public DeleteDelta(Chunk orig)
Construct.- Parameters:
orig-
-
-
Method Detail
-
verify
public void verify(java.util.List<java.lang.Object> target) throws PatchFailedExceptionDescription copied from class:DeltaVerifies that this delta can be used to patch the given text.- Specified by:
verifyin classDelta- Parameters:
target- the text to patch.- Throws:
PatchFailedException- if the patch cannot be applied.- See Also:
Delta.verify(java.util.List)
-
applyTo
public void applyTo(java.util.List<java.lang.Object> target)
Description copied from class:DeltaApplies this delta as a patch to the given text.- Specified by:
applyToin classDelta- Parameters:
target- the text to patch.- See Also:
Delta.applyTo(java.util.List)
-
toString
public void toString(java.lang.StringBuilder s)
Description copied from class:DeltaConverts this delta into its Unix diff style string representation.- Overrides:
toStringin classDelta- Parameters:
s- aStringBufferto which the string representation will be appended.- See Also:
Delta.toString(java.lang.StringBuilder)
-
toRCSString
public void toRCSString(java.lang.StringBuilder s, java.lang.String EOL)Description copied from class:DeltaConverts this delta into its RCS style string representation.- Specified by:
toRCSStringin classDelta- Parameters:
s- aStringBufferto which the string representation will be appended.EOL- the string to use as line separator.- See Also:
Delta.toRCSString(java.lang.StringBuilder, java.lang.String)
-
accept
public void accept(RevisionVisitor visitor)
Description copied from class:DeltaAccepts a visitor.See the Visitor pattern in "Design Patterns" by the GOF4.
- Specified by:
acceptin classDelta- Parameters:
visitor- The visitor.- See Also:
Delta.accept(org.apache.wicket.util.diff.RevisionVisitor)
-
-