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
0946be07
Commit
0946be07
authored
May 08, 2019
by
yanzg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Excel导出功能
parent
71057ec7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
RandomHelper.java
...c/main/java/com/yanzuoguang/util/helper/RandomHelper.java
+4
-1
WebFileHelper.java
...main/java/com/yanzuoguang/cloud/helper/WebFileHelper.java
+1
-0
No files found.
yzg-util-base/src/main/java/com/yanzuoguang/util/helper/RandomHelper.java
View file @
0946be07
...
@@ -6,6 +6,7 @@ import java.util.UUID;
...
@@ -6,6 +6,7 @@ import java.util.UUID;
/**
/**
* 随机码生成工具
* 随机码生成工具
* @author 颜佐光
*/
*/
public
final
class
RandomHelper
{
public
final
class
RandomHelper
{
...
@@ -19,6 +20,8 @@ public final class RandomHelper {
...
@@ -19,6 +20,8 @@ public final class RandomHelper {
private
static
final
int
RANDOM_CHARSET_LEN
=
RANDOM_CHARSET
.
length
();
private
static
final
int
RANDOM_CHARSET_LEN
=
RANDOM_CHARSET
.
length
();
private
static
final
int
RANDOM_SIZE
=
6
;
/**
/**
* 得到32位随机码
* 得到32位随机码
*
*
...
@@ -44,7 +47,7 @@ public final class RandomHelper {
...
@@ -44,7 +47,7 @@ public final class RandomHelper {
*/
*/
public
static
String
generateRandomCodeSix
()
{
public
static
String
generateRandomCodeSix
()
{
StringBuffer
sb
=
new
StringBuffer
();
StringBuffer
sb
=
new
StringBuffer
();
for
(
int
i
=
0
;
i
<
6
;
i
++)
{
for
(
int
i
=
0
;
i
<
RANDOM_SIZE
;
i
++)
{
sb
.
append
(
generateRandomCodeOne
(
RANDOM_CHARSET
,
RANDOM_CHARSET_LEN
));
sb
.
append
(
generateRandomCodeOne
(
RANDOM_CHARSET
,
RANDOM_CHARSET_LEN
));
}
}
return
sb
.
toString
();
return
sb
.
toString
();
...
...
yzg-util-cloud/src/main/java/com/yanzuoguang/cloud/helper/WebFileHelper.java
View file @
0946be07
...
@@ -22,6 +22,7 @@ import java.util.UUID;
...
@@ -22,6 +22,7 @@ import java.util.UUID;
/**
/**
* 上传文件,下载文件操作类
* 上传文件,下载文件操作类
* @author 颜佐光
*/
*/
public
final
class
WebFileHelper
{
public
final
class
WebFileHelper
{
...
...
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