Changes between Version 2 and Version 3 of RepDeveloperGuide
- Timestamp:
- Oct 22, 2010, 12:57:55 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
RepDeveloperGuide
v2 v3 4 4 5 5 By default the test REP does not publish its Resource Description to a Resource Directory. 6 The 'testPublish' method in REPTest.java will publish the Resource Description stored in the file xml/resource-description.xml describing a dummy light sensor. 6 The helper class RPIClient provides you with methods to publish and unpublish Resource Descriptions stored locally on a the file system. 7 For instance **xml/resource-description.xml** describes a dummy light sensor. 7 8 8 The Resource Directory to be used needs to be set in the REP class. Please overwrite following lines according to your needs:9 The Resource Directory to be used needs to be set in the constructor of RPIClient class. 9 10 10 11 {{{ 11 // TODO set RESOURCE_DIRECTORY_PATH 12 private static String RESOURCE_DIRECTORY_PATH; // = "http://localhost:8183/rd/"; 13 private static String RESOURCE_PUBLISH_PATH; // = "http://localhost:8183/rpi/"; 12 public RPIClient(String rliPath, String rpiPath) 14 13 }}} 15 14 15 The first parameter **rliPath** outlines the path to the Resource Directory Lookup Interface, e.g. **http://localhost:8183/rd/** 16 The second parameter **rpiPath** specifies the path to the Resource Publish Interface, e.g. **http://localhost:8183/rpi/** 16 17 17 Alternatively the RD path can be set via REP constructor method:18 {{{19 protected REP(String repRoot, int repPort, String RD_Path, String RPI_Path)20 }}}21 18 You can either set up your own local Resource Directory or you can use one of the preconfigured directories deployed at SENSEI partners' sites. 22 19