Skip to content

Commit

Permalink
NGSTACK-836: restructure parent-child indexing field mapper
Browse files Browse the repository at this point in the history
  • Loading branch information
pspanja committed May 29, 2024
1 parent 4df4ff8 commit ebafc0a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,23 @@

declare(strict_types=1);

namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper;
namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation;

use Ibexa\Contracts\Core\Persistence\Content as SPIContent;
use Ibexa\Contracts\Core\Persistence\Content\ContentInfo;
use Ibexa\Contracts\Core\Persistence\Content\Handler as ContentHandler;
use Ibexa\Contracts\Core\Persistence\Content\Type\Handler as ContentTypeHandler;
use Ibexa\Contracts\Core\Persistence\Content\Location\Handler as LocationHandler;
use Ibexa\Contracts\Core\Persistence\Content\Type\Handler as ContentTypeHandler;
use Ibexa\Contracts\Core\Persistence\Filter\Content\Handler;
use Ibexa\Contracts\Core\Repository\Exceptions\BadStateException;
use Ibexa\Contracts\Core\Repository\Exceptions\InvalidCriterionArgumentException;
use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentTypeIdentifier;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LogicalAnd;
use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ParentLocationId;
use Ibexa\Contracts\Core\Repository\Values\Filter\Filter;
use Ibexa\Contracts\Core\Persistence\Filter\Content\Handler;
use Ibexa\Contracts\Solr\FieldMapper\ContentTranslationFieldMapper;
use Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper\FullTextFieldResolver;

use function array_key_exists;
use function array_keys;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper;
namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper;

use Ibexa\Contracts\Core\Persistence\Content as SPIContent;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\FullTextFieldResolver;
namespace Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper\FullTextFieldResolver;

use Ibexa\Contracts\Core\Persistence\Content as SPIContent;
use Ibexa\Contracts\Core\Persistence\Content\Type\Handler as ContentTypeHandler;
Expand All @@ -11,7 +11,7 @@
use Ibexa\Contracts\Core\Search\FieldType\FullTextField;
use Ibexa\Contracts\Core\Search\FieldType\TextField;
use Ibexa\Core\Search\Common\FieldRegistry;
use Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\FullTextFieldResolver;
use Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper\FullTextFieldResolver;

final class NativeFulltextFieldResolver implements FullTextFieldResolver
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
netgen_search_extra.parent_child_indexing.parent_child_field_mapper:
class: Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ParentChildFieldMapper
class: Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper
arguments:
- '@netgen_search_extra.parent_child_indexing.fulltext_field_resolver'
- '@Ibexa\Contracts\Core\Persistence\Content\Type\Handler'
Expand All @@ -20,7 +20,7 @@ services:
- '%netgen.ibexa_search_extra.parent_child_indexer%'

netgen_search_extra.parent_child_indexing.fulltext_field_resolver.native:
class: Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\FullTextFieldResolver\NativeFulltextFieldResolver
class: Netgen\IbexaSearchExtra\Core\Search\Solr\FieldMapper\ContentTranslation\ParentChildFieldMapper\FullTextFieldResolver\NativeFulltextFieldResolver
arguments:
- '@Ibexa\Contracts\Core\Persistence\Content\Type\Handler'
- '@Ibexa\Core\Search\Common\FieldRegistry'
Expand Down

0 comments on commit ebafc0a

Please sign in to comment.