org.powerscala.datastore.impl.mongodb

MongoDBDatastore

class MongoDBDatastore extends Datastore

Linear Supertypes
Datastore, Listenable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. MongoDBDatastore
  2. Datastore
  3. Listenable
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new MongoDBDatastore(host: String = "localhost", port: Int = 27017, database: String = "datastore")

Type Members

  1. class ConvertFunction extends (String, Any, EnhancedClass) ⇒ Any

    Definition Classes
    Datastore

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. def alias(f: (Class[_]) ⇒ Option[String]): Unit

    Definition Classes
    Datastore
  7. final def aliasName(name: String, clazz: Class[_]): String

    Allows overriding the collection name being utilized for the datastore.

    Allows overriding the collection name being utilized for the datastore.

    Defaults to return the same value passed in or the simple class name if name is null.

    Definition Classes
    Datastore
  8. def apply[T](f: (DatastoreSession) ⇒ T): T

    Executes the supplied function within a local session.

    Executes the supplied function within a local session. If a session already exists it will be utilized or a new one will be created and terminated upon completion of the session block.

    f

    the function to execute within the session

    returns

    the result from the function

    Definition Classes
    Datastore
  9. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  10. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. def collection[T <: Identifiable, R](f: (DatastoreCollection[T]) ⇒ R)(implicit manifest: Manifest[T]): R

    Definition Classes
    Datastore
  12. def collectionNameForClass(clazz: Class[_]): String

    Definition Classes
    Datastore
  13. lazy val connection: MongoClient

  14. def convert(name: String, value: Any, resultType: EnhancedClass, values: Map[String, Any]): Any

    Called during deserialization from the datastore to support conversion from one type (what is persisted in the datastore) to another type (what is represented in the class structure).

    Called during deserialization from the datastore to support conversion from one type (what is persisted in the datastore) to another type (what is represented in the class structure). This can be useful for refactors of the class structure without having to immediately update the datastore.

    name

    the name of the field for this value being converted

    value

    the value found in the datastore

    resultType

    the expected result type

    values

    the other values for the other fields for this conversion

    returns

    value converted to resultType

    Definition Classes
    Datastore
  15. val convertFunction: ConvertFunction

    Attributes
    protected[org.powerscala.datastore]
    Definition Classes
    Datastore
  16. val convertValues: LocalStack[Map[String, Any]]

    Attributes
    protected[org.powerscala.datastore]
    Definition Classes
    Datastore
  17. def createCollection[T <: Identifiable](name: String, session: DatastoreSession, creator: (String) ⇒ DatastoreCollection[T])(implicit manifest: Manifest[T]): DatastoreCollection[T]

    Called by DatastoreSession to create an instance of a DatastoreCollection.

    Called by DatastoreSession to create an instance of a DatastoreCollection.

    By default this method simply invokes: creator(name)

    T

    the type of collection to be created

    name

    the name of this collection

    session

    the current session the collection is to be created with

    creator

    the default creator function

    returns

    DatastoreCollection[T]

    Definition Classes
    Datastore
  18. def createSession(): MongoDBDatastoreSession

    returns

    a new session for use with this datastore

    Attributes
    protected
    Definition Classes
    MongoDBDatastoreDatastore
  19. def createSessionForThread(): Boolean

    Definition Classes
    Datastore
  20. def createdCollection[T <: Identifiable](name: String, session: DatastoreSession, collection: DatastoreCollection[T])(implicit manifest: Manifest[T]): Unit

    Definition Classes
    Datastore
  21. def creatingCollection[T <: Identifiable](name: String, session: DatastoreSession)(implicit manifest: Manifest[T]): Unit

    Definition Classes
    Datastore
  22. val database: String

  23. val deletes: DatastoreDeleteProcessor

    Definition Classes
    Datastore
  24. def disconnect(): Unit

    Definition Classes
    Datastore
  25. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  26. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  27. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  28. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  29. var globalize: Boolean

    If set to true, all Identifiable objects will be be cross-persisted to their own collection when persisted as part of another collection.

    If set to true, all Identifiable objects will be be cross-persisted to their own collection when persisted as part of another collection.

    For example, if Person class had a reference to Address and Address is Identifiable, then Address will also be persisted to the Address collection if globalize is set to true.

  30. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  31. val host: String

  32. def indexes: List[Field[_, _]]

    Indexes that need to be defined for this Datastore.

    Indexes that need to be defined for this Datastore.

    Definition Classes
    Datastore
  33. def initializeCollection[T <: Identifiable](name: String, session: DatastoreSession, collection: DatastoreCollection[T], clazz: Class[_]): Unit

    Definition Classes
    Datastore
  34. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  35. def listen[Event, Response, Result](name: String, priority: Priority, modes: ListenMode*)(f: (Event) ⇒ Response)(implicit eventManifest: Manifest[Event]): FunctionalListener[Event, Response]

    Definition Classes
    Listenable
  36. val listeners: Listeners

    Definition Classes
    Listenable
  37. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  38. final def notify(): Unit

    Definition Classes
    AnyRef
  39. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  40. def parent: Null

    Definition Classes
    Datastore
  41. val persists: DatastorePersistProcessor

    Definition Classes
    Datastore
  42. val port: Int

  43. def register(clazz: Class[_]): Unit

    Creates an alias for all classes that are subclasses of clazz to map to the clazz.

    Creates an alias for all classes that are subclasses of clazz to map to the clazz.getSimpleName.

    clazz

    Definition Classes
    Datastore
  44. def session: MongoDBDatastoreSession

    returns

    the existing session for this thread or null if one does not exist.

    Definition Classes
    MongoDBDatastoreDatastore
  45. def shutdown(): Unit

  46. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  47. implicit val thisListenable: Listenable

    Definition Classes
    Listenable
  48. def toString(): String

    Definition Classes
    AnyRef → Any
  49. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  50. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  51. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Datastore

Inherited from Listenable

Inherited from AnyRef

Inherited from Any

Ungrouped