GenericDataModel ClassNReco.Recommender Class Library
A simple IDataModel which uses a given list of users as its data source. This implementation is mostly useful for small experiments and is not recommended for contexts where performance is important.
Inheritance Hierarchy

System Object
  NReco.CF.Taste.Impl.Model AbstractDataModel
    NReco.CF.Taste.Impl.Model GenericDataModel

Namespace: NReco.CF.Taste.Impl.Model
Assembly: NReco.Recommender (in NReco.Recommender.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax

[SerializableAttribute]
public sealed class GenericDataModel : AbstractDataModel

The GenericDataModel type exposes the following members.

Constructors

  NameDescription
Public methodGenericDataModel(FastByIDMap IPreferenceArray )
Creates a new GenericDataModel from the given users (and their preferences). This IDataModel retains all this information in memory and is effectively immutable.
Public methodGenericDataModel(IDataModel)
Creates a new GenericDataModel containing an immutable copy of the data from another given IDataModel.
Public methodGenericDataModel(FastByIDMap IPreferenceArray , FastByIDMap FastByIDMap Nullable DateTime   )
Creates a new GenericDataModel from the given users (and their preferences). This IDataModel retains all this information in memory and is effectively immutable.
Top
Methods

  NameDescription
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetItemIDs (Overrides AbstractDataModel GetItemIDs .)
Public methodGetItemIDsFromUser (Overrides AbstractDataModel GetItemIDsFromUser(Int64).)
Public methodGetMaxPreference (Inherited from AbstractDataModel.)
Public methodGetMinPreference (Inherited from AbstractDataModel.)
Public methodGetNumItems (Overrides AbstractDataModel GetNumItems .)
Public methodGetNumUsers (Overrides AbstractDataModel GetNumUsers .)
Public methodGetNumUsersWithPreferenceFor(Int64) (Overrides AbstractDataModel GetNumUsersWithPreferenceFor(Int64).)
Public methodGetNumUsersWithPreferenceFor(Int64, Int64) (Overrides AbstractDataModel GetNumUsersWithPreferenceFor(Int64, Int64).)
Public methodGetPreferencesForItem (Overrides AbstractDataModel GetPreferencesForItem(Int64).)
Public methodGetPreferencesFromUser (Overrides AbstractDataModel GetPreferencesFromUser(Int64).)
Public methodGetPreferenceTime (Overrides AbstractDataModel GetPreferenceTime(Int64, Int64).)
Public methodGetPreferenceValue (Overrides AbstractDataModel GetPreferenceValue(Int64, Int64).)
Public methodGetRawItemData
This is used mostly internally to the framework, and shouldn't be relied upon otherwise.
Public methodGetRawUserData
This is used mostly internally to the framework, and shouldn't be relied upon otherwise.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodGetUserIDs (Overrides AbstractDataModel GetUserIDs .)
Public methodHasPreferenceValues (Overrides AbstractDataModel HasPreferenceValues .)
Public methodRefresh (Overrides AbstractDataModel Refresh(IList IRefreshable ).)
Public methodRemovePreference (Overrides AbstractDataModel RemovePreference(Int64, Int64).)
Public methodSetPreference (Overrides AbstractDataModel SetPreference(Int64, Int64, Single).)
Public methodStatic memberToDataMap(IDataModel)
Exports the simple user IDs and preferences in the data model.
Public methodStatic memberToDataMap(FastByIDMap IList IPreference  , Boolean)
Public methodToString (Overrides Object ToString .)
Top
See Also