@Service public class UserParamService extends Object
| 构造器和说明 |
|---|
UserParamService() |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
delete(long userId)
删除指定用户的所有参数记录。
|
int |
delete(long userId,
String name)
删除指定用户下的某个具体参数项。
|
Object |
get(long userId,
String name)
获取指定用户下某参数的原始对象值。
|
boolean |
getBoolean(long userId,
String name)
获取指定用户下某参数的布尔值。
|
String |
getDate(long userId,
String name)
获取指定用户下某参数的日期格式化字符串(仅年月日)。
|
String |
getDateTime(long userId,
String name)
获取指定用户下某参数的时间格式化字符串(包含时分秒)。
|
double |
getDouble(long userId,
String name)
获取指定用户下某参数的双精度浮点值。
|
float |
getFloat(long userId,
String name)
获取指定用户下某参数的单精度浮点值。
|
int |
getInt(long userId,
String name)
获取指定用户下某参数的整型值。
|
com.alibaba.fastjson.JSONObject |
getJson(long userId,
String name)
将指定用户下某参数解析为JSON对象。
|
List |
getList(long userId,
String name)
将指定用户下某参数解析为List结构。
|
Map |
getMap(long userId,
String name)
将指定用户下某参数解析为Map结构。
|
String |
getString(long userId,
String name)
获取指定用户下某参数的字符串形式值。
|
int |
insert(long userId,
String name,
Object value)
插入一个新的用户参数项。
|
List<Map<String,Object>> |
list()
获取所有用户的参数列表。
|
List<Map<String,Object>> |
list(long userId)
根据用户ID获取该用户的参数列表。
|
int |
update(long userId,
String name,
Object value)
更新指定用户下某参数的值。
|
@Comment(value="\u83b7\u53d6\u7528\u6237\u5217\u8868") public List<Map<String,Object>> list() throws SQLException
SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u7528\u6237\u53c2\u6570\u5217\u8868") public List<Map<String,Object>> list(long userId) throws SQLException
userId - 用户唯一标识符SQLException - 数据库访问异常时抛出@Comment(value="\u6e05\u7a7a\u7528\u6237\u53c2\u6570")
public int delete(long userId)
throws SQLException
userId - 要删除参数的用户IDSQLException - 数据库访问异常时抛出@Comment(value="\u5220\u9664\u7528\u6237\u53c2\u6570")
public int delete(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名称SQLException - 数据库访问异常时抛出@Comment(value="\u6dfb\u52a0\u7528\u6237\u53c2\u6570")
public int insert(long userId,
String name,
Object value)
throws SQLException
userId - 用户IDname - 参数名value - 参数值(可为任意类型)SQLException - 数据库访问异常时抛出@Comment(value="\u66f4\u65b0\u7528\u6237\u53c2\u6570")
public int update(long userId,
String name,
Object value)
throws SQLException
userId - 用户IDname - 参数名value - 新的参数值SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u7528\u6237\u53c2\u6570") public Object get(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u7528\u6237\u53c2\u6570") public String getString(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u7528\u6237\u53c2\u6570")
public int getInt(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u7528\u6237\u53c2\u6570")
public double getDouble(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6Float")
public float getFloat(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u65e5\u671f") public String getDate(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6\u65e5\u671f\u65f6\u95f4") public String getDateTime(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6JSON")
public com.alibaba.fastjson.JSONObject getJson(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6Map") public Map getMap(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6List") public List getList(long userId, String name) throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出@Comment(value="\u83b7\u53d6Boolean")
public boolean getBoolean(long userId,
String name)
throws SQLException
userId - 用户IDname - 参数名SQLException - 数据库访问异常时抛出Copyright © 2026. All rights reserved.