Difference between revisions of "GeoFence library"
From Gcube Wiki
(→User section) |
(→User section) |
||
Line 39: | Line 39: | ||
Returns: | Returns: | ||
HttpStatus object. | HttpStatus object. | ||
+ | </pre> | ||
+ | |||
+ | *updateUser(User user) | ||
+ | <pre> | ||
+ | Parameters: | ||
+ | user - It's the User object you are updating. | ||
+ | Returns: | ||
+ | HttpStatus object. | ||
+ | </pre> | ||
+ | |||
+ | *updateUserById(String id, String password, String email, boolean admin, boolean enabled) | ||
+ | <pre> | ||
+ | Parameters: | ||
+ | id - It's the id of user. | ||
+ | password - It's the password of user. | ||
+ | email - It's the email of user. | ||
+ | admin - It's the boolean flag to define if user is administrator or not. | ||
+ | enabled - It's the boolean flag to define if user is enabled or not. | ||
+ | Returns: | ||
+ | HttpStatus object. | ||
</pre> | </pre> | ||
==Group section== | ==Group section== |
Revision as of 14:55, 21 November 2017
- GeoFence()
Parameters: No input parameter, the default endpoint of Geofence instance is located in the config.properties file. Returns: GeoFence object.
- GeoFence(geofenceRestUrl)
Parameters: geofenceRestUrl - GeoFence endpoint. Returns: GeoFence object.
User section
- getUserById(String id)
Parameters: id - It's the userId of user you are looking for. Returns: GSUser object.
- getUserByUsername(String userName)
Parameters: userName - It's the name of user you are looking for. Returns: GSUser object.
- createUser(User user)
Parameters: user - It's the User object you are creating. Returns: HttpStatus object.
- updateUser(User user)
Parameters: user - It's the User object you are updating. Returns: HttpStatus object.
- updateUserById(String id, String password, String email, boolean admin, boolean enabled)
Parameters: id - It's the id of user. password - It's the password of user. email - It's the email of user. admin - It's the boolean flag to define if user is administrator or not. enabled - It's the boolean flag to define if user is enabled or not. Returns: HttpStatus object.