PHP 클래스 Wallmander\ElasticsearchIndexer\Controller\QueryIntegration

저자: Mikael Mattsson ([email protected])
파일 보기 프로젝트 열기: wallmanderco/elasticsearch-indexer

공개 메소드들

메소드 설명
actionLoopEnd ( WP_Query $query ) Make sure the correct blog is restored.
actionLoopStart ( WP_Query $query ) Ensure we've started a loop before we allow ourselves to change the blog.
actionPreGetPosts ( WP_Query $query ) Disables cache_results, adds header.
actionThePost ( array $post ) Switch to the correct site if the post site id is different than the actual one.
filterFoundPostsQuery ( string $sql, WP_Query $query ) : string Remove the found_rows from the SQL Query.
filterPostsRequest ( string $request, WP_Query $query ) : string Filter query string used for get_posts(). Search for posts and save for later.
filterThePosts ( array $posts, WP_Query $query ) : array

메소드 상세

actionLoopEnd() 공개 정적인 메소드

Make sure the correct blog is restored.
public static actionLoopEnd ( WP_Query $query )
$query WP_Query

actionLoopStart() 공개 정적인 메소드

Ensure we've started a loop before we allow ourselves to change the blog.
public static actionLoopStart ( WP_Query $query )
$query WP_Query

actionPreGetPosts() 공개 정적인 메소드

Disables cache_results, adds header.
public static actionPreGetPosts ( WP_Query $query )
$query WP_Query

actionThePost() 공개 정적인 메소드

Switch to the correct site if the post site id is different than the actual one.
public static actionThePost ( array $post )
$post array

filterFoundPostsQuery() 공개 정적인 메소드

Remove the found_rows from the SQL Query.
public static filterFoundPostsQuery ( string $sql, WP_Query $query ) : string
$sql string
$query WP_Query
리턴 string

filterPostsRequest() 공개 정적인 메소드

Return a query that will return nothing.
public static filterPostsRequest ( string $request, WP_Query $query ) : string
$request string
$query WP_Query
리턴 string

filterThePosts() 공개 정적인 메소드

public static filterThePosts ( array $posts, WP_Query $query ) : array
$posts array
$query WP_Query
리턴 array