Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refund #6

Closed
wants to merge 11 commits into from
Closed

Refund #6

wants to merge 11 commits into from

Conversation

klausxie
Copy link

增添接口:
1,订单查询
(请求:OrderQueryRequest 继承 RequestBase)
(响应: OrderQueryResponse 继承ResponseBase)

2,申请退款
(请求:RefundRequest 继承 RequestBase)
(响应: RefundResponse 继承ResponseBase)

RefundRequest 依赖 ClientCustomSSL(该类作用是读取apiclient_cert.p12证书,根据传入的数据参数生成带认证请求,并将请求回复的数据存入ResponseBase对象返回).

3,退款查询
(请求:RefundQueryRequest 继承 RequestBase)
(响应: RefundQueryResponse 继承ResponseBase)

}

KeyStore keyStore = KeyStore.getInstance("PKCS12");
FileInputStream inputStream = new FileInputStream(new File(path));
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is improper to use File here. Data encapsulated in some virtual source such as java archive(.jar)/URL may not and should not access via File interfaces. In this case, certificates are provided in classpath, which requires you to access it via the "classpath" way. Such like this:

            InputStream stream = this.getClass()
                .getResourceAsStream(resourcePath);

You may refer to javadoc or SO for further information.

@cuter44 cuter44 closed this May 20, 2015
@cuter44 cuter44 reopened this May 25, 2015
@cuter44
Copy link
Owner

cuter44 commented May 25, 2015

As refactor completed, this feature is available to merge to upstream. It is being processed soon.

cuter44 added a commit that referenced this pull request May 30, 2015
fix PR #6
+ wxpay/OrderQuery
+ wxpay/Refund
+ wxpay/RefundQuery
@cuter44
Copy link
Owner

cuter44 commented May 30, 2015

Thanks for your contributions.

Your code has been integrated into the latest release. Sorry for that there is too much difference to merge via git. Therefore your id will not appear on contributors graph. I again apologize for that.

@cuter44 cuter44 closed this May 30, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants