module documentation

_copysupport.py - ZMS Copy and Move Support

This module provides support for copying and moving ZMS objects, including normalization of IDs, handling of BLOB fields, and clipboard operations.

License: GNU General Public License v2 or later, Organization: ZMS Publishing

Class CopySupport Provides copy and move support for ZMS objects, including clipboard operations, BLOB field handling, and normalization of object IDs after paste.
Function normalize_ids_after_copy The ids of copied objects are normalized to the context-node's id_prefix and the ZMS-client's sequence incrementing (acl_sequence). After the objects are moved to their new position their ids are normalized, that means they are reset to a new id that consists of the id_prefix of the target-context and the next increment of the ZMS-object sequence counter.
Function normalize_ids_after_move Normalize the IDs of moved objects after they are pasted into a new context.
Constant OP_COPY Undocumented
Constant OP_MOVE Undocumented
def normalize_ids_after_copy(node, id_prefix='e', ids=[]): (source)

The ids of copied objects are normalized to the context-node's id_prefix and the ZMS-client's sequence incrementing (acl_sequence). After the objects are moved to their new position their ids are normalized, that means they are reset to a new id that consists of the id_prefix of the target-context and the next increment of the ZMS-object sequence counter.

Parameters
nodecontext-node
id_prefixid_prefix of context-node
idslist of ids to be normalized, '*' for all
Note
This function is called after manage_pasteObjs() has moved the objects.
def normalize_ids_after_move(node, id_prefix='e', ids=[]): (source)

Normalize the IDs of moved objects after they are pasted into a new context.

Parameters
node:ZMSNodeThe context node where objects are pasted.
id_prefix:strThe ID prefix for the new context.
ids:listList of IDs to normalize, or '*' for all.
OP_COPY: int = (source)

Undocumented

Value
0
OP_MOVE: int = (source)

Undocumented

Value
1