public function createOperationContext(
        $filter = [],
        $includeAcls = false,
        $includeAllowableActions = true,
        $includePolicies = false,
        IncludeRelationships $includeRelationships = null,
        array $renditionFilter = [],
        $includePathSegments = true,
        $orderBy = null,
        $cacheEnabled = false,
        $maxItemsPerPage = 100
    ) {
        $operationContext = new OperationContext();
        $operationContext->setFilter($filter);
        $operationContext->setIncludeAcls($includeAcls);
        $operationContext->setIncludeAllowableActions($includeAllowableActions);
        $operationContext->setIncludePolicies($includePolicies);
        if ($includeRelationships !== null) {
            $operationContext->setIncludeRelationships($includeRelationships);
        }
        $operationContext->setRenditionFilter($renditionFilter);
        $operationContext->setIncludePathSegments($includePathSegments);
        if (!empty($orderBy)) {
            $operationContext->setOrderBy($orderBy);
        }
        $operationContext->setCacheEnabled($cacheEnabled);
        $operationContext->setMaxItemsPerPage($maxItemsPerPage);

        return $operationContext;
    }