UserProductSearchQueryConfiguration class

Get products a user created, photographed,

Deprecated, use standard queries instead

  UserProductSearchQueryConfiguration configuration =
      UserProductSearchQueryConfiguration(
    // Products user photographed
    type: UserProductSearchType.PHOTOGRAPHER,
    userId: '',
  );

  SearchResult result = await OpenFoodAPIClient.searchProducts(
    User(userId: '', password: ''),
    configuration,
  );

  print(result.count);
´´´
Inheritance
Annotations

Constructors

UserProductSearchQueryConfiguration({required UserProductSearchType type, required String userId, OpenFoodFactsLanguage? language, List<OpenFoodFactsLanguage> languages = const [], List<ProductField>? fields, int? pageNumber, int? pageSize})

Properties

additionalParameters List<Parameter>
getter/setter pairinherited
country OpenFoodFactsCountry?
The country for this query, if any.
finalinherited
fields List<ProductField>?
Defines which ProductFields are retrieved.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
language OpenFoodFactsLanguage?
Use to set the desired product language. Cannot be used together with the languages field. See also the comment to the languages field.
getter/setter pairinherited
languages List<OpenFoodFactsLanguage>?
The languages field should be used when a product is requested with fields in multiple languages. I.e.:
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
type UserProductSearchType
final
userId String
final

Methods

computeCountryCode() String?
inherited
getParametersMap() Map<String, String>
Returns the corresponding API URI parameter map
override
getResponse(User? user, QueryType? queryType) Future<Response>
Performs the query, do not use directly please use dedicates methods in OpenFoodAPIClient
inherited
getUriPath() String
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited