D
D
Djuba Baghdad2021-06-26 20:51:29
Java
Djuba Baghdad, 2021-06-26 20:51:29

How to take only certain data from the site?

Hello, I wanted to make one simple application for one game. The essence of the program is that it contains all the information on the game, such as locations, mobs, weapons, etc., and it has categories like "Weapons", "Mobs", "Locations" and faced such a problem that manually fill everything this is very long and tedious (description, image), all this data (description, images) is freely available. I wanted to know how you can take data from the site where everything is stored and correctly register in the application, so that the info about mobs would be only in the "Mobs" category, locations in the "Locations" category, etc., etc.
Essence of the question: how to take only certain data from the site and how to properly sort them into categories

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry Roo, 2021-06-26
@xez

Take all the data, throw out the unnecessary ones, then sort them into categories.

O
Orkhan, 2021-06-26
Hasanly @azerphoenix

Good afternoon.
You need to write a parser that will collect the necessary information for you.
Here it is necessary to note one nuance - it all depends on the site.
For example, if the site is some kind of MVC app, then you can use jsoup to parse the data. If the site content is generated dynamically (i.e. there is a certain frontend), then you can not parse data from html, but look at the site's internal API and parse JSON. And then using java to collect a collection of pojos from the parsed data and save it to the database or somewhere else ... And then display it in the device (For example, RecyclerView or something else ...)
In general, something like this ...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question