Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
browser-backend
Project
Project
Details
Activity
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
Administrator
browser-backend
Commits
091da1f1
Commit
091da1f1
authored
Mar 23, 2020
by
renjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
绑定记录
parent
4b9ede7b
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
7 deletions
+16
-7
IpResourceDto.java
...a/com/edgec/browserbackend/browser/dto/IpResourceDto.java
+10
-0
BindHistoryToString.java
...dgec/browserbackend/common/utils/BindHistoryToString.java
+5
-6
StringToBindHistory.java
...dgec/browserbackend/common/utils/StringToBindHistory.java
+1
-1
No files found.
src/main/java/com/edgec/browserbackend/browser/dto/IpResourceDto.java
View file @
091da1f1
...
@@ -21,6 +21,7 @@ public class IpResourceDto {
...
@@ -21,6 +21,7 @@ public class IpResourceDto {
private
String
password
;
private
String
password
;
private
List
<
String
>
protocol
;
private
List
<
String
>
protocol
;
ShopDto
bindShop
;
ShopDto
bindShop
;
private
List
<
BindHistory
>
bindHistories
;
public
IpResourceDto
(){
public
IpResourceDto
(){
}
}
...
@@ -39,6 +40,7 @@ public class IpResourceDto {
...
@@ -39,6 +40,7 @@ public class IpResourceDto {
this
.
password
=
ipResource
.
getPassword
();
this
.
password
=
ipResource
.
getPassword
();
this
.
protocol
=
ipResource
.
getProtocol
();
this
.
protocol
=
ipResource
.
getProtocol
();
this
.
bindShop
=
shopDto
;
this
.
bindShop
=
shopDto
;
this
.
bindHistories
=
ipResource
.
getBindHistory
();
}
}
public
String
getId
()
{
public
String
getId
()
{
...
@@ -144,4 +146,12 @@ public class IpResourceDto {
...
@@ -144,4 +146,12 @@ public class IpResourceDto {
public
void
setProtocol
(
List
<
String
>
protocol
)
{
public
void
setProtocol
(
List
<
String
>
protocol
)
{
this
.
protocol
=
protocol
;
this
.
protocol
=
protocol
;
}
}
public
List
<
BindHistory
>
getBindHistories
()
{
return
bindHistories
;
}
public
void
setBindHistories
(
List
<
BindHistory
>
bindHistories
)
{
this
.
bindHistories
=
bindHistories
;
}
}
}
src/main/java/com/edgec/browserbackend/common/utils/BindHistoryToString.java
View file @
091da1f1
...
@@ -9,11 +9,10 @@ public class BindHistoryToString implements Converter<BindHistory, String> {
...
@@ -9,11 +9,10 @@ public class BindHistoryToString implements Converter<BindHistory, String> {
@Override
@Override
public
String
convert
(
BindHistory
bindHistory
)
{
public
String
convert
(
BindHistory
bindHistory
)
{
return
"BindHistory{"
+
return
"{ shopName="
+
new
Character
(
'"'
)
+
bindHistory
.
getShopName
()
+
new
Character
(
'"'
)
+
"shopName=\""
+
bindHistory
.
getShopName
()
+
"\""
+
", ip="
+
new
Character
(
'"'
)
+
bindHistory
.
getIp
()
+
new
Character
(
'"'
)
+
", ip=\""
+
bindHistory
.
getIp
()
+
"\""
+
", platform="
+
new
Character
(
'"'
)
+
bindHistory
.
getPlatform
()
+
new
Character
(
'"'
)
+
", platform=\""
+
bindHistory
.
getPlatform
()
+
"\""
+
", unbindTime="
+
new
Character
(
'"'
)
+
bindHistory
.
getUnbindTime
()
+
new
Character
(
'"'
)
+
", unbindTime=\""
+
bindHistory
.
getUnbindTime
()
+
"\""
+
" }"
;
"}"
;
}
}
}
}
src/main/java/com/edgec/browserbackend/common/utils/StringToBindHistory.java
View file @
091da1f1
...
@@ -10,7 +10,7 @@ import java.util.StringTokenizer;
...
@@ -10,7 +10,7 @@ import java.util.StringTokenizer;
public
class
StringToBindHistory
implements
Converter
<
String
,
BindHistory
>
{
public
class
StringToBindHistory
implements
Converter
<
String
,
BindHistory
>
{
@Override
@Override
public
BindHistory
convert
(
String
s
)
{
public
BindHistory
convert
(
String
s
)
{
s
=
s
.
substring
(
1
2
,
s
.
lastIndexOf
(
"}"
));
s
=
s
.
substring
(
2
,
s
.
lastIndexOf
(
"}"
));
StringTokenizer
stringTokenizer
=
new
StringTokenizer
(
s
,
","
);
StringTokenizer
stringTokenizer
=
new
StringTokenizer
(
s
,
","
);
BindHistory
bindHistory
=
new
BindHistory
();
BindHistory
bindHistory
=
new
BindHistory
();
if
(
stringTokenizer
.
hasMoreTokens
())
{
if
(
stringTokenizer
.
hasMoreTokens
())
{
...
...
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