public class Breinify
extends java.lang.Object
| Constructor and Description |
|---|
Breinify() |
| Modifier and Type | Method and Description |
|---|---|
static void |
activity()
Sends an activity to the engine utilizing the API.
|
static void |
activity(BreinUser user,
java.lang.String activityType,
java.lang.String categoryType,
java.lang.String description)
Sends an activity to the engine utilizing the API.
|
static void |
activity(BreinUser user,
java.lang.String activityType,
java.lang.String categoryType,
java.lang.String description,
java.util.function.Function<java.lang.String,java.lang.Void> errorCallback)
Sends an activity to the engine utilizing the API.
|
static BreinActivity |
getBreinActivity() |
static BreinLookup |
getBreinLookup() |
static BreinRecommendation |
getBreinRecommendation() |
static BreinTemporalData |
getBreinTemporalData() |
static BreinConfig |
getConfig()
gets the config
|
static BreinResult |
lookup(BreinLookup breinLookup,
BreinUser user,
BreinDimension dimension)
Retrieves a lookup result from the engine.
|
static BreinResult |
lookup(BreinUser user,
BreinDimension dimension)
Retrieves a lookup result from the engine.
|
static BreinResult |
recommendation(BreinRecommendation breinRecommendationPara)
Sends a recommendation request to the engine utilizing the API.
|
static void |
setConfig(BreinConfig breinConfig)
sets the configuration
|
static void |
shutdown()
Shutdown Breinify services
|
static BreinResult |
temporalData(BreinTemporalData breinTemporalData,
BreinUser user)
Sends a temporalData to the engine utilizing the API.
|
static BreinResult |
temporalData(BreinUser user)
Sends a temporalData to the engine utilizing the API.
|
public static void setConfig(BreinConfig breinConfig)
breinConfig - config objectpublic static BreinConfig getConfig()
public static BreinActivity getBreinActivity()
public static BreinLookup getBreinLookup()
public static BreinTemporalData getBreinTemporalData()
public static BreinRecommendation getBreinRecommendation()
public static void activity(BreinUser user, java.lang.String activityType, java.lang.String categoryType, java.lang.String description, java.util.function.Function<java.lang.String,java.lang.Void> errorCallback)
This request is asynchronous.
user - a plain object specifying the user information the activity belongs toactivityType - the type of the activity collected, i.e., one of search, login, logout, addToCart,
removeFromCart, checkOut, selectProduct, or other. if not specified, the default other will
be usedcategoryType - the category of the platform/service/products, i.e., one of apparel, home, education, family,
food, health, job, services, or otherdescription - a string with further information about the activity performederrorCallback - a callback function that is invoked in case of an error (can be null)public static void activity(BreinUser user, java.lang.String activityType, java.lang.String categoryType, java.lang.String description)
This request is asynchronous.
user - a plain object specifying the user information the activity belongs toactivityType - the type of the activity collected, i.e., one of search, login, logout, addToCart,
removeFromCart, checkOut, selectProduct, or other. if not specified, the default other will
be usedcategoryType - the category of the platform/service/products, i.e., one of apparel, home, education, family,
food, health, job, services, or otherdescription - a string with further information about the activity performedpublic static void activity()
// retrieve BreinActivity instance from Breinify class BreinActivity breinActivity = Breinify.getBreinActivity();
// set methods as desired to breinActivity (for instance) breinActivity.setBreinUser(new BreinUser("user.name@email.com"); ...
// invoke this method Breinify.activity();
This request is asynchronous.
public static BreinResult lookup(BreinUser user, BreinDimension dimension)
This request is synchronous.
user - a plain object specifying information about the user to retrieve data for.dimension - an object (with an array) containing the names of the dimensions to lookup.public static BreinResult lookup(BreinLookup breinLookup, BreinUser user, BreinDimension dimension)
This request is synchronous.
breinLookup - a plain object specifying the lookup information.user - a plain object specifying information about the user to retrieve data for.dimension - an object (with an array) containing the names of the dimensions to lookup.public static BreinResult temporalData(BreinUser user)
Furthermore it uses the internal instance of BreinTemporalData.
user - a plain object specifying information about the user to retrieve data for.public static BreinResult temporalData(BreinTemporalData breinTemporalData, BreinUser user)
breinTemporalData - a plain object specifying the information of the temporaldata.user - a plain object specifying information about the user to retrieve data for.public static BreinResult recommendation(BreinRecommendation breinRecommendationPara)
breinRecommendationPara - contains the brein recommendation objectpublic static void shutdown()
Copyright © Breinify - All Rights Reserved.