Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
automatic-test
Overview
Overview
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
钟涨钱
automatic-test
Commits
dd512bec
Commit
dd512bec
authored
Aug 25, 2021
by
朽木不可雕也
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
backup
parent
1e37bda7
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
barrage-crawler-server/src/main/java/com/zhiweidata/automatictest/barragecrawlerserver/createtasks/BiliBiliCreateTaskJob.java
+8
-4
No files found.
barrage-crawler-server/src/main/java/com/zhiweidata/automatictest/barragecrawlerserver/createtasks/BiliBiliCreateTaskJob.java
View file @
dd512bec
...
@@ -26,11 +26,15 @@ public class BiliBiliCreateTaskJob extends CreateTaskJob {
...
@@ -26,11 +26,15 @@ public class BiliBiliCreateTaskJob extends CreateTaskJob {
try
{
try
{
Map
<?,
?>
liveJson
=
new
ObjectMapper
().
readValue
(
new
URL
(
"https://api.live.bilibili.com/xlive/web-interface/v1/index/getList?platform=web"
),
Map
.
class
);
Map
<?,
?>
liveJson
=
new
ObjectMapper
().
readValue
(
new
URL
(
"https://api.live.bilibili.com/xlive/web-interface/v1/index/getList?platform=web"
),
Map
.
class
);
liveJson
=
(
Map
<?,
?>)
requireNonNull
(
liveJson
.
get
(
"data"
));
liveJson
=
(
Map
<?,
?>)
requireNonNull
(
liveJson
.
get
(
"data"
));
final
List
<?>
roomList
=
(
List
<?>)
liveJson
.
get
(
"room_list"
);
final
List
<?>
moduleList
=
(
List
<?>)
liveJson
.
get
(
"room_list"
);
roomList
.
forEach
(
liveRoom
->
{
moduleList
.
forEach
(
liveModule
->
{
Map
<?,
?>
roomMap
=
(
Map
<?,
?>)
liveRoom
;
Map
<?,
?>
liveModuleMap
=
(
Map
<?,
?>)
liveModule
;
List
<?>
roomList
=
(
List
<?>)
liveModuleMap
.
get
(
"list"
);
roomList
.
forEach
(
room
->
{
Map
<?,
?>
roomMap
=
(
Map
<?,
?>)
room
;
this
.
liveTitle
=
(
String
)
roomMap
.
get
(
"title"
);
this
.
liveTitle
=
(
String
)
roomMap
.
get
(
"title"
);
super
.
createCollectionTask
((
String
)
roomMap
.
get
(
"link"
));
BiliBiliCreateTaskJob
.
super
.
createCollectionTask
((
String
)
roomMap
.
get
(
"link"
));
});
});
});
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
log
.
error
(
e
.
getMessage
(),
e
);
...
...
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