-
Notifications
You must be signed in to change notification settings - Fork 301
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #632 from jsteggink/issue-626-managed-resources
Issue #626 managed resources
- Loading branch information
Showing
44 changed files
with
2,542 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?php | ||
|
||
namespace Solarium\QueryType\ManagedResources\Query; | ||
|
||
use Solarium\Core\Client\Client; | ||
use Solarium\QueryType\ManagedResources\RequestBuilder\Resources as RequestBuilder; | ||
use Solarium\QueryType\ManagedResources\ResponseParser\Resources as ResponseParser; | ||
use Solarium\Core\Query\AbstractQuery; | ||
|
||
class Resources extends AbstractQuery | ||
{ | ||
/** | ||
* Fixed name for resources. | ||
* | ||
* @var string | ||
*/ | ||
private $name = 'resources'; | ||
|
||
/** | ||
* Default options. | ||
* | ||
* @var array | ||
*/ | ||
protected $options = [ | ||
'handler' => 'schema/managed', | ||
'resultclass' => 'Solarium\QueryType\ManagedResources\Result\Resources\ResourceList', | ||
'omitheader' => true, | ||
]; | ||
|
||
/** | ||
* Get the name of resources. | ||
* | ||
* @return string | ||
*/ | ||
public function getName(): string | ||
{ | ||
return $this->name; | ||
} | ||
|
||
/** | ||
* Get query type. | ||
* | ||
* @return string | ||
*/ | ||
public function getType(): string | ||
{ | ||
return Client::QUERY_MANAGED_RESOURCES; | ||
} | ||
|
||
/** | ||
* Get the request builder class for this query. | ||
* | ||
* @return RequestBuilder | ||
*/ | ||
public function getRequestBuilder(): RequestBuilder | ||
{ | ||
return new RequestBuilder(); | ||
} | ||
|
||
/** | ||
* Get the response parser class for this query. | ||
* | ||
* @return ResponseParser | ||
*/ | ||
public function getResponseParser(): ResponseParser | ||
{ | ||
return new ResponseParser(); | ||
} | ||
} |
Oops, something went wrong.