Package com._1c.g5.v8.dt.compare.store
Interface IComparisonProcessStore
-
public interface IComparisonProcessStore
A prototype / stub interface for the comparison process store.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
cleanCorrespondence(ComparisonProcessHandle handle, SymlinkComparisonNode node)
Cleans (recursively, if required) the correspondence information related to the specified node.Collection<ObjectsTriple<String>>
getCorrespondences(ComparisonProcessHandle handle)
Returns explicit correspondence and exclusion information as a collection of triple of symbolic links.String
getDirectCorrespondence(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide)
Gets the direct correspondence for the specified symbolic link and direction.IComparedObjects<?>
getFromComparedObjectCache(ComparisonProcessHandle handle, long nodeBmId)
Returns the compared object from the cache for the specified node of the specified comparison process.MatchingStrategy
getMainSideMatchingStrategy(ComparisonProcessHandle handle)
Returns the matching strategy for matching objects with the main side of the comparison.Set<Long>
getNodesMarkedAsChangedByUser(ComparisonProcessHandle handle)
Gets comparison nodes marked as changed by user.boolean
isExcluded(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide)
Checks if the specified object is explicitly excluded from being matched in the specified direction.void
markNodeAsChangedByUser(ComparisonProcessHandle handle, long nodeId)
Marks the comparison node as changed by user.void
putToComparedObjectCache(ComparisonProcessHandle handle, long nodeBmId, IComparedObjects<?> comparedObject)
Puts the specified compared object to the compared object cache.void
reduceCacheUsageTemporarily()
Reduces the cache usage temporarily (depends on the implementation) to reduce overall resource strain on the system during high-load operationsvoid
setDirectCorrespondence(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide, String target)
Sets the direct correspondence for the specified symbolic link and direction.void
setIsExcluded(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide, boolean value)
Modifies the explicit exclusion flag for matching the specified object in the specified direction.void
setMainSideMatchingStrategy(ComparisonProcessHandle handle, MatchingStrategy matchingStrategy)
Sets the matching strategy for matching objects with the main side of the comparison.
-
-
-
Method Detail
-
getDirectCorrespondence
String getDirectCorrespondence(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide)
Gets the direct correspondence for the specified symbolic link and direction.- Parameters:
handle
- the comparison process handle, notnull
source
- the source symbolic link, notnull
sourceSide
- the source side, notnull
targetSide
- the target side, notnull
- Returns:
- the direct correspondence on the other side or
null
-
getCorrespondences
Collection<ObjectsTriple<String>> getCorrespondences(ComparisonProcessHandle handle)
Returns explicit correspondence and exclusion information as a collection of triple of symbolic links.- Parameters:
handle
- the comparison process handle, notnull
- Returns:
- collection of symbolic link triple
-
setDirectCorrespondence
void setDirectCorrespondence(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide, String target)
Sets the direct correspondence for the specified symbolic link and direction.- Parameters:
handle
- the comparison process handle, notnull
source
- the source symbolic link, notnull
sourceSide
- the source side, notnull
targetSide
- the target side, notnull
target
- the direct correspondence value to set (may benull
-
getMainSideMatchingStrategy
MatchingStrategy getMainSideMatchingStrategy(ComparisonProcessHandle handle)
Returns the matching strategy for matching objects with the main side of the comparison.- Parameters:
handle
- the comparison process handle, notnull
- Returns:
- the matching strategy for the main side, not
null
-
setMainSideMatchingStrategy
void setMainSideMatchingStrategy(ComparisonProcessHandle handle, MatchingStrategy matchingStrategy)
Sets the matching strategy for matching objects with the main side of the comparison.- Parameters:
handle
- the comparison process handle, notnull
matchingStrategy
- the matching strategy to set, notnull
-
cleanCorrespondence
void cleanCorrespondence(ComparisonProcessHandle handle, SymlinkComparisonNode node)
Cleans (recursively, if required) the correspondence information related to the specified node.- Parameters:
handle
- the comparison process handle, notnull
node
- the comparison result node to clean correspondence information for, notnull
-
isExcluded
boolean isExcluded(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide)
Checks if the specified object is explicitly excluded from being matched in the specified direction.- Parameters:
handle
- the comparison process handle, notnull
source
- the object symbolic link, notnull
sourceSide
- the source side, notnull
targetSide
- the target side, notnull
- Returns:
true
if the object is excluded from matching
-
setIsExcluded
void setIsExcluded(ComparisonProcessHandle handle, String source, ComparisonSide sourceSide, ComparisonSide targetSide, boolean value)
Modifies the explicit exclusion flag for matching the specified object in the specified direction.- Parameters:
handle
- the comparison process handle, notnull
source
- the object symbolic link, notnull
sourceSide
- the source side, notnull
targetSide
- the target side, notnull
value
-true
to mark the object as excluded, andfalse
to remove the object from exclusion
-
putToComparedObjectCache
void putToComparedObjectCache(ComparisonProcessHandle handle, long nodeBmId, IComparedObjects<?> comparedObject)
Puts the specified compared object to the compared object cache.- Parameters:
handle
- the handle of the comparison process the compared object belongs tonodeId
- the id of the node for which the compared object is storedcomparedObject
- the compared object, may benull
to remove from cache
-
getFromComparedObjectCache
IComparedObjects<?> getFromComparedObjectCache(ComparisonProcessHandle handle, long nodeBmId)
Returns the compared object from the cache for the specified node of the specified comparison process.- Parameters:
handle
- the handle of the comparison processnodeId
- the identifier of the node- Returns:
- a compared object or
null
-
getNodesMarkedAsChangedByUser
Set<Long> getNodesMarkedAsChangedByUser(ComparisonProcessHandle handle)
Gets comparison nodes marked as changed by user.- Parameters:
handle
- the handle of the comparison process, notnull
- Returns:
- the set of node identifiers marked as changed, may be empty, never
null
-
markNodeAsChangedByUser
void markNodeAsChangedByUser(ComparisonProcessHandle handle, long nodeId)
Marks the comparison node as changed by user.- Parameters:
handle
- the handle of the comparison process, notnull
nodeId
- the comparison node identifier
-
reduceCacheUsageTemporarily
void reduceCacheUsageTemporarily()
Reduces the cache usage temporarily (depends on the implementation) to reduce overall resource strain on the system during high-load operations
-
-