使用文档完善

This commit is contained in:
lqyan
2024-02-19 15:48:24 +08:00
parent ccff90c96a
commit 062fb20485
6 changed files with 98 additions and 8 deletions

View File

@@ -1,6 +1,7 @@
package com.jhinno.sdk.openapi.api;
import cn.hutool.crypto.symmetric.AES;
import cn.hutool.http.ContentType;
import com.fasterxml.jackson.core.type.TypeReference;
import com.jhinno.sdk.openapi.ArgsException;
import com.jhinno.sdk.openapi.CommonConstant;
@@ -143,14 +144,15 @@ public class JHApiExecution {
/**
* 构建一个带token的请求头
*
* @param username 用户名
* @param username 用户名
* @param isContentType 是否携带默认的Content-type默认为{@link ContentType#JSON}
* @return 请求头
*/
protected Map<String, String> getHeaders(String username, boolean isContentType) {
Map<String, String> headers = new HashMap<>();
// 默认请求json数据
if (isContentType) {
headers.put("Content-type", "application/json");
headers.put("Content-type", ContentType.JSON.getValue());
}
if (StringUtils.isBlank(username)) {
return headers;

View File

@@ -66,6 +66,7 @@ public class JHAppApiExecution extends JHApiExecution {
* 注:开启密集后,仅能查看自己的会话和比自己密级低的会话
* </p>
*
* @param username 用户名
* @return 会话列表
*/
public List<SessionInfo> getDesktopList(String username) {
@@ -223,6 +224,7 @@ public class JHAppApiExecution extends JHApiExecution {
/**
* 连接会话
*
* @param username 用户名
* @param sessionId 会话拆
* @return JHClient协议链接信息
*/

View File

@@ -1,6 +1,5 @@
package com.jhinno.sdk.openapi.api.app;
import com.sun.java.swing.plaf.windows.resources.windows;
import lombok.Data;
import java.util.Date;

View File

@@ -35,6 +35,7 @@ public class JHDataApiExecution extends JHApiExecution {
/**
* 根据用户scope查询数据目录列表
*
* @param username 用户名
* @return 用户数据目录列表
*/
public List<SpoolerDataInfo> getSpoolersData(String username) {