test_class.declarator: LOGGER = Logger.getLogger(GeoStoreClientTest.class)
test_class.modifier: private final static
test_class.original_string: private final static Logger LOGGER = Logger.getLogger(GeoStoreClientTest.class);
test_class.type: Logger
test_class.var_name: LOGGER
test_class.declarator: DEFAULTCATEGORYNAME = "TestCategory1"
test_class.modifier: final
test_class.original_string: final String DEFAULTCATEGORYNAME = "TestCategory1";
test_class.type: String
test_class.var_name: DEFAULTCATEGORYNAME
test_class.file: src/modules/rest/client/src/test/java/it/geosolutions/geostore/services/rest/GeoStoreClientTest.java
test_class.identifier: GeoStoreClientTest
test_class.superclass: extends BaseGeoStoreClientTest
test_case.body: @Test
      public void testupdateSecurityRules() {
      	
      	createDefaultCategory();
  
          RESTResource res = new RESTResource();
          res.setCategory(new RESTCategory(DEFAULTCATEGORYNAME));
  
          String timeid = Long.toString(System.currentTimeMillis());
          res.setName("rest_test_resource_" + timeid);
  
          Long userId = createUser("u1_" + timeid, Role.USER, "---");
          
          UserGroup g1 = new UserGroup();
          g1.setGroupName("g1_"  + timeid);
          Long groupId = adminClient.insertUserGroup(g1);
          
          
          Long id = client.insert(res);
          List<SecurityRule> ruleList = new ArrayList<SecurityRule>();
          
          SecurityRule rule = new SecurityRule();
          rule.setCanRead(true);
          rule.setCanWrite(true);   
          User user = new User();
          user.setId(userId);
          rule.setUser(user);
          ruleList.add(rule);
          
          rule = new SecurityRule();
          rule.setCanRead(true);
          rule.setCanWrite(false); 
          UserGroup group = new UserGroup();
          group.setId(groupId);
          rule.setGroup(group);
          ruleList.add(rule);
          
          SecurityRuleList rules = new SecurityRuleList(ruleList);
          client.updateSecurityRules(id, rules);
          
          SecurityRuleList writtenRules = client.getSecurityRules(id);
          assertNotNull(writtenRules.getList());
          assertEquals(2, rules.getList().size());
      }
test_case.class_method_signature: GeoStoreClientTest.testupdateSecurityRules()
test_case.full_signature: @Test public void testupdateSecurityRules()
test_case.identifier: testupdateSecurityRules
test_case.invocations: createDefaultCategory setCategory toString currentTimeMillis setName createUser setGroupName insertUserGroup insert setCanRead setCanWrite setId setUser add setCanRead setCanWrite setId setGroup add updateSecurityRules getSecurityRules assertNotNull getList assertEquals size getList
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testupdateSecurityRules()
focal_class.declarator: username = null
focal_class.modifier: private
focal_class.original_string: private String username = null;
focal_class.type: String
focal_class.var_name: username
focal_class.declarator: password = null
focal_class.modifier: private
focal_class.original_string: private String password = null;
focal_class.type: String
focal_class.var_name: password
focal_class.declarator: geostoreRestUrl = null
focal_class.modifier: private
focal_class.original_string: private String geostoreRestUrl = null;
focal_class.type: String
focal_class.var_name: geostoreRestUrl
focal_class.file: src/modules/rest/client/src/main/java/it/geosolutions/geostore/services/rest/GeoStoreClient.java
focal_class.identifier: GeoStoreClient
focal_class.class_method_signature: GeoStoreClient.GeoStoreClient()
focal_class.full_signature: public  GeoStoreClient()
focal_class.identifier: GeoStoreClient
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  GeoStoreClient()
focal_class.class_method_signature: GeoStoreClient.searchResources(SearchFilter searchFilter)
focal_class.full_signature: @Deprecated public ShortResourceList searchResources(SearchFilter searchFilter)
focal_class.identifier: searchResources
focal_class.modifiers: @Deprecated public
focal_class.parameters: (SearchFilter searchFilter)
focal_class.return: ShortResourceList
focal_class.signature: ShortResourceList searchResources(SearchFilter searchFilter)
focal_class.class_method_signature: GeoStoreClient.searchResources(SearchFilter searchFilter,
              Integer page, Integer entries,
              Boolean includeAttributes, Boolean includeData)
