Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
Y
yzg-util
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
YZG
yzg-util
Commits
222ec7a5
Commit
222ec7a5
authored
Jun 22, 2022
by
yanzg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
升级新版本
parent
82971303
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
20 additions
and
15 deletions
+20
-15
WxAuthCode2SessionReq.java
.../wxxcx/auth/login/code2session/WxAuthCode2SessionReq.java
+5
-0
WxXcxAuthCode2SessionRequest.java
...auth/login/code2session/WxXcxAuthCode2SessionRequest.java
+5
-5
WxXcxCode2SessionRes.java
...g/wxxcx/auth/login/code2session/WxXcxCode2SessionRes.java
+1
-1
WxXcxAuthLogin.java
...main/java/com/yanzuoguang/wxxcx/start/WxXcxAuthLogin.java
+4
-4
WxXcxAuthLoginImpl.java
.../com/yanzuoguang/wxxcx/start/impl/WxXcxAuthLoginImpl.java
+5
-5
No files found.
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/Code2SessionReq.java
→
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/
WxAuth
Code2SessionReq.java
View file @
222ec7a5
package
com
.
yanzuoguang
.
wxxcx
.
auth
.
login
.
code2session
;
import
com.yanzuoguang.util.helper.HttpHelper
;
public
class
Code2SessionReq
{
public
class
WxAuthCode2SessionReq
{
}
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/
Code2SessionWxXwxWxXcx
Request.java
→
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/
WxXcxAuthCode2Session
Request.java
View file @
222ec7a5
...
...
@@ -10,13 +10,13 @@ import com.yanzuoguang.wxxcx.base.*;
*
* @author 颜佐光
*/
public
class
Code2SessionWxXwxWxXcx
Request
implements
WxXwxRequestUrl
,
WxXcxRequestUrlPara
{
public
class
WxXcxAuthCode2Session
Request
implements
WxXwxRequestUrl
,
WxXcxRequestUrlPara
{
private
final
WxXcxConfig
wxXcxConfig
;
private
final
WxXcxRequest
wxXcxRequest
;
private
final
Code2SessionReq
req
;
private
final
WxAuth
Code2SessionReq
req
;
public
Code2SessionWxXwxWxXcxRequest
(
WxXcxConfig
wxXcxConfig
,
WxXcxRequest
wxXcxRequest
,
Code2SessionReq
req
)
{
public
WxXcxAuthCode2SessionRequest
(
WxXcxConfig
wxXcxConfig
,
WxXcxRequest
wxXcxRequest
,
WxAuth
Code2SessionReq
req
)
{
this
.
wxXcxConfig
=
wxXcxConfig
;
this
.
wxXcxRequest
=
wxXcxRequest
;
this
.
req
=
req
;
...
...
@@ -32,11 +32,11 @@ public class Code2SessionWxXwxWxXcxRequest implements WxXwxRequestUrl, WxXcxRequ
return
HttpHelper
.
getUrlParameter
(
req
);
}
public
Code2SessionRes
getResponse
()
{
public
WxXcx
Code2SessionRes
getResponse
()
{
// todo: 检测参数是否合法
// Assert.assertEquals();
return
this
.
wxXcxRequest
.
request
(
this
,
response
->
{
Code2SessionRes
ret
=
JsonHelper
.
deserialize
(
response
,
new
TypeReference
<
Code2SessionRes
>()
{
WxXcxCode2SessionRes
ret
=
JsonHelper
.
deserialize
(
response
,
new
TypeReference
<
WxXcx
Code2SessionRes
>()
{
});
WxXcxAssert
.
assertBaseError
(
ret
);
return
ret
;
...
...
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/Code2SessionRes.java
→
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/auth/login/code2session/
WxXcx
Code2SessionRes.java
View file @
222ec7a5
...
...
@@ -2,5 +2,5 @@ package com.yanzuoguang.wxxcx.auth.login.code2session;
import
com.yanzuoguang.wxxcx.base.WxXcxBaseError
;
public
class
Code2SessionRes
extends
WxXcxBaseError
{
public
class
WxXcx
Code2SessionRes
extends
WxXcxBaseError
{
}
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/start/WxXcxAuthLogin.java
View file @
222ec7a5
package
com
.
yanzuoguang
.
wxxcx
.
start
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.Code2SessionReq
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.Code2SessionRes
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
WxAuth
Code2SessionReq
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
WxXcx
Code2SessionRes
;
/**
* 微信登录实现类
...
...
@@ -13,8 +13,8 @@ public interface WxXcxAuthLogin {
/**
* 请求登录
*
* @param
c
ode2SessionReq 请求登录
* @param
wxAuthC
ode2SessionReq 请求登录
* @return 请求实体
*/
Code2SessionRes
code2Session
(
Code2SessionReq
c
ode2SessionReq
);
WxXcxCode2SessionRes
code2Session
(
WxAuthCode2SessionReq
wxAuthC
ode2SessionReq
);
}
yzg-util-wxxcx/src/main/java/com/yanzuoguang/wxxcx/start/impl/WxXcxAuthLoginImpl.java
View file @
222ec7a5
package
com
.
yanzuoguang
.
wxxcx
.
start
.
impl
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.Code2SessionReq
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
Code2SessionWxXwxWxXcx
Request
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.Code2SessionRes
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
WxAuth
Code2SessionReq
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
WxXcxAuthCode2Session
Request
;
import
com.yanzuoguang.wxxcx.auth.login.code2session.
WxXcx
Code2SessionRes
;
import
com.yanzuoguang.wxxcx.base.WxXcxConfig
;
import
com.yanzuoguang.wxxcx.base.WxXcxRequest
;
import
com.yanzuoguang.wxxcx.start.WxXcxAuthLogin
;
...
...
@@ -25,8 +25,8 @@ public class WxXcxAuthLoginImpl implements WxXcxAuthLogin {
}
@Override
public
Code2SessionRes
code2Session
(
Code2SessionReq
c
ode2SessionReq
)
{
Code2SessionWxXwxWxXcxRequest
code2SessionRequest
=
new
Code2SessionWxXwxWxXcxRequest
(
wxXcxConfig
,
wxXcxRequest
,
c
ode2SessionReq
);
public
WxXcxCode2SessionRes
code2Session
(
WxAuthCode2SessionReq
wxAuthC
ode2SessionReq
)
{
WxXcxAuthCode2SessionRequest
code2SessionRequest
=
new
WxXcxAuthCode2SessionRequest
(
wxXcxConfig
,
wxXcxRequest
,
wxAuthC
ode2SessionReq
);
return
code2SessionRequest
.
getResponse
();
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment