View Javadoc

1   /*
2    * To change this template, choose Tools | Templates and open the template in
3    * the editor.
4    */
5   
6   package net.sf.ovanttasks.ovnative.demos;
7   
8   import net.sf.ovanttasks.ovnative.win32.Registry;
9   
10  /**
11   * @author aploese
12   */
13  public class Main {
14  
15  	public static void main(String[] args) {
16  		try {
17  			Registry reg = new Registry(Registry.HKEY_CURRENT_USER);
18  			for (String s : reg.valueNames()) {
19  				System.out.println("Value: " + s);
20  			}
21  			for (String s : reg.subKeyNames()) {
22  				System.out.println("SubKey: " + s);
23  			}
24  			System.out.println("END OK");
25  		} catch (Exception e) {
26  			System.out.println("END EXCEPTION");
27  			System.err.println(e.getMessage());
28  			e.printStackTrace();
29  		}
30  	}
31  
32  }