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
d9265188
Commit
d9265188
authored
5 years ago
by
yanzg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
常规BUG的修改
parent
dfeed506
master
1.0-SNAPSHOT
test
ver1.0
ver1.1
ver1.2
ver1.3
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
4 deletions
+18
-4
CodeException.java
...in/java/com/yanzuoguang/util/exception/CodeException.java
+10
-0
ByteHelper.java
...src/main/java/com/yanzuoguang/util/helper/ByteHelper.java
+2
-1
Ref.java
yzg-util-base/src/main/java/com/yanzuoguang/util/vo/Ref.java
+3
-0
BaseDao.java
yzg-util-db/src/main/java/com/yanzuoguang/dao/BaseDao.java
+3
-3
No files found.
yzg-util-base/src/main/java/com/yanzuoguang/util/exception/CodeException.java
View file @
d9265188
...
...
@@ -2,6 +2,7 @@ package com.yanzuoguang.util.exception;
/**
* 途比达异常信息
*
* @author 颜佐光
*/
public
class
CodeException
extends
RuntimeException
{
...
...
@@ -57,6 +58,15 @@ public class CodeException extends RuntimeException {
this
.
code
=
code
;
}
/**
* 构造函数
* throw new CodeException("01","该订单已过期",order);
* throw new CodeException("02","该订单未到使用时间",order);
*
* @param code 错误码
* @param message 错误消息
* @param target 错误数据源,如订单数据
*/
public
CodeException
(
String
code
,
String
message
,
Object
target
)
{
super
(
message
);
this
.
code
=
code
;
...
...
This diff is collapsed.
Click to expand it.
yzg-util-base/src/main/java/com/yanzuoguang/util/helper/ByteHelper.java
View file @
d9265188
...
...
@@ -556,6 +556,7 @@ public class ByteHelper {
* @return 转换之后的值
*/
public
static
int
fromBCD
(
byte
from
)
{
return
(
from
/
BYTE_HEX_UNIT
)
*
BYTE_TEN_UNIT
+
from
%
BYTE_HEX_UNIT
;
return
(
from
/
BYTE_HEX_UNIT
)
*
BYTE_TEN_UNIT
+
from
%
BYTE_HEX_UNIT
;
}
}
This diff is collapsed.
Click to expand it.
yzg-util-base/src/main/java/com/yanzuoguang/util/vo/Ref.java
View file @
d9265188
...
...
@@ -3,6 +3,9 @@ package com.yanzuoguang.util.vo;
/**
* 引用值,方便修改
*
int func(Ref<Interger> int1,Ref<Integer> int2){
int1.value =1 ;
}
* @param <T>
* @author 颜佐光
*/
...
...
This diff is collapsed.
Click to expand it.
yzg-util-db/src/main/java/com/yanzuoguang/dao/BaseDao.java
View file @
d9265188
...
...
@@ -39,7 +39,7 @@ public interface BaseDao {
String
save
(
Object
model
);
/**
* 删除数据
* 删除数据
,可以用于父子表删除,如通过订单删除游客信息 visitorDao.remove({orderId:1});
*
* @param model 需要删除的数据,可以是主键字符串(Int),或者是包含主键的实体,或者是包含其他非主键的实体完全匹配.
* @return 删除的记录数量
...
...
@@ -47,7 +47,7 @@ public interface BaseDao {
int
remove
(
Object
model
);
/**
* 加载数据
* 加载数据
,可以用于父子表删除,如通过订单删除游客信息 visitorDao.load({orderId:1});
*
* @param model 加载数据的请求参数,可以是主键字符串(Int),或者是包含主键的实体,或者是包含其他非主键的实体完全匹配.
* @param cls 需要加载的数据的类型
...
...
@@ -58,7 +58,7 @@ public interface BaseDao {
/**
* 加载列表数据
* 加载列表数据
,可以用于父子表删除,如通过订单删除游客信息 visitorDao.loadList({orderId:1});
*
* @param model 加载数据的请求参数,可以是主键字符串(Int),或者是包含主键的实体,或者是包含其他非主键的实体完全匹配.
* @param cls 需要加载的数据的类型
...
...
This diff is collapsed.
Click to expand it.
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