List of functions
This is a complete list of all the functions you can use inside our framework.
Customer Management
Use these functions to manage an Object_Customer.
- Preferabli.main().loginCustomer(String merchant_customer_identification, String merchant_customer_verification, API_ResultHandler<Object_Customer> handler)
- Preferabli.main().getCustomer(Boolean force_refresh, API_ResultHandler<Object_Customer> handler)
- Preferabli.main().logout(API_ResultHandler<Boolean> handler)
Unauthenticated Actions
These functions return generic, non user-specific results.
- Preferabli.main().searchProducts(String query, Boolean lock_to_integration, ArrayList<Object_Product.Other_ProductCategory> product_categories, ArrayList<Object_Product.Other_ProductType> product_types, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
- Preferabli.main().labelRecognition(File label_file, Boolean include_merchant_links, API_ResultHandler<Object_LabelRecResults> handler)
- Preferabli.main().getGuidedRec(long guided_rec_id, API_ResultHandler<Object_GuidedRec> handler)
- Preferabli.main().getGuidedRecResults(long guided_rec_id, ArrayList<Long> selected_choice_ids, Integer price_min, Integer price_max, Long collection_id, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
- Preferabli.main().whereToBuy(long product_id, Other_FulfillSort fulfill_sort, Boolean append_nonconforming_results, Boolean lock_to_integration, API_ResultHandler<Object_WhereToBuy> handler)
- Preferabli.main().lttt(long product_id, Integer year, Long collection_id, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
Authenticated Actions
These functions require an authenticated user. They are user specific actions that help deliver a personalized experience.
- Preferabli.main().rateProduct(long product_id, int year, Object_Tag.Other_RatingLevel rating, String location, String notes, Double price, Integer quantity, Integer format_ml, API_ResultHandler<Object_Product> handler)
- Preferabli.main().wishlistProduct(long product_id, int year, String location, String notes, Double price, Integer quantity, Integer format_ml, API_ResultHandler<Object_Product> handler)
- Preferabli.main().getProfile(Boolean force_refresh, API_ResultHandler<Object_Profile> handler)
- Preferabli.main().getFoods(API_ResultHandler<ArrayList<Object_Food>> handler)
- Preferabli.main().getRecs(Object_Product.Other_ProductCategory product_category, Object_Product.Other_ProductType product_type, Long collection_id, Integer price_min, Integer price_max, ArrayList<Long> style_ids, ArrayList<Long> food_ids, Boolean include_merchant_links, API_ResultHandler<Object_Recommendation> handler)
- Preferabli.main().getRatedProducts(Boolean force_refresh, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
- Preferabli.main().getWishlistedProducts(Boolean force_refresh, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
- Preferabli.main().getPurchasedProducts(Boolean force_refresh, Boolean lock_to_integration, Boolean include_merchant_links, API_ResultHandler<ArrayList<Object_Product>> handler)
- Preferabli.main().deleteTag(long tag_id, API_ResultHandler<Object_Product> handler)
- Preferabli.main().getPreferabliProductId(String merchant_product_id, String merchant_variant_id, API_ResultHandler<Long> handler)
Static Functions
Static functions are called without using themain()instance.See examples below.
The Preferabli class also provides these helpful class utility methods:
- Preferabli.initialize(Application application, String client_interface, Long integration_id)
- Preferabli.isCustomerLoggedIn()
- Preferabli.getPoweredByPreferabliLogo(Boolean light_background)
Updated about 1 year ago
What’s Next
For a more in depth of analysis of our functionalities, please check:
