public boolean isCollection(String target){
  return target.endsWith("/");
}

public boolean isCollection ( String target ) { return target . endsWith ( "/" ) ; }
returns true if the given name or path belongs to a collection . in this case ends with a slash .
