No Description

UmengUappGetNewAccountsResult.class.php 1.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. include_once (app_path('/libs/Umeng/').'com/alibaba/openapi/client/entity/SDKDomain.class.php');
  3. include_once (app_path('/libs/Umeng/').'com/alibaba/openapi/client/entity/ByteArray.class.php');
  4. include_once (app_path('/libs/Umeng/').'com/umeng/uapp/param/UmengUappAccountInfo.class.php');
  5. class UmengUappGetNewAccountsResult {
  6. private $newAccountInfo;
  7. /**
  8. * @return UmengUappAccountInfo[]
  9. */
  10. public function getNewAccountInfo() {
  11. return $this->newAccountInfo;
  12. }
  13. /**
  14. * 设置UmengUappAccountInfo[]
  15. * @param array include @see UmengUappAccountInfo[] $newAccountInfo
  16. * 此参数必填 */
  17. public function setNewAccountInfo(UmengUappAccountInfo $newAccountInfo) {
  18. $this->newAccountInfo = $newAccountInfo;
  19. }
  20. private $stdResult;
  21. public function setStdResult($stdResult) {
  22. $this->stdResult = $stdResult;
  23. if (array_key_exists ( "newAccountInfo", $this->stdResult )) {
  24. $newAccountInfoResult=$this->stdResult->{"newAccountInfo"};
  25. $object = json_decode ( json_encode ( $newAccountInfoResult ), true );
  26. $this->newAccountInfo = array ();
  27. for($i = 0; $i < count ( $object ); $i ++) {
  28. $arrayobject = new ArrayObject ( $object [$i] );
  29. $UmengUappAccountInfoResult=new UmengUappAccountInfo();
  30. $UmengUappAccountInfoResult->setArrayResult($arrayobject );
  31. $this->newAccountInfo [$i] = $UmengUappAccountInfoResult;
  32. }
  33. }
  34. }
  35. private $arrayResult;
  36. public function setArrayResult($arrayResult) {
  37. $this->arrayResult = $arrayResult;
  38. if (array_key_exists ( "newAccountInfo", $this->arrayResult )) {
  39. $newAccountInfoResult=$arrayResult['newAccountInfo'];
  40. $this->newAccountInfo = new UmengUappAccountInfo();
  41. $this->newAccountInfo->setStdResult ( $newAccountInfoResult);
  42. }
  43. }
  44. }
  45. ?>