- Timestamp:
- Nov 5, 2014, 1:00:33 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/docs/services/howtos.txt
r406 r528 166 166 ---- 167 167 168 ZOO-API 169 ******* 170 171 Before you build your first ZOO-Service implemented inn Java, it is 172 recommended that you first build the ZOO class of the Java ZOO-API. 173 174 .. Note:: You should build ZOO-Kernel prior to follow this instructions. 175 176 To build the ZOO.class of the ZOO-API for Java, use the following 177 command: 178 179 .. code-block:: guess 180 181 cd zoo-api/java 182 make 183 cp ZOO.class libZOO.so /usr/lib/cgi-bin 184 185 .. Note:: running the previous commands will require that both 186 ``javac`` and ``javah`` are in your PATH. 187 188 Java ZCFG requirements 189 ********************************** 190 191 .. Note:: For each Service provided by your ZOO Java Services Provider 192 (your corresponding Java class), the ZCFG File must be 193 named the same as the Java public method name (also the 194 case of characters is important). 195 196 The ZCFG file should contain the following : 197 198 serviceType 199 Java 200 serviceProvider 201 The name of the Java class to use as a ZOO Service Provider. For instance, if your 202 java class, located in the same directory as your ZOO-Kernel, was 203 named ``HelloWorld.class`` then you should use ``HelloWorld``. 204 205 206 Java Data Structure used 207 ******************************** 208 209 The three parameters of the function are passed to the Java function 210 as `java.util.HashMap <http://docs.oracle.com/javase/8/docs/api/java/util/HashMap.html>`__. 211 212 Sample ZOO Java Services Provider 213 ****************************************** 214 168 215 .. code-block:: java 169 216 … … 178 225 outputs.put("Result",hm1); 179 226 System.err.println("Hello from JAVA WOrld !"); 180 return 3;227 return ZOO.SERVICE_SUCCEEDED; 181 228 } 182 229 }
Note: See TracChangeset
for help on using the changeset viewer.