VkNet.Categories.GroupsCategory.Search C# (CSharp) Méthode

Search() private méthode

private Search ( [ query, int &totalCount, uint offset = null, uint count = null, GroupSort sort = GroupSort.Normal, GroupType type = null, uint countryId = null, uint cityId = null, bool future = false ) : ReadOnlyCollection
query [
totalCount int
offset uint
count uint
sort GroupSort
type GroupType
countryId uint
cityId uint
future bool
Résultat ReadOnlyCollection
        public ReadOnlyCollection<Group> Search([NotNull] string query, out int totalCount, uint? offset = null, uint? count = null, GroupSort sort = GroupSort.Normal, GroupType type = null, uint? countryId = null, uint? cityId = null, bool future = false)
        {
            VkErrors.ThrowIfNullOrEmpty(() => query);

            var parameters = new GroupsSearchParams
            {
                Query = query,
                Sort = sort,
                Count = count,
                Offset = offset,
                Type = type,
                CityId = cityId,
                CountryId = countryId,
                Future = future
            };
            var result = Search(parameters);

            totalCount = Convert.ToInt32(result.TotalCount);

            return result.ToReadOnlyCollection();
        }

Same methods

GroupsCategory::Search ( int &totalCount, GroupsSearchParams @params ) : ReadOnlyCollection
GroupsCategory::Search ( GroupsSearchParams @params, bool skipAuthorization = false ) : VkCollection

Usage Example

Exemple #1
0
		public void Search_EmptyQuery_ThrowsArgumentException()
		{
			int totalCount;

			var groups = new GroupsCategory(new VkApi { AccessToken = "token" });
			This.Action(() => groups.Search("", out totalCount)).Throws<ArgumentNullException>();
		}
All Usage Examples Of VkNet.Categories.GroupsCategory::Search