IRPCSearch.GetFolderObjectsCount
Vault API / core read session or assertion idempotent returns metadata structure version
Gets the count of objects in the specified folder.
| Service | Search MFiles.IRPCSearch |
|---|---|
| gRPC method | /MFiles.IRPCSearch/GetFolderObjectsCount |
| HTTP (mf-http-grpc) | POST /grpc/v1/get-folder-objects-count |
| Request | GetFolderObjectsCountRequest |
| Response | GetFolderObjectsCountResponse |
| Book and level | Vault API, core |
| Kind | read |
| Session | Required: a session (mfiles-session-id-bin metadata) or a session assertion (x-mf-session-assertion metadata). |
| Idempotent | yes |
| Returns metadata structure version | yes (in the mfiles-metadata-version-bin trailer) |
| Streaming | none (unary) |
Remarks
Used by the M-Files clients to show object counts in folder listings. To count the results of a search, use GetObjectCountInSearch.
Request: GetFolderObjectsCountRequest
Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.
| Field | Type | Description |
|---|---|---|
callimp | CallImportance | The importance level of this call. Typically CALL_IMPORTANCE_NORMAL.Values: CALL_IMPORTANCE_DEFAULT (0), CALL_IMPORTANCE_NORMAL (1), CALL_IMPORTANCE_CAN_BE_REJECTED (2). |
search_options | SearchTarget | Search options. |
search_options.index | string | The name of the search index to use. Empty uses the vault's default index. An unknown name fails with "Target index is not available." |
search_options.mode | SearchMode | Whether to prefer, require or avoid the full-text search engine. See SearchMode.Values: SEARCH_MODE_DEFAULT (0), SEARCH_MODE_FAVOR_FULL_TEXT_SEARCH (1), SEARCH_MODE_REQUIRE_FULL_TEXT_SEARCH (2), SEARCH_MODE_REQUIRE_DATABASE_SEARCH (3). |
search_options.search_master_storage | bool | True to also search objects kept in Master Storage, where the vault supports it. |
search_options.continuation_token | string | Continuation token for paging results from Master Storage. SearchObjects does not support it and fails with "Continuation token is not supported." when it is set together with search_master_storage. |
parent[] | repeated Folder | Describes the parent folder. |
parent[].type | FolderType | The type of the folder, for example FOLDER_TYPE_VIEW_FOLDER or FOLDER_TYPE_PROPERTY_FOLDER.Values: FOLDER_TYPE_UNKNOWN (0), FOLDER_TYPE_ANY_FOLDER (1), FOLDER_TYPE_VIEW_FOLDER (2), FOLDER_TYPE_PROPERTY_FOLDER (3), FOLDER_TYPE_TRADITIONAL_FOLDER (4), FOLDER_TYPE_SEARCH_FOLDER (5), FOLDER_TYPE_EXTERNAL_VIEW_FOLDER (6). |
parent[].data | FolderInfoUnion | Additional folder type -specific information as a union. |
parent[].data.any_folder | FolderInfoUnion.AnyFolderData (oneof data) | Any folder type. |
parent[].data.view_folder | FolderInfoUnion.ViewFolderData (oneof data) | View folder type. |
parent[].data.property_folder | FolderInfoUnion.PropertyFolderData (oneof data) | Property (virtual) folder type. |
parent[].data.traditional_folder | FolderInfoUnion.TraditionalFolderData (oneof data) | Traditional folder type. |
parent[].data.search_folder | FolderInfoUnion.SearchFolderData (oneof data) | Search folder (extended view folder) type. |
parent[].data.external_view_folder | FolderInfoUnion.ExternalViewFolderData (oneof data) | External view folder type. |
facetsearchflags | FACETSEARCHFLAGS | Facet search flags. Ignored if bFacetMode is false. |
facetsearchflags.all | bool | Specifies all flags set; Including any future flags. |
facetsearchflags.enabled | bool | Facet search is enabled. |
facetsearchflags.ignore_search_permissions | bool | No ACL check on facet search. |
facetsearchflags.ignore_group_permissions | bool | No ACL check on facet groups. |
facetsearchflags.ignore_value_permissions | bool | No ACL check on individual facet values. |
facetsearchflags.sort_facets | bool | Sort facet values in descending occurrence order within each facet group. |
facetsearchflags.ascending_order | bool | If SortFacetValues is present, sort facet values in ascending occurrence order within each facet group. |
srcrequestarr[] | repeated SearchResultsCountRequest | Search results count requests. |
srcrequestarr[].group_id | int32 | The identifier of a search results group. |
srcrequestarr[].count_threshold | uint32 | Threshold for the count. If zero, it should be ignored. A non-zero value specifies that the caller does not request an exact count if it is greater than this threshold value. If a real count is smaller than or equal this threshold, it is reported as an exact count. |
max_objects_limit_for_groups | uint32 | The OT specific limit for object count. |
facet_filter | StringValue | If set, specifies the additional facet search filter. |
facet_filter.value | string | String. |
Response: GetFolderObjectsCountResponse
Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.
| Field | Type | Description |
|---|---|---|
psrcountarr[] | repeated SearchResultsCount | Resulting search results counts. |
psrcountarr[].group_id | int32 | The group that was counted: an object type ID, or -100 for all object types. |
psrcountarr[].flags | SRCOUNTFLAGS | How to read count: exact_measure if exact, more_than if more objects match. |
psrcountarr[].flags.all | bool | Specifies all flags set; Including any future flags. |
psrcountarr[].flags.exact_measure | bool | If available, the reported result count is an exact measure. |
psrcountarr[].flags.more_than | bool | If available, the reported result count is not an exact measure but it indicates that an exact count is more than the reported count. |
psrcountarr[].flags.multi_phase_initial | bool | If available, the reported result count is based on the added items only. |
psrcountarr[].flags.multi_phase_count_only | bool | If available, the reported result count is to be associated with a group without actual results. |
psrcountarr[].flags.multi_phase | bool | If available, the reported result count supports multi-phase search, and it is to be associated with the initial result count rather than the total count. |
psrcountarr[].flags.additional_items | bool | Identifies a search results count. |
psrcountarr[].count | uint32 | The number of matching objects. |
psearchstatusflags | SEARCHSTATUSFLAGS | Receives search status flags. |
psearchstatusflags.all | bool | Specifies all flags set; Including any future flags. |
psearchstatusflags.multiphase_object_type_search_needed | bool | Multi-phase OT search is needed. |
psearchstatusflags.wildcard_expansion_limit_exceeded | bool | Wildcard expansion limit has been exceeded (but some results has been returned anyway). |
psearchstatusflags.may_contain_stale_data | bool | Data returned by search may be out of date. |
psearchstatusflags.resorted_to_default_sort | bool | Requested sorting is not supported and result set was established using the default sorting (relevance). |
psearchstatusflags.resorted_to_default_sort_too_many_results | bool | Requested sorting is not supported and result set was established using the default sorting (relevance) because there are too many matching results for sorting. |
psearchstatusflags.sorted_by_engine | bool | Data returned by search was sorted by the engine (Global Sorting). |
search_output_info | SearchOutputInfo | Additional information about the completed search operation. |
search_output_info.processing_time_at_engine_in_milliseconds | int32 | The processing time at the search engine, in milliseconds. -1 if not known. |
search_output_info.processing_time_at_engine_from_mfserver_in_milliseconds | int32 | The processing time at the search engine, including network roundtrip from MFServer, in milliseconds. -1 if not known. |
search_output_info.processing_time_at_mfserver_in_milliseconds | int32 | The total processing time at MFServer, in milliseconds. -1 if not known. |
search_output_info.processing_time_at_mfserver_from_client_in_milliseconds | int32 | The total processing time at MFServer, including network roundtrip from the client, in milliseconds. -1 if not known. |
Related methods
- GetObjectCountInSearch -- Counts the objects that match the given conditions without returning them.