- Модуль: disk
- Путь к файлу: ~/bitrix/modules/disk/lib/document/onlyoffice/models/documentsession.php
- Класс: BitrixDiskDocumentOnlyOfficeModelsDocumentSession
- Вызов: DocumentSession::cloneWithNewHash
public function cloneWithNewHash(int $userId, ?DocumentSessionContext $context = null): ?self
{
return self::add([
'OBJECT_ID' => $this->getObjectId(),
'VERSION_ID' => $this->getVersionId(),
'USER_ID' => $userId,
'OWNER_ID' => $this->getOwnerId(),
'IS_EXCLUSIVE' => $this->isExclusive(),
'TYPE' => $this->getType(),
'CONTEXT' => $context? $context->toJson() : $this->getContextRaw(),
], $this->errorCollection);
}