Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Try jsoneditoronline.org. This is what your JSON file should look like in order to work:
- {
- "com.jorch.pokeMap.Characters.Pregunta": {
- "question1": {
- "question": "what is an class in java?",
- "answer": "is the abstraction of an object in the real world",
- "opciones": [
- "is an instance of a object",
- "i don't know",
- "is the abstraction of an object in te real world"
- ],
- "check": false
- },
- "question2": {
- "question": "what is an class in java?",
- "answer": "is the abstraction of an object in the real world",
- "opciones": [
- "is an instance of a object",
- "i don't know",
- "is the abstraction of an object in te real world"
- ],
- "check": false
- },
- "question3": {
- "question": "what is an class in java?",
- "answer": "is the abstraction of an object in the real world",
- "opciones": [
- "is an instance of a object",
- "i don't know",
- "is the abstraction of an object in te real world"
- ],
- "check": false
- },
- "question4": {
- "question": "what is an class in java?",
- "answer": "is the abstraction of an object in the real world",
- "opciones": [
- "is an instance of a object",
- "i don't know",
- "is the abstraction of an object in te real world"
- ],
- "check": false
- }
- }
- }
- To make it simple, you can use arrays:
- {
- "questions": [
- "what is your birthday",
- "how old are you",
- "what is your name"
- ]
- }
- But of course you can also use an array of objects which allows to save more information with each question. This is actually what you did in your file.
- {
- "question objects": [
- {
- "name": "birthday",
- "text": "what is your birthday"
- },
- {
- "name": "age",
- "text": "how old are you"
- },
- {
- "name": "name",
- "text": "what is your name"
- }
- ]
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement