nutrition_ai_module library

Classes

AmountEstimate
Data class that represents the results of the volume detection process.
BarcodeCandidate
Data class that represents the results of the barcode detection process.
DetectedCandidate
Class that represents the results of the food detection process.
Error
A final class representing an error result of an operation.
FoodCandidates
Data class that represents the results of the SDK's detection process.
FoodDetectionConfiguration
Configuration object used to define a recognition session.
FoodRecognitionListener
Used as a callback to receive results from analyzing camera frames.
FoodRecord
Represents a record of food items, including their ingredients, serving sizes, and other properties.
FoodRecordIngredient
Represents an ingredient of a food record.
InflammatoryEffectData
Represents a nutrient associated with an inflammatory effect score.
NutritionAdvisor
A singleton class that provides access to the Nutrition AI Advisor API.
NutritionAI
Singleton class to interact with NutritionAI SDK.
NutritionAIModule
The NutritionAIModule class is a singleton that handles the initialization and configuration of the Nutrition AI module. It manages the connection to different storage connectors and sets up the user interface and user profile.
NutritionFactsRecognitionListener
Interface for listening to nutrition facts recognition events.
PackagedFoodCandidate
Represents the result of the packaged food detection process.
PassioAccountListener
An abstract interface class for listening to updates on token budgets.
PassioAdvisorFoodInfo
Represents information about a food item recognized by the Passio Advisor.
PassioAdvisorResponse
Represents the response from the Passio Advisor.
PassioAlternative
Represents an alternative option for a food item.
PassioCameraZoomLevel
This class represents the camera zoom levels, including minimum and maximum values.
PassioConfiguration
A PassioConfiguration object must be constructed to configure the SDK. The configuration process depends on the location of the files needed for the SDK to work. There are three different ways to configure the SDK depending on the attributes of the object.
PassioConnector
PassioFoodAmount
Represents the amount of a food item, including selected quantity and unit, serving sizes, and serving units.
PassioFoodDataInfo
A class representing detailed information about a food item.
PassioFoodIcons
The defaultIcon represents one of five predefined icons shipped with the SDK, base on the food item's PassioIDEntityType.
PassioFoodItem
Represents a food item with its details, amount, ingredients, and nutritional information.
PassioFoodItemData
Data class that contains the nutritional information for a single food item.
PassioFoodMetadata
Represents metadata associated with a particular food item.
PassioFoodOrigin
The origin of the data for a given food item of the nutritional database.
PassioFoodRecipe
Data class the holds the nutritional information of a food item that is classified as a recipe. A recipe has multiple ingredients, but their quantity is controlled by a single selectedUnit and selectedQuantity.
PassioIcon
PassioIDAttributes
Data class that represent an entry in the SDK's nutritional database.
PassioIngredient
Represents an ingredient within a food item, including its amount, metadata, name, and reference nutrients.
PassioMealPlan
Class representing a meal plan.
PassioMealPlanItem
Class representing a meal plan item.
PassioNutrients
Represents the nutritional information of a food item, including various nutrients and their quantities.
PassioNutritionFacts
A class representing the nutritional facts of a food item.
PassioPreview
Widget that is used to display the camera preview and the frames being processed by the NutritionAI SDK.
PassioResult<T>
A sealed class representing the result of an operation, which can either be a success or an error.
PassioSearchNutritionPreview
Represents a preview of the nutritional information for a food item,
PassioSearchResponse
Represents the response from a food search API, containing search results and alternate names for the searched food item.
PassioServingSize
Data class that represents the serving sizes of a food item.
PassioServingUnit
Data class that represents the serving unit of a food item.
PassioSpeechRecognitionModel
Represents a speech recognition model.
PassioStatus
Object that is returned as a result of the configuration process.
PassioStatusListener
PassioTokenBudget
This class holds information about the API name, the budget cap, the tokens used in a certain period, and the total usage for that period.
PlatformImage
Native representation of an image.
Success<T>
A final class representing a successful result of an operation.
Unit
Base class used to create units for mass, energy, etc.
UnitEnergy
Class that represents a measurement of energy.
UnitIU
Class that represents a measurement of IU.
UnitMass
Class that represents a measurement of mass.
UserProfileModel
A class representing a user's profile model.
VoidType
A class representing a void type.
WaterRecord
A class representing a water consumption record.
WeightRecord
A class representing a weight record.

Enums

ActivityLevel
Represents different levels of activity.
CalorieDeficit
Represents different options for calorie deficit or surplus.
Conversion
EstimationQuality
Enum representing the quality of an estimation.
FramesPerSecond
Enumeration for the frames per second options.
GenderSelection
Represents the gender selection options.
HeightUnit
Represents units for height measurements.
IconSize
Enumeration for icon sizes.
MeasurementSystem
Represents different measurement systems for units.
MoveDirection
Enum representing different move directions.
PassioFoodResultType
Represents different types of results that can be returned from food recognition.
PassioIDEntityType
Defines different categories of food items provided by the SDK.
PassioImageResolution
Represents different image resolution options.
PassioLogAction
Defines different log actions that can be performed.
PassioMealTime
Represents the different times of day for meals.
PassioMode
PassioSDKError
UnitEnergyType
UnitMassType
VolumeDetectionMode
Enumeration for the volume detection mode options.
WaterUnits
Represents units for water volume measurements.
WeightUnits
Represents units for weight measurements.

Extensions

FoodRecordExtension on FoodRecord
Extension to calculate and retrieve nutritional values for a single FoodRecord object.
FoodRecordListExtension on List<FoodRecord>
Extension to calculate the sum of nutritional values for a list of FoodRecord objects.
IconSizeExtension on IconSize
Extension on the IconSize enum to provide a URL-friendly size string.

Typedefs

Barcode = String
Identifier of a product code scanned from a barcode.
PackagedFoodCode = String
Identifier of a product code scanned from a package.
PassioID = String
Identifier of food items in the NutritionAI's database.