You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
yanzong/extend/suning-sdk-php/SuningRequest.php

61 lines
1.1 KiB

8 months ago
<?php
/**
* 苏宁开放平台接口 - 接口调用请求抽象类
*
* @author 14050890
* @date 2014-06-03
*/
abstract class SuningRequest {
protected $apiParams = array();
/**
* 是否参数校验(默认false,测试及生产建议为true)
*/
protected $checkParam = false;
public function getCheckParam() {
return $this->checkParam;
}
public function setCheckParam($checkParam) {
$this->checkParam = $checkParam;
}
public function generatorJsonReq($appParams) {
return null;
}
public function generatorXmlReq($appParams) {
return null;
}
/**
* 根据请求方式,生成相应请求报文
*
* @param
* type 请求方式(json或xml)
*/
abstract function getApiParams();
/**
* 获取接口方法名称
*/
abstract function getApiMethodName();
protected $pointParams = array();
public function getPointParams() {
return $this->pointParams;
}
public function setPointParams($pointParams) {
$this->pointParams = $pointParams;
}
/**
* 数据校验
*/
abstract function check();
}
?>