Skip to content

Commit

Permalink
Merge pull request #1045 from magento-okapis/MAGETWO-65444-Api-Annota…
Browse files Browse the repository at this point in the history
…tions

- MAGETWO-65444 Add @api annotation to modules owned by Okapis
- MAGETWO-66882 [Clone] Allowing Web API listing to be public - 2.2
  • Loading branch information
buskamuza authored Apr 20, 2017
2 parents ecf775e + 0f2becb commit 6476ac9
Show file tree
Hide file tree
Showing 149 changed files with 431 additions and 141 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@
use Magento\Framework\ObjectManager\Helper\Composite as CompositeHelper;

/**
* Composite user context (implements composite pattern).
* User context.
*
* This class is not implementing standard composite pattern and will not invoke all of its children.
* Instead, it will try to find the first suitable child and return its result.
*
* @api
*/
class CompositeUserContext implements \Magento\Authorization\Model\UserContextInterface
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,9 @@
/**
* Admin permissions collection
*
* @author Magento Core Team <core@magentocommerce.com>
* @deprecated
* @see \Magento\Authorization\Model\ResourceModel\Rules\Collection
*/
class Collection extends \Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
class Collection extends \Magento\Authorization\Model\ResourceModel\Rules\Collection
{
/**
* Initialize resource
*
* @return void
*/
protected function _construct()
{
$this->_init(
\Magento\Authorization\Model\Rules::class,
\Magento\Authorization\Model\ResourceModel\Rules::class
);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

/**
* Admin role collection
*
* @api
*/
class Collection extends \Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
/**
* Rules collection
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
*/
class Collection extends \Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
{
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Authorization/Model/Role.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
* @method \Magento\Authorization\Model\Role setUserType(string $value)
* @method string getRoleName()
* @method \Magento\Authorization\Model\Role setRoleName(string $value)
* @api
*/
class Role extends \Magento\Framework\Model\AbstractModel
{
Expand Down
5 changes: 3 additions & 2 deletions app/code/Magento/Authorization/Model/Rules.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
* @method \Magento\Authorization\Model\Rules setAssertId(int $value)
* @method string getPermission()
* @method \Magento\Authorization\Model\Rules setPermission(string $value)
* @api
*/
class Rules extends \Magento\Framework\Model\AbstractModel
{
Expand All @@ -30,14 +31,14 @@ class Rules extends \Magento\Framework\Model\AbstractModel
* @param \Magento\Framework\Model\Context $context
* @param \Magento\Framework\Registry $registry
* @param \Magento\Authorization\Model\ResourceModel\Rules $resource
* @param \Magento\Authorization\Model\ResourceModel\Permissions\Collection $resourceCollection
* @param \Magento\Authorization\Model\ResourceModel\Rules\Collection $resourceCollection
* @param array $data
*/
public function __construct(
\Magento\Framework\Model\Context $context,
\Magento\Framework\Registry $registry,
\Magento\Authorization\Model\ResourceModel\Rules $resource,
\Magento\Authorization\Model\ResourceModel\Permissions\Collection $resourceCollection,
\Magento\Authorization\Model\ResourceModel\Rules\Collection $resourceCollection,
array $data = []
) {
parent::__construct($context, $registry, $resource, $resourceCollection, $data);
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/Authorization/Model/UserContextInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

/**
* Interface for current user identification.
*
* @api
*/
interface UserContextInterface
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@
* See COPYING.txt for license details.
*/

namespace Magento\Captcha\Block\Adminhtml\Captcha;

/**
* Captcha block for adminhtml area
*
* @author Magento Core Team <core@magentocommerce.com>
*/
namespace Magento\Captcha\Block\Adminhtml\Captcha;

class DefaultCaptcha extends \Magento\Captcha\Block\Captcha\DefaultCaptcha
{
/**
Expand Down
2 changes: 0 additions & 2 deletions app/code/Magento/Captcha/Block/Captcha/DefaultCaptcha.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

/**
* Captcha block
*
* @author Magento Core Team <core@magentocommerce.com>
*/
class DefaultCaptcha extends \Magento\Framework\View\Element\Template
{
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/Captcha/Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

/**
* Captcha image model
*
* @api
*/
class Data extends \Magento\Framework\App\Helper\AbstractHelper
{
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Captcha/Model/DefaultModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
/**
* Implementation of \Zend\Captcha\Image
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
*/
class DefaultModel extends \Zend\Captcha\Image implements \Magento\Captcha\Model\CaptchaInterface
{
Expand Down
5 changes: 4 additions & 1 deletion app/code/Magento/Captcha/view/frontend/web/captcha.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ define([
], function ($) {
'use strict';

/**
* @api
*/
$.widget('mage.captcha', {
options: {
refreshClass: 'refreshing',
Expand All @@ -26,7 +29,7 @@ define([
},

/**
* Method triggeres an AJAX request to refresh the CAPTCHA image
* Method triggers an AJAX request to refresh the CAPTCHA image
*/
refresh: function () {
var imageLoader = this.options.imageLoader;
Expand Down
3 changes: 3 additions & 0 deletions app/code/Magento/Catalog/Model/Product/Exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@

use Magento\Framework\Exception\LocalizedException;

/**
* @api
*/
class Exception extends LocalizedException
{
}
8 changes: 3 additions & 5 deletions app/code/Magento/CatalogRule/Model/Flag.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@
* See COPYING.txt for license details.
*/

/**
* Flag stores status about availability not applied catalog price rules
*
* @author Magento Core Team <core@magentocommerce.com>
*/
namespace Magento\CatalogRule\Model;

/**
* Flag indicates that some rules have changed but changes have not been applied yet.
*/
class Flag extends \Magento\Framework\Flag
{
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

/**
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @api
*/
class IndexBuilder
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
/**
* Exception which represents situation where temporary index table should be used somewhere,
* but it does not exist in a database
*
* @api
*/
class IndexTableNotExistException extends LocalizedException
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

/**
* Exception for situation where used state which is not defined in configuration
*
* @api
*/
class UnknownStateException extends LocalizedException
{
Expand Down
3 changes: 3 additions & 0 deletions app/code/Magento/Checkout/Exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
*/
namespace Magento\Checkout;

/**
* @api
*/
class Exception extends \Magento\Framework\Exception\LocalizedException
{
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
use Magento\Framework\Exception\AlreadyExistsException;

/**
* Class AttributeGroupAlreadyExistsException
* @api
*/
class AttributeGroupAlreadyExistsException extends AlreadyExistsException
{
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Eav/Model/Entity/Attribute/Exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
/**
* EAV entity attribute exception
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
*/
class Exception extends \Magento\Framework\Exception\LocalizedException
{
Expand Down
3 changes: 1 addition & 2 deletions app/code/Magento/Integration/Model/AdminTokenService.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,12 @@

/**
* Class to handle token generation for Admins
*
*/
class AdminTokenService implements \Magento\Integration\Api\AdminTokenServiceInterface
{
/**
* Token Model
*a
*
* @var TokenModelFactory
*/
private $tokenModelFactory;
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Integration/Model/Integration.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
* @method \string getUpdatedAt()
* @method Integration setUpdatedAt(\string $createdAt)
* @method \Magento\Integration\Model\ResourceModel\Integration getResource()
* @api
*/
class Integration extends \Magento\Framework\Model\AbstractModel
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

/**
* Class RecreatedIntegration to display message when a config-based integration needs to be reactivated
*
*/
class RecreatedIntegration implements \Magento\Framework\Notification\MessageInterface
{
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Integration/Model/Oauth/Token.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
* @method int getAuthorized()
* @method Token setAuthorized() setAuthorized(int $authorized)
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @api
*/
class Token extends \Magento\Framework\Model\AbstractModel
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
* See COPYING.txt for license details.
*/

/**
* jQuery plugin is added.
*
* @api
*/
define([
'jquery',
'Magento_Ui/js/modal/alert',
Expand Down
6 changes: 3 additions & 3 deletions app/code/Magento/MediaStorage/Helper/File/Storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
* See COPYING.txt for license details.
*/

namespace Magento\MediaStorage\Helper\File;

/**
* File storage helper
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
*/
namespace Magento\MediaStorage\Helper\File;

class Storage extends \Magento\Framework\App\Helper\AbstractHelper
{
/**
Expand Down
10 changes: 5 additions & 5 deletions app/code/Magento/MediaStorage/Helper/File/Storage/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@
* See COPYING.txt for license details.
*/

/**
* Database saving file helper
*
* @author Magento Core Team <core@magentocommerce.com>
*/
namespace Magento\MediaStorage\Helper\File\Storage;

use Magento\Framework\App\Filesystem\DirectoryList;
use Magento\Framework\Filesystem;

/**
* Database saving file helper
*
* @api
*/
class Database extends \Magento\Framework\App\Helper\AbstractHelper
{
/**
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/MediaStorage/Model/File/Storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@

/**
* Class Storage
*
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @api
*/
class Storage extends AbstractModel
{
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/MediaStorage/Model/File/Storage/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@

/**
* Class Database
*
* @api
*/
class Database extends \Magento\MediaStorage\Model\File\Storage\Database\AbstractDatabase
{
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/MediaStorage/Model/File/Storage/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@

/**
* Class File
*
* @api
*/
class File
{
Expand Down
6 changes: 3 additions & 3 deletions app/code/Magento/MediaStorage/Model/File/Uploader.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
* See COPYING.txt for license details.
*/

namespace Magento\MediaStorage\Model\File;

/**
* Core file uploader model
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
*/
namespace Magento\MediaStorage\Model\File;

class Uploader extends \Magento\Framework\File\Uploader
{
/**
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/Msrp/Pricing/Price/MsrpPriceInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

/**
* MSRP price interface
*
* @api
*/
interface MsrpPriceInterface
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

/**
* @api
*/

define([
'Magento_Tax/js/view/checkout/minicart/subtotal/totals',
'underscore'
Expand Down
Loading

0 comments on commit 6476ac9

Please sign in to comment.