focal_class.full_signature: public ResourceList searchResources(SearchFilter searchFilter,
              Integer page, Integer entries,
              Boolean includeAttributes, Boolean includeData)
focal_class.identifier: searchResources
focal_class.modifiers: public
focal_class.parameters: (SearchFilter searchFilter,
              Integer page, Integer entries,
              Boolean includeAttributes, Boolean includeData)
focal_class.return: ResourceList
focal_class.signature: ResourceList searchResources(SearchFilter searchFilter,
              Integer page, Integer entries,
              Boolean includeAttributes, Boolean includeData)
focal_class.class_method_signature: GeoStoreClient.addQParam(WebResource wb, String key, Object value)
focal_class.full_signature: protected WebResource addQParam(WebResource wb, String key, Object value)
focal_class.identifier: addQParam
focal_class.modifiers: protected
focal_class.parameters: (WebResource wb, String key, Object value)
focal_class.return: WebResource
focal_class.signature: WebResource addQParam(WebResource wb, String key, Object value)
focal_class.class_method_signature: GeoStoreClient.insert(RESTResource resource)
focal_class.full_signature: public Long insert(RESTResource resource)
focal_class.identifier: insert
focal_class.modifiers: public
focal_class.parameters: (RESTResource resource)
focal_class.return: Long
focal_class.signature: Long insert(RESTResource resource)
focal_class.class_method_signature: GeoStoreClient.getResource(Long id, boolean full)
focal_class.full_signature: public Resource getResource(Long id, boolean full)
focal_class.identifier: getResource
focal_class.modifiers: public
focal_class.parameters: (Long id, boolean full)
focal_class.return: Resource
focal_class.signature: Resource getResource(Long id, boolean full)
focal_class.class_method_signature: GeoStoreClient.getResource(Long id)
focal_class.full_signature: public Resource getResource(Long id)
focal_class.identifier: getResource
focal_class.modifiers: public
focal_class.parameters: (Long id)
focal_class.return: Resource
focal_class.signature: Resource getResource(Long id)
focal_class.class_method_signature: GeoStoreClient.deleteResource(Long id)
focal_class.full_signature: public void deleteResource(Long id)
focal_class.identifier: deleteResource
focal_class.modifiers: public
focal_class.parameters: (Long id)
focal_class.return: void
focal_class.signature: void deleteResource(Long id)
focal_class.class_method_signature: GeoStoreClient.updateResource(Long id, RESTResource resource)
focal_class.full_signature: public void updateResource(Long id, RESTResource resource)
focal_class.identifier: updateResource
focal_class.modifiers: public
focal_class.parameters: (Long id, RESTResource resource)
focal_class.return: void
focal_class.signature: void updateResource(Long id, RESTResource resource)
focal_class.class_method_signature: GeoStoreClient.getAllShortResource(Integer page, Integer entries)
focal_class.full_signature: public ShortResourceList getAllShortResource(Integer page, Integer entries)
focal_class.identifier: getAllShortResource
focal_class.modifiers: public
focal_class.parameters: (Integer page, Integer entries)
focal_class.return: ShortResourceList
focal_class.signature: ShortResourceList getAllShortResource(Integer page, Integer entries)
focal_class.class_method_signature: GeoStoreClient.getSecurityRules(Long resourceId)
focal_class.full_signature: public SecurityRuleList getSecurityRules(Long resourceId)
focal_class.identifier: getSecurityRules
focal_class.modifiers: public
focal_class.parameters: (Long resourceId)
focal_class.return: SecurityRuleList
focal_class.signature: SecurityRuleList getSecurityRules(Long resourceId)
focal_class.class_method_signature: GeoStoreClient.updateSecurityRules(Long resourceId, SecurityRuleList rules)
focal_class.full_signature: public void updateSecurityRules(Long resourceId, SecurityRuleList rules)
focal_class.identifier: updateSecurityRules
focal_class.modifiers: public
focal_class.parameters: (Long resourceId, SecurityRuleList rules)
focal_class.return: void
focal_class.signature: void updateSecurityRules(Long resourceId, SecurityRuleList rules)
focal_class.class_method_signature: GeoStoreClient.getData(Long id)
focal_class.full_signature: public String getData(Long id)
focal_class.identifier: getData
focal_class.modifiers: public
focal_class.parameters: (Long id)
focal_class.return: String
focal_class.signature: String getData(Long id)
focal_class.class_method_signature: GeoStoreClient.getData(Long id, MediaType acceptMediaType)
focal_class.full_signature: public String getData(Long id, MediaType acceptMediaType)
focal_class.identifier: getData
focal_class.modifiers: public
focal_class.parameters: (Long id, MediaType acceptMediaType)
focal_class.return: String
focal_class.signature: String getData(Long id, MediaType acceptMediaType)
focal_class.class_method_signature: GeoStoreClient.getRawData(Long id, RawFormat decodeFrom)
focal_class.full_signature: public byte[] getRawData(Long id, RawFormat decodeFrom)
focal_class.identifier: getRawData
focal_class.modifiers: public
focal_class.parameters: (Long id, RawFormat decodeFrom)
focal_class.return: byte[]
focal_class.signature: byte[] getRawData(Long id, RawFormat decodeFrom)
focal_class.class_method_signature: GeoStoreClient.getRawData(Class<T> clazz, Long id, RawFormat decodeFrom)
focal_class.full_signature: public T getRawData(Class<T> clazz, Long id, RawFormat decodeFrom)
focal_class.identifier: getRawData
focal_class.modifiers: public
focal_class.parameters: (Class<T> clazz, Long id, RawFormat decodeFrom)
focal_class.return: T
focal_class.signature: T getRawData(Class<T> clazz, Long id, RawFormat decodeFrom)
focal_class.class_method_signature: GeoStoreClient.setData(Long id, String data)
focal_class.full_signature: public void setData(Long id, String data)
focal_class.identifier: setData
focal_class.modifiers: public
focal_class.parameters: (Long id, String data)
focal_class.return: void
focal_class.signature: void setData(Long id, String data)
focal_class.class_method_signature: GeoStoreClient.updateData(Long id, String data)
focal_class.full_signature: public void updateData(Long id, String data)
focal_class.identifier: updateData
focal_class.modifiers: public
focal_class.parameters: (Long id, String data)
focal_class.return: void
focal_class.signature: void updateData(Long id, String data)
focal_class.class_method_signature: GeoStoreClient.insert(RESTCategory category)
focal_class.full_signature: public Long insert(RESTCategory category)
focal_class.identifier: insert
focal_class.modifiers: public
focal_class.parameters: (RESTCategory category)
focal_class.return: Long
focal_class.signature: Long insert(RESTCategory category)
focal_class.class_method_signature: GeoStoreClient.getCategory(Long id)
focal_class.full_signature: public Category getCategory(Long id)
focal_class.identifier: getCategory
focal_class.modifiers: public
focal_class.parameters: (Long id)
focal_class.return: Category
focal_class.signature: Category getCategory(Long id)
focal_class.class_method_signature: GeoStoreClient.getCategoryCount(String nameLike)
focal_class.full_signature: public Long getCategoryCount(String nameLike)
focal_class.identifier: getCategoryCount
focal_class.modifiers: public
focal_class.parameters: (String nameLike)
focal_class.return: Long
focal_class.signature: Long getCategoryCount(String nameLike)
focal_class.class_method_signature: GeoStoreClient.getCategories(Integer page, Integer entries)
focal_class.full_signature: public CategoryList getCategories(Integer page, Integer entries)
focal_class.identifier: getCategories
focal_class.modifiers: public
focal_class.parameters: (Integer page, Integer entries)
focal_class.return: CategoryList
focal_class.signature: CategoryList getCategories(Integer page, Integer entries)
focal_class.class_method_signature: GeoStoreClient.getCategories()
focal_class.full_signature: public CategoryList getCategories()
focal_class.identifier: getCategories
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: CategoryList
focal_class.signature: CategoryList getCategories()
focal_class.class_method_signature: GeoStoreClient.deleteCategory(Long id)
focal_class.full_signature: public void deleteCategory(Long id)
focal_class.identifier: deleteCategory
focal_class.modifiers: public
focal_class.parameters: (Long id)
focal_class.return: void
focal_class.signature: void deleteCategory(Long id)
focal_class.class_method_signature: GeoStoreClient.searchUserGroup(Integer start,Integer limit, String nameLike, boolean all)
focal_class.full_signature: public ExtGroupList searchUserGroup(Integer start,Integer limit, String nameLike, boolean all)
focal_class.identifier: searchUserGroup
focal_class.modifiers: public
focal_class.parameters: (Integer start,Integer limit, String nameLike, boolean all)
focal_class.return: ExtGroupList
focal_class.signature: ExtGroupList searchUserGroup(Integer start,Integer limit, String nameLike, boolean all)
focal_class.class_method_signature: GeoStoreClient.searchUserGroup(Integer start,Integer limit, String nameLike)
focal_class.full_signature: public ExtGroupList searchUserGroup(Integer start,Integer limit, String nameLike)
focal_class.identifier: searchUserGroup
focal_class.modifiers: public
focal_class.parameters: (Integer start,Integer limit, String nameLike)
focal_class.return: ExtGroupList
focal_class.signature: ExtGroupList searchUserGroup(Integer start,Integer limit, String nameLike)
focal_class.class_method_signature: GeoStoreClient.getShortResource(long id)
focal_class.full_signature: public ShortResource getShortResource(long id)
focal_class.identifier: getShortResource
focal_class.modifiers: public
focal_class.parameters: (long id)
focal_class.return: ShortResource
focal_class.signature: ShortResource getShortResource(long id)
focal_class.class_method_signature: GeoStoreClient.getBaseWebResource()
focal_class.full_signature: protected WebResource getBaseWebResource()
focal_class.identifier: getBaseWebResource
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.return: WebResource
focal_class.signature: WebResource getBaseWebResource()
focal_class.class_method_signature: GeoStoreClient.getBaseWebResource(Object... path)
focal_class.full_signature: protected WebResource getBaseWebResource(Object... path)
focal_class.identifier: getBaseWebResource
focal_class.modifiers: protected
focal_class.parameters: (Object... path)
focal_class.return: WebResource
focal_class.signature: WebResource getBaseWebResource(Object... path)
focal_class.class_method_signature: GeoStoreClient.getPassword()
focal_class.full_signature: public String getPassword()
focal_class.identifier: getPassword
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getPassword()
focal_class.class_method_signature: GeoStoreClient.setPassword(String password)
focal_class.full_signature: public void setPassword(String password)
focal_class.identifier: setPassword
focal_class.modifiers: public
focal_class.parameters: (String password)
focal_class.return: void
focal_class.signature: void setPassword(String password)
focal_class.class_method_signature: GeoStoreClient.getUsername()
focal_class.full_signature: public String getUsername()
focal_class.identifier: getUsername
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getUsername()
focal_class.class_method_signature: GeoStoreClient.setUsername(String username)
focal_class.full_signature: public void setUsername(String username)
focal_class.identifier: setUsername
focal_class.modifiers: public
focal_class.parameters: (String username)
focal_class.return: void
focal_class.signature: void setUsername(String username)
focal_class.class_method_signature: GeoStoreClient.getGeostoreRestUrl()
focal_class.full_signature: public String getGeostoreRestUrl()
focal_class.identifier: getGeostoreRestUrl
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getGeostoreRestUrl()
focal_class.class_method_signature: GeoStoreClient.setGeostoreRestUrl(String geostoreRestUrl)
focal_class.full_signature: public void setGeostoreRestUrl(String geostoreRestUrl)
focal_class.identifier: setGeostoreRestUrl
focal_class.modifiers: public
focal_class.parameters: (String geostoreRestUrl)
focal_class.return: void
focal_class.signature: void setGeostoreRestUrl(String geostoreRestUrl)
focal_method.body: public void updateSecurityRules(Long resourceId, SecurityRuleList rules)
      {
      	 getBaseWebResource("resources", "resource", resourceId, "permissions")
      	 	.header("Content-Type", MediaType.TEXT_XML)
                   .accept(MediaType.TEXT_PLAIN)
      	 	.post(rules);
      }
focal_method.class_method_signature: GeoStoreClient.updateSecurityRules(Long resourceId, SecurityRuleList rules)
focal_method.full_signature: public void updateSecurityRules(Long resourceId, SecurityRuleList rules)
focal_method.identifier: updateSecurityRules
focal_method.invocations: post accept header getBaseWebResource
focal_method.modifiers: public
focal_method.parameters: (Long resourceId, SecurityRuleList rules)
focal_method.return: void
focal_method.signature: void updateSecurityRules(Long resourceId, SecurityRuleList rules)