Method: AlfrescoAPI::QueriesApi#find_nodes_with_http_info
- Defined in:
- lib/alfresco_api/api/queries_api.rb
#find_nodes_with_http_info(term, opts = {}) ⇒ Array<(NodePaging, Fixnum, Hash)>
Find nodes Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets a list of nodes that match the given search criteria. The search term is used to look for nodes that match against name, title, description, full text content or tags. The search term: - must contain a minimum of 3 alphanumeric characters - allows "quoted term" - can optionally use '*' for wildcard matching By default, file and folder types will be searched unless a specific type is provided as a query parameter. By default, the search will be across the repository unless a specific root node id is provided to start the search from. You can sort the result list using the orderBy parameter. You can specify one or more of the following fields in the orderBy parameter: * name * modifiedAt * createdAt
52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 |
# File 'lib/alfresco_api/api/queries_api.rb', line 52 def find_nodes_with_http_info(term, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: QueriesApi.find_nodes ..." end # verify the required parameter 'term' is set if @api_client.config.client_side_validation && term.nil? fail ArgumentError, "Missing the required parameter 'term' when calling QueriesApi.find_nodes" end if @api_client.config.client_side_validation && !opts[:'skip_count'].nil? && opts[:'skip_count'] < 0 fail ArgumentError, 'invalid value for "opts[:"skip_count"]" when calling QueriesApi.find_nodes, must be greater than or equal to 0.' end if @api_client.config.client_side_validation && !opts[:'max_items'].nil? && opts[:'max_items'] < 1 fail ArgumentError, 'invalid value for "opts[:"max_items"]" when calling QueriesApi.find_nodes, must be greater than or equal to 1.' end # resource path local_var_path = "/queries/nodes" # query parameters query_params = {} query_params[:'term'] = term query_params[:'rootNodeId'] = opts[:'root_node_id'] if !opts[:'root_node_id'].nil? query_params[:'skipCount'] = opts[:'skip_count'] if !opts[:'skip_count'].nil? query_params[:'maxItems'] = opts[:'max_items'] if !opts[:'max_items'].nil? query_params[:'nodeType'] = opts[:'node_type'] if !opts[:'node_type'].nil? query_params[:'include'] = @api_client.build_collection_param(opts[:'include'], :csv) if !opts[:'include'].nil? query_params[:'orderBy'] = @api_client.build_collection_param(opts[:'order_by'], :csv) if !opts[:'order_by'].nil? query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['basicAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'NodePaging') if @api_client.config.debugging @api_client.config.logger.debug "API called: QueriesApi#find_nodes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |