Back to index

plone3  3.1.7
Public Member Functions | Static Public Attributes
CMFDiffTool.interfaces.IStringDifference Class Reference
Inheritance diagram for CMFDiffTool.interfaces.IStringDifference:
Inheritance graph
[legend]
Collaboration diagram for CMFDiffTool.interfaces.IStringDifference:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def getLineDiffs
def testChanges
def applyChanges

Static Public Attributes

tuple meta_type = Attribute('title', 'A human readable name for the diff type')
tuple field = Attribute('field', 'The name of the field being compared')
tuple same = Attribute('same', 'True if the fields are the "same" (whatever that means for this difference)')
tuple oldValue = Attribute('oldValue', 'The old field value being compared')
tuple newValue = Attribute('newValue', 'The new field value being compared')

Detailed Description

An anterface for interacting with the difference between two
string (text) objects

Definition at line 62 of file __init__.py.


Member Function Documentation

Update the specified object with the difference

Definition at line 58 of file __init__.py.

00058 
00059     def applyChanges(ob):
00060         """Update the specified object with the difference"""
00061 

An anterface for interacting with the difference between two
string (text) objects
Return a list of differences between the two objects on a
line-by-line basis

Each difference is a 5-tuple as described here:
http://www.python.org/doc/2.1.3/lib/sequence-matcher.html#l2h-721

The interpretation of these tuples depends on the difference class

Definition at line 66 of file __init__.py.

00066 
00067     def getLineDiffs():
00068         """Return a list of differences between the two objects on a
00069         line-by-line basis
00070 
00071         Each difference is a 5-tuple as described here:
00072         http://www.python.org/doc/2.1.3/lib/sequence-matcher.html#l2h-721
00073 
00074         The interpretation of these tuples depends on the difference class"""

Test the specified object to determine if the change set will apply cleanly.

Returns None if there would be no erros

Definition at line 52 of file __init__.py.

00052 
00053     def testChanges(ob):
00054         """Test the specified object to determine if the change set will apply cleanly.
00055 
00056         Returns None if there would be no erros
00057         """


Member Data Documentation

tuple CMFDiffTool.interfaces.IDifference.field = Attribute('field', 'The name of the field being compared') [static, inherited]

Definition at line 47 of file __init__.py.

tuple CMFDiffTool.interfaces.IDifference.meta_type = Attribute('title', 'A human readable name for the diff type') [static, inherited]
An interface for interacting with the difference between two
objects

Definition at line 46 of file __init__.py.

tuple CMFDiffTool.interfaces.IDifference.newValue = Attribute('newValue', 'The new field value being compared') [static, inherited]

Definition at line 50 of file __init__.py.

tuple CMFDiffTool.interfaces.IDifference.oldValue = Attribute('oldValue', 'The old field value being compared') [static, inherited]

Definition at line 49 of file __init__.py.

tuple CMFDiffTool.interfaces.IDifference.same = Attribute('same', 'True if the fields are the "same" (whatever that means for this difference)') [static, inherited]

Definition at line 48 of file __init__.py.


The documentation for this class was generated from the following file: