YAML Custom File

Discussion in 'Plugin Development' started by MasterAsp, Dec 3, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    MasterAsp

    Hello, what I'm trying to do, is to create a YAML file and write custom config to it. My question is, how could I read all the nodes under a node. For example say I have the following yaml.
    Code:
    example:
        example1:
        example2:
        example3:
        example4:
    
    Is there anything I can use that can read a dynamic number of nodes under the example node?
     
  2. Code:
    config.getConfigurationSection("example").getKeys(false)
    The parameter of getKeys determines if you would also like to obtain sub-nodes of your nodes (if it were true, a theoretical node example.example1.foobar would be also included in the result).
     
  3. Offline

    MasterAsp

    Thank you, that was EXTREMELY helpful.
     
    Bone008 likes this.
Thread Status:
Not open for further replies.

Share This Page