Guest User

Untitled

a guest
Aug 31st, 2016
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.07 KB | None | 0 0
  1. [2016-08-31 15:45:22] main.ERROR: /usr/bin/php7.0 -f /var/www/html/magento/bin/magento setup:di:compile 2>&1
  2. Compilation was started.
  3. %message% 0/7 [>---------------------------] 0% 1 sec 42.0 MiB%message% 0/7 [>---------------------------] 0% 1 sec 42.0 MiBProxies code generation... 0/7 [>---------------------------] 0% 1$
  4. Proxies code generation... 1/7 [====>-----------------------] 14% 1 sec 46.0 MiB
  5. Repositories code generation... 1/7 [====>-----------------------] 14% 1 sec 46.0 MiBPHP Fatal error: Cannot declare interface MagentoPaymentModelMethodInterface, because the name is already $
  6.  
  7. Fatal error: Cannot declare interface MagentoPaymentModelMethodInterface, because the name is already in use in /var/www/html/magento/vendor/magento/module-paypal/Model/MethodInterface.php on l$
  8.  
  9. <?php
  10. /**
  11. * Copyright © 2016 Magento. All rights reserved.
  12. * See COPYING.txt for license details.
  13. */
  14. namespace MagentoPaymentModel;
  15.  
  16. use MagentoFrameworkDataObject;
  17. use MagentoQuoteApiDataCartInterface;
  18.  
  19. /**
  20. * Payment interface
  21. * @api
  22. */
  23. interface MethodInterface
  24. {
  25. /**
  26. * Retrieve payment method code
  27. *
  28. * @return string
  29. *
  30. */
  31. public function getCode();
  32.  
  33. /**
  34. * Retrieve block type for method form generation
  35. *
  36. * @return string
  37. *
  38. * @deprecated
  39. */
  40. public function getFormBlockType();
  41.  
  42. /**
  43. * Retrieve payment method title
  44. *
  45. * @return string
  46. *
  47. */
  48. public function getTitle();
  49.  
  50. /**
  51. * Store id setter
  52. * @param int $storeId
  53. * @return void
  54. */
  55. public function setStore($storeId);
  56.  
  57. /**
  58. * Store id getter
  59. * @return int
  60. */
  61. public function getStore();
  62.  
  63. /**
  64. * Check order availability
  65. *
  66. * @return bool
  67. *
  68. */
  69. public function canOrder();
  70.  
  71. /**
  72. * Check authorize availability
  73. *
  74. * @return bool
  75. *
  76. */
  77. public function canAuthorize();
  78.  
  79. /**
  80. * Check capture availability
  81. *
  82. * @return bool
  83. *
  84. */
  85. public function canCapture();
  86.  
  87. /**
  88. * Check partial capture availability
  89. *
  90. * @return bool
  91. *
  92. */
  93. public function canCapturePartial();
  94.  
  95. /**
  96. * Check whether capture can be performed once and no further capture possible
  97. *
  98. * @return bool
  99. *
  100. */
  101. public function canCaptureOnce();
  102.  
  103. /**
  104. * Check refund availability
  105. *
  106. * @return bool
  107. *
  108. */
  109. public function canRefund();
  110.  
  111. /**
  112. * Check partial refund availability for invoice
  113. *
  114. * @return bool
  115. *
  116. */
  117. public function canRefundPartialPerInvoice();
  118.  
  119. /**
  120. * Check void availability
  121. * @return bool
  122. *
  123. */
  124. public function canVoid();
  125.  
  126. /**
  127. * Using internal pages for input payment data
  128. * Can be used in admin
  129. *
  130. * @return bool
  131. */
  132. public function canUseInternal();
  133.  
  134. /**
  135. * Can be used in regular checkout
  136. *
  137. * @return bool
  138. */
  139. public function canUseCheckout();
  140.  
  141. /**
  142. * Can be edit order (renew order)
  143. *
  144. * @return bool
  145. *
  146. */
  147. public function canEdit();
  148.  
  149. /**
  150. * Check fetch transaction info availability
  151. *
  152. * @return bool
  153. *
  154. */
  155. public function canFetchTransactionInfo();
  156.  
  157. /**
  158. * Fetch transaction info
  159. *
  160. * @param InfoInterface $payment
  161. * @param string $transactionId
  162. * @return array
  163. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  164. *
  165. */
  166. public function fetchTransactionInfo(InfoInterface $payment, $transactionId);
  167.  
  168. /**
  169. * Retrieve payment system relation flag
  170. *
  171. * @return bool
  172. *
  173. */
  174. public function isGateway();
  175.  
  176. /**
  177. * Retrieve payment method online/offline flag
  178. *
  179. * @return bool
  180. *
  181. */
  182. public function isOffline();
  183.  
  184. /**
  185. * Flag if we need to run payment initialize while order place
  186. *
  187. * @return bool
  188. *
  189. */
  190. public function isInitializeNeeded();
  191.  
  192. /**
  193. * To check billing country is allowed for the payment method
  194. *
  195. * @param string $country
  196. * @return bool
  197. */
  198. public function canUseForCountry($country);
  199.  
  200. /**
  201. * Check method for processing with base currency
  202. *
  203. * @param string $currencyCode
  204. * @return bool
  205. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  206. */
  207. public function canUseForCurrency($currencyCode);
  208.  
  209. /**
  210. * Retrieve block type for display method information
  211. *
  212. * @return string
  213. *
  214. * @deprecated
  215. */
  216. public function getInfoBlockType();
  217.  
  218. /**
  219. * Retrieve payment information model object
  220. *
  221. * @return InfoInterface
  222. * @throws MagentoFrameworkExceptionLocalizedException
  223. *
  224. * @deprecated
  225. */
  226. public function getInfoInstance();
  227.  
  228. /**
  229. * Retrieve payment information model object
  230. *
  231. * @param InfoInterface $info
  232. * @return void
  233. *
  234. * @deprecated
  235. */
  236. public function setInfoInstance(InfoInterface $info);
  237.  
  238. /**
  239. * Validate payment method information object
  240. *
  241. * @return $this
  242. * @throws MagentoFrameworkExceptionLocalizedException
  243. *
  244. */
  245. public function validate();
  246.  
  247. /**
  248. * Order payment abstract method
  249. *
  250. * @param InfoInterface $payment
  251. * @param float $amount
  252. * @return $this
  253. *
  254. */
  255. public function order(MagentoPaymentModelInfoInterface $payment, $amount);
  256.  
  257. /**
  258. * Authorize payment abstract method
  259. *
  260. * @param InfoInterface $payment
  261. * @param float $amount
  262. * @return $this
  263. *
  264. */
  265. public function authorize(MagentoPaymentModelInfoInterface $payment, $amount);
  266.  
  267. /**
  268. * Capture payment abstract method
  269. *
  270. * @param InfoInterface $payment
  271. * @param float $amount
  272. * @return $this
  273. *
  274. */
  275. public function capture(MagentoPaymentModelInfoInterface $payment, $amount);
  276.  
  277. /**
  278. * Refund specified amount for payment
  279. *
  280. * @param InfoInterface $payment
  281. * @param float $amount
  282. * @return $this
  283. *
  284. */
  285. public function refund(MagentoPaymentModelInfoInterface $payment, $amount);
  286.  
  287. /**
  288. * Cancel payment abstract method
  289. *
  290. * @param InfoInterface $payment
  291. * @return $this
  292. *
  293. */
  294. public function cancel(MagentoPaymentModelInfoInterface $payment);
  295.  
  296. /**
  297. * Void payment abstract method
  298. *
  299. * @param InfoInterface $payment
  300. * @return $this
  301. *
  302. */
  303. public function void(MagentoPaymentModelInfoInterface $payment);
  304.  
  305. /**
  306. * Whether this method can accept or deny payment
  307. * @return bool
  308. *
  309. */
  310. public function canReviewPayment();
  311.  
  312. /**
  313. * Attempt to accept a payment that us under review
  314. *
  315. * @param InfoInterface $payment
  316. * @return false
  317. * @throws MagentoFrameworkExceptionLocalizedException
  318. *
  319. */
  320. public function acceptPayment(InfoInterface $payment);
  321.  
  322. /**
  323. * Attempt to deny a payment that us under review
  324. *
  325. * @param InfoInterface $payment
  326. * @return false
  327. * @throws MagentoFrameworkExceptionLocalizedException
  328. *
  329. */
  330. public function denyPayment(InfoInterface $payment);
  331.  
  332. /**
  333. * Retrieve information from payment configuration
  334. *
  335. * @param string $field
  336. * @param int|string|null|MagentoStoreModelStore $storeId
  337. *
  338. * @return mixed
  339. */
  340. public function getConfigData($field, $storeId = null);
  341.  
  342. /**
  343. * Assign data to info model instance
  344. *
  345. * @param DataObject $data
  346. * @return $this
  347. *
  348. */
  349. public function assignData(DataObject $data);
  350.  
  351. /**
  352. * Check whether payment method can be used
  353. *
  354. * @param CartInterface|null $quote
  355. * @return bool
  356. *
  357. */
  358. public function isAvailable(CartInterface $quote = null);
  359.  
  360. /**
  361. * Is active
  362. *
  363. * @param int|null $storeId
  364. * @return bool
  365. *
  366. */
  367. public function isActive($storeId = null);
  368.  
  369. /**
  370. * Method that will be executed instead of authorize or capture
  371. * if flag isInitializeNeeded set to true
  372. *
  373. * @param string $paymentAction
  374. * @param object $stateObject
  375. *
  376. * @return $this
  377. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  378. *
  379. */
  380. public function initialize($paymentAction, $stateObject);
  381.  
  382. /**
  383. * Get config payment action url
  384. * Used to universalize payment actions when processing payment place
  385. *
  386. * @return string
  387. *
  388. */
  389. public function getConfigPaymentAction();
  390. }
  391.  
  392. <?php
  393. /**
  394. * Copyright © 2016 Magento. All rights reserved.
  395. * See COPYING.txt for license details.
  396. */
  397. namespace MagentoPaymentModel;
  398.  
  399. use MagentoFrameworkDataObject;
  400. use MagentoQuoteApiDataCartInterface;
  401.  
  402. /**
  403. * Payment interface
  404. * @api
  405. */
  406. interface MethodInterface
  407. {
  408. /**
  409. * Retrieve payment method code
  410. *
  411. * @return string
  412. *
  413. */
  414. public function getCode();
  415.  
  416. /**
  417. * Retrieve block type for method form generation
  418. *
  419. * @return string
  420. *
  421. * @deprecated
  422. */
  423. public function getFormBlockType();
  424.  
  425. /**
  426. * Retrieve payment method title
  427. *
  428. * @return string
  429. *
  430. */
  431. public function getTitle();
  432.  
  433. /**
  434. * Store id setter
  435. * @param int $storeId
  436. * @return void
  437. */
  438. public function setStore($storeId);
  439.  
  440. /**
  441. * Store id getter
  442. * @return int
  443. */
  444. public function getStore();
  445.  
  446. /**
  447. * Check order availability
  448. *
  449. * @return bool
  450. *
  451. */
  452. public function canOrder();
  453.  
  454. /**
  455. * Check authorize availability
  456. *
  457. * @return bool
  458. *
  459. */
  460. public function canAuthorize();
  461.  
  462. /**
  463. * Check capture availability
  464. *
  465. * @return bool
  466. *
  467. */
  468. public function canCapture();
  469.  
  470. /**
  471. * Check partial capture availability
  472. *
  473. * @return bool
  474. *
  475. */
  476. public function canCapturePartial();
  477.  
  478. /**
  479. * Check whether capture can be performed once and no further capture possible
  480. *
  481. * @return bool
  482. *
  483. */
  484. public function canCaptureOnce();
  485.  
  486. /**
  487. * Check refund availability
  488. *
  489. * @return bool
  490. *
  491. */
  492. public function canRefund();
  493.  
  494. /**
  495. * Check partial refund availability for invoice
  496. *
  497. * @return bool
  498. *
  499. */
  500. public function canRefundPartialPerInvoice();
  501.  
  502. /**
  503. * Check void availability
  504. * @return bool
  505. *
  506. */
  507. public function canVoid();
  508.  
  509. /**
  510. * Using internal pages for input payment data
  511. * Can be used in admin
  512. *
  513. * @return bool
  514. */
  515. public function canUseInternal();
  516.  
  517. /**
  518. * Can be used in regular checkout
  519. *
  520. * @return bool
  521. */
  522. public function canUseCheckout();
  523.  
  524. /**
  525. * Can be edit order (renew order)
  526. *
  527. * @return bool
  528. *
  529. */
  530. public function canEdit();
  531.  
  532. /**
  533. * Check fetch transaction info availability
  534. *
  535. * @return bool
  536. *
  537. */
  538. public function canFetchTransactionInfo();
  539.  
  540. /**
  541. * Fetch transaction info
  542. *
  543. * @param InfoInterface $payment
  544. * @param string $transactionId
  545. * @return array
  546. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  547. *
  548. */
  549. public function fetchTransactionInfo(InfoInterface $payment, $transactionId);
  550.  
  551. /**
  552. * Retrieve payment system relation flag
  553. *
  554. * @return bool
  555. *
  556. */
  557. public function isGateway();
  558.  
  559. /**
  560. * Retrieve payment method online/offline flag
  561. *
  562. * @return bool
  563. *
  564. */
  565. public function isOffline();
  566.  
  567. /**
  568. * Flag if we need to run payment initialize while order place
  569. *
  570. * @return bool
  571. *
  572. */
  573. public function isInitializeNeeded();
  574.  
  575. /**
  576. * To check billing country is allowed for the payment method
  577. *
  578. * @param string $country
  579. * @return bool
  580. */
  581. public function canUseForCountry($country);
  582.  
  583. /**
  584. * Check method for processing with base currency
  585. *
  586. * @param string $currencyCode
  587. * @return bool
  588. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  589. */
  590. public function canUseForCurrency($currencyCode);
  591.  
  592. /**
  593. * Retrieve block type for display method information
  594. *
  595. * @return string
  596. *
  597. * @deprecated
  598. */
  599. public function getInfoBlockType();
  600.  
  601. /**
  602. * Retrieve payment information model object
  603. *
  604. * @return InfoInterface
  605. * @throws MagentoFrameworkExceptionLocalizedException
  606. *
  607. * @deprecated
  608. */
  609. public function getInfoInstance();
  610.  
  611. /**
  612. * Retrieve payment information model object
  613. *
  614. * @param InfoInterface $info
  615. * @return void
  616. *
  617. * @deprecated
  618. */
  619. public function setInfoInstance(InfoInterface $info);
  620.  
  621. /**
  622. * Validate payment method information object
  623. *
  624. * @return $this
  625. * @throws MagentoFrameworkExceptionLocalizedException
  626. *
  627. */
  628. public function validate();
  629.  
  630. /**
  631. * Order payment abstract method
  632. *
  633. * @param InfoInterface $payment
  634. * @param float $amount
  635. * @return $this
  636. *
  637. */
  638. public function order(MagentoPaymentModelInfoInterface $payment, $amount);
  639.  
  640. /**
  641. * Authorize payment abstract method
  642. *
  643. * @param InfoInterface $payment
  644. * @param float $amount
  645. * @return $this
  646. *
  647. */
  648. public function authorize(MagentoPaymentModelInfoInterface $payment, $amount);
  649.  
  650. /**
  651. * Capture payment abstract method
  652. *
  653. * @param InfoInterface $payment
  654. * @param float $amount
  655. * @return $this
  656. *
  657. */
  658. public function capture(MagentoPaymentModelInfoInterface $payment, $amount);
  659.  
  660. /**
  661. * Refund specified amount for payment
  662. *
  663. * @param InfoInterface $payment
  664. * @param float $amount
  665. * @return $this
  666. *
  667. */
  668. public function refund(MagentoPaymentModelInfoInterface $payment, $amount);
  669.  
  670. /**
  671. * Cancel payment abstract method
  672. *
  673. * @param InfoInterface $payment
  674. * @return $this
  675. *
  676. */
  677. public function cancel(MagentoPaymentModelInfoInterface $payment);
  678.  
  679. /**
  680. * Void payment abstract method
  681. *
  682. * @param InfoInterface $payment
  683. * @return $this
  684. *
  685. */
  686. public function void(MagentoPaymentModelInfoInterface $payment);
  687.  
  688. /**
  689. * Whether this method can accept or deny payment
  690. * @return bool
  691. *
  692. */
  693. public function canReviewPayment();
  694.  
  695. /**
  696. * Attempt to accept a payment that us under review
  697. *
  698. * @param InfoInterface $payment
  699. * @return false
  700. * @throws MagentoFrameworkExceptionLocalizedException
  701. *
  702. */
  703. public function acceptPayment(InfoInterface $payment);
  704.  
  705. /**
  706. * Attempt to deny a payment that us under review
  707. *
  708. * @param InfoInterface $payment
  709. * @return false
  710. * @throws MagentoFrameworkExceptionLocalizedException
  711. *
  712. */
  713. public function denyPayment(InfoInterface $payment);
  714.  
  715. /**
  716. * Retrieve information from payment configuration
  717. *
  718. * @param string $field
  719. * @param int|string|null|MagentoStoreModelStore $storeId
  720. *
  721. * @return mixed
  722. */
  723. public function getConfigData($field, $storeId = null);
  724.  
  725. /**
  726. * Assign data to info model instance
  727. *
  728. * @param DataObject $data
  729. * @return $this
  730. *
  731. */
  732. public function assignData(DataObject $data);
  733.  
  734. /**
  735. * Check whether payment method can be used
  736. *
  737. * @param CartInterface|null $quote
  738. * @return bool
  739. *
  740. */
  741. public function isAvailable(CartInterface $quote = null);
  742.  
  743. /**
  744. * Is active
  745. *
  746. * @param int|null $storeId
  747. * @return bool
  748. *
  749. */
  750. public function isActive($storeId = null);
  751.  
  752. /**
  753. * Method that will be executed instead of authorize or capture
  754. * if flag isInitializeNeeded set to true
  755. *
  756. * @param string $paymentAction
  757. * @param object $stateObject
  758. *
  759. * @return $this
  760. * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  761. *
  762. */
  763. public function initialize($paymentAction, $stateObject);
  764.  
  765. /**
  766. * Get config payment action url
  767. * Used to universalize payment actions when processing payment place
  768. *
  769. * @return string
  770. *
  771. */
  772. public function getConfigPaymentAction();
  773. }
Add Comment
Please, Sign In to add comment