src/PbjxHelperTrait.php
protected function createGetNodeRequest(Message $message, NodeRef $nodeRef, Pbjx $pbjx): GetNodeRequest
    {
        $curie = $message::schema()->getCurie();

        /** @var GetNodeRequest $class */
        $class = MessageResolver::resolveCurie(SchemaCurie::fromString(
            "{$curie->getVendor()}:{$curie->getPackage()}:request:get-{$nodeRef->getLabel()}-request"
        ));

        return $class::create();
    }
protected function createGetNodeRequest(Message $message, NodeRef $nodeRef, Pbjx $pbjx): GetNodeRequest
    {
        $curie = $message::schema()->getCurie();

        /** @var GetNodeRequest $class */
        $class = MessageResolver::resolveCurie(SchemaCurie::fromString(
            "{$curie->getVendor()}:{$curie->getPackage()}:request:get-{$nodeRef->getLabel()}-request"
        ));

        return $class::create();
    }
protected function createGetNodeRequest ( Message $ message , NodeRef $ nodeRef , Pbjx $ pbjx ) : GetNodeRequest { $ curie = $ message :: schema ( ) -> getCurie ( ) ; /** @var GetNodeRequest $class */ $ class = MessageResolver :: resolveCurie ( SchemaCurie :: fromString ( "{$curie->getVendor()}:{$curie->getPackage()}:request:get-{$nodeRef->getLabel()}-request" ) ) ; return $ class :: create ( ) ; }
A conventional factory to create a get node request from an existing message
and node ref.  Various pbjx lifecycle events need to fetch the node for the
operation currently executing. For example, when attempting to update a node
we fetch the current node in order to make some validations possible.

Override this method if the convention doesn't match or needs to have a special
case handled.  You can also override when you need to populate data on the
get node request before it's processed (multi-tenant apps sometimes need this).

@param Message $message
@param NodeRef $nodeRef
@param Pbjx    $pbjx

@return GetNodeRequest
A conventional factory to create a get node request from an existing message and node ref . Various pbjx lifecycle events need to fetch the node for the operation currently executing . For example when attempting to update a node we fetch the current node in order to make some validations possible .