commit 897a334bf6d0b1d5974427b518e777e7f0934672 Author: Will Bradley Date: Fri Dec 1 19:35:11 2017 -0800 Initial commit diff --git a/build.docset/Contents/Info.plist b/build.docset/Contents/Info.plist new file mode 100644 index 0000000..a14accc --- /dev/null +++ b/build.docset/Contents/Info.plist @@ -0,0 +1,18 @@ + + + + + CFBundleIdentifier + build + CFBundleName + build + DashDocSetFamily + python + DocSetPlatformFamily + build + isDashDocset + + isJavaScriptEnabled + + + diff --git a/build.docset/Contents/Resources/Documents/.buildinfo b/build.docset/Contents/Resources/Documents/.buildinfo new file mode 100644 index 0000000..445bf8b --- /dev/null +++ b/build.docset/Contents/Resources/Documents/.buildinfo @@ -0,0 +1,4 @@ +# Sphinx build info version 1 +# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. +config: b9a0aa75b165bda23dea90cac5cdb554 +tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/blending-orm-and-mongodb-odm.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/blending-orm-and-mongodb-odm.doctree new file mode 100644 index 0000000..5da3045 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/blending-orm-and-mongodb-odm.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-array-access-for-domain-objects.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-array-access-for-domain-objects.doctree new file mode 100644 index 0000000..2f20eb6 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-array-access-for-domain-objects.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-the-notify-changetracking-policy.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-the-notify-changetracking-policy.doctree new file mode 100644 index 0000000..cc78bfb Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-the-notify-changetracking-policy.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-wakeup-or-clone.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-wakeup-or-clone.doctree new file mode 100644 index 0000000..e8fadc8 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/implementing-wakeup-or-clone.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/mapping-classes-to-orm-and-odm.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/mapping-classes-to-orm-and-odm.doctree new file mode 100644 index 0000000..6b812a0 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/mapping-classes-to-orm-and-odm.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/resolve-target-document-listener.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/resolve-target-document-listener.doctree new file mode 100644 index 0000000..0df07d0 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/resolve-target-document-listener.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/simple-search-engine.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/simple-search-engine.doctree new file mode 100644 index 0000000..7b6064b Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/simple-search-engine.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/soft-delete-extension.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/soft-delete-extension.doctree new file mode 100644 index 0000000..beb98d2 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/soft-delete-extension.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/cookbook/validation-of-documents.doctree b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/validation-of-documents.doctree new file mode 100644 index 0000000..23f0a77 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/cookbook/validation-of-documents.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/environment.pickle b/build.docset/Contents/Resources/Documents/.doctrees/environment.pickle new file mode 100644 index 0000000..b30813e Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/environment.pickle differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/index.doctree b/build.docset/Contents/Resources/Documents/.doctrees/index.doctree new file mode 100644 index 0000000..f8b8cd6 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/index.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/aggregation-builder.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/aggregation-builder.doctree new file mode 100644 index 0000000..b090daf Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/aggregation-builder.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/annotations-reference.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/annotations-reference.doctree new file mode 100644 index 0000000..f249a44 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/annotations-reference.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/architecture.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/architecture.doctree new file mode 100644 index 0000000..ae2aaa3 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/architecture.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/basic-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/basic-mapping.doctree new file mode 100644 index 0000000..d69c4bb Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/basic-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/best-practices.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/best-practices.doctree new file mode 100644 index 0000000..7c490b9 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/best-practices.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/bidirectional-references.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/bidirectional-references.doctree new file mode 100644 index 0000000..41ad65d Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/bidirectional-references.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/capped-collections.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/capped-collections.doctree new file mode 100644 index 0000000..3c1b603 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/capped-collections.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/change-tracking-policies.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/change-tracking-policies.doctree new file mode 100644 index 0000000..3bc89d6 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/change-tracking-policies.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/complex-references.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/complex-references.doctree new file mode 100644 index 0000000..833ac3d Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/complex-references.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/console-commands.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/console-commands.doctree new file mode 100644 index 0000000..9c85ecc Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/console-commands.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/custom-collections.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/custom-collections.doctree new file mode 100644 index 0000000..3732d63 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/custom-collections.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/document-repositories.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/document-repositories.doctree new file mode 100644 index 0000000..3087cc5 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/document-repositories.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/eager-cursors.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/eager-cursors.doctree new file mode 100644 index 0000000..7227b45 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/eager-cursors.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/embedded-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/embedded-mapping.doctree new file mode 100644 index 0000000..40906f4 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/embedded-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/events.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/events.doctree new file mode 100644 index 0000000..c0e374b Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/events.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/filters.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/filters.doctree new file mode 100644 index 0000000..4b96b80 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/filters.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/find-and-update.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/find-and-update.doctree new file mode 100644 index 0000000..58f7ac8 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/find-and-update.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/geospatial-queries.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/geospatial-queries.doctree new file mode 100644 index 0000000..06fc5e5 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/geospatial-queries.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/indexes.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/indexes.doctree new file mode 100644 index 0000000..056f1ae Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/indexes.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/inheritance-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/inheritance-mapping.doctree new file mode 100644 index 0000000..4ba7a3d Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/inheritance-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/introduction.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/introduction.doctree new file mode 100644 index 0000000..8a41f7b Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/introduction.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/logging.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/logging.doctree new file mode 100644 index 0000000..ff07527 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/logging.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/map-reduce.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/map-reduce.doctree new file mode 100644 index 0000000..54287a9 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/map-reduce.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/metadata-drivers.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/metadata-drivers.doctree new file mode 100644 index 0000000..b1f2133 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/metadata-drivers.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/migrating-schemas.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/migrating-schemas.doctree new file mode 100644 index 0000000..521c53e Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/migrating-schemas.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/priming-references.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/priming-references.doctree new file mode 100644 index 0000000..41dbf26 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/priming-references.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/query-builder-api.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/query-builder-api.doctree new file mode 100644 index 0000000..c95aa9d Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/query-builder-api.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/reference-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/reference-mapping.doctree new file mode 100644 index 0000000..9d1f5ff Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/reference-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/sharding.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/sharding.doctree new file mode 100644 index 0000000..25b9f18 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/sharding.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/slave-okay-queries.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/slave-okay-queries.doctree new file mode 100644 index 0000000..dca2f78 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/slave-okay-queries.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/storage-strategies.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/storage-strategies.doctree new file mode 100644 index 0000000..b074777 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/storage-strategies.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/storing-files-with-mongogridfs.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/storing-files-with-mongogridfs.doctree new file mode 100644 index 0000000..dc52515 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/storing-files-with-mongogridfs.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/transactions-and-concurrency.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/transactions-and-concurrency.doctree new file mode 100644 index 0000000..22e5f23 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/transactions-and-concurrency.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/trees.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/trees.doctree new file mode 100644 index 0000000..ea30dde Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/trees.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/upserting-documents.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/upserting-documents.doctree new file mode 100644 index 0000000..79ae739 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/upserting-documents.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/working-with-objects.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/working-with-objects.doctree new file mode 100644 index 0000000..21db888 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/working-with-objects.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/xml-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/xml-mapping.doctree new file mode 100644 index 0000000..8efe6ec Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/xml-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/reference/yml-mapping.doctree b/build.docset/Contents/Resources/Documents/.doctrees/reference/yml-mapping.doctree new file mode 100644 index 0000000..efa6799 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/reference/yml-mapping.doctree differ diff --git a/build.docset/Contents/Resources/Documents/.doctrees/tutorials/getting-started.doctree b/build.docset/Contents/Resources/Documents/.doctrees/tutorials/getting-started.doctree new file mode 100644 index 0000000..4e36523 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/.doctrees/tutorials/getting-started.doctree differ diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/blending-orm-and-mongodb-odm.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/blending-orm-and-mongodb-odm.rst.txt new file mode 100644 index 0000000..712a25f --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/blending-orm-and-mongodb-odm.rst.txt @@ -0,0 +1,210 @@ +Blending the ORM and MongoDB ODM +================================ + +Since the start of the `Doctrine MongoDB Object Document Mapper`_ project people have asked how it can be integrated with the `ORM`_. This article will demonstrates how you can integrate the two transparently, maintaining a clean domain model. + +This example will have a `Product` that is stored in MongoDB and the `Order` stored in a MySQL database. + +Define Product +-------------- + +First lets define our `Product` document: + +.. code-block:: php + + id; + } + + public function getTitle() + { + return $this->title; + } + + public function setTitle($title) + { + $this->title = $title; + } + } + +Define Entity +------------- + +Next create the `Order` entity that has a `$product` and `$productId` property linking it to the `Product` that is stored with MongoDB: + +.. code-block:: php + + id; + } + + public function getProductId() + { + return $this->productId; + } + + public function setProduct(Product $product) + { + $this->productId = $product->getId(); + $this->product = $product; + } + + public function getProduct() + { + return $this->product; + } + } + +Event Subscriber +---------------- + +Now we need to setup an event subscriber that will set the `$product` property of all `Order` instances to a reference to the document product so it can be lazily loaded when it is accessed the first time. So first register a new event subscriber: + +.. code-block:: php + + getEventManager(); + $eventManager->addEventListener( + array(\Doctrine\ORM\Events::postLoad), new MyEventSubscriber($dm) + ); + +So now we need to define a class named `MyEventSubscriber` and pass a dependency to the `DocumentManager`. It will have a `postLoad()` method that sets the product document reference: + +.. code-block:: php + + dm = $dm; + } + + public function postLoad(LifecycleEventArgs $eventArgs) + { + $order = $eventArgs->getEntity(); + $em = $eventArgs->getEntityManager(); + $productReflProp = $em->getClassMetadata('Entities\Order') + ->reflClass->getProperty('product'); + $productReflProp->setAccessible(true); + $productReflProp->setValue( + $order, $this->dm->getReference('Documents\Product', $order->getProductId()) + ); + } + } + +The `postLoad` method will be invoked after an ORM entity is loaded from the database. This allows us to use the `DocumentManager` to set the `$product` property with a reference to the `Product` document with the product id we previously stored. + +Working with Products and Orders +-------------------------------- + +First create a new `Product`: + +.. code-block:: php + + setTitle('Test Product'); + $dm->persist($product); + $dm->flush(); + +Now create a new `Order` and link it to a `Product` in MySQL: + +.. code-block:: php + + setProduct($product); + $em->persist($order); + $em->flush(); + +Later we can retrieve the entity and lazily load the reference to the document in MongoDB: + +.. code-block:: php + + find('Order', $order->getId()); + + // Instance of an uninitialized product proxy + $product = $order->getProduct(); + + // Initializes proxy and queries the database + echo "Order Title: " . $product->getTitle(); + +If you were to print the `$order` you would see that we got back regular PHP objects: + +.. code-block:: php + + 53 + [productId:Entities\Order:private] => 4c74a1868ead0ed7a9000000 + [product:Entities\Order:private] => Proxies\DocumentsProductProxy Object + ( + [__isInitialized__] => 1 + [id:Documents\Product:private] => 4c74a1868ead0ed7a9000000 + [title:Documents\Product:private] => Test Product + ) + ) + +.. _Doctrine MongoDB Object Document Mapper: http://www.doctrine-project.org/projects/mongodb_odm +.. _ORM: http://www.doctrine-project.org/projects/orm diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-array-access-for-domain-objects.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-array-access-for-domain-objects.rst.txt new file mode 100644 index 0000000..1b62c24 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-array-access-for-domain-objects.rst.txt @@ -0,0 +1,123 @@ +Implementing ArrayAccess for Domain Objects +=========================================== + +.. sectionauthor:: Roman Borschel (roman@code-factory.org) + +This recipe will show you how to implement ArrayAccess for your +domain objects in order to allow more uniform access, for example +in templates. In these examples we will implement ArrayAccess on a +`Layer Supertype `_ +for all our domain objects. + +Option 1 +-------- + +In this implementation we will make use of PHPs highly dynamic +nature to dynamically access properties of a subtype in a supertype +at runtime. Note that this implementation has 2 main caveats: + +- It will not work with private fields +- It will not go through any getters/setters + +.. code-block:: php + + $offset); + } + + public function offsetSet($offset, $value) + { + $this->$offset = $value; + } + + public function offsetGet($offset) + { + return $this->$offset; + } + + public function offsetUnset($offset) + { + $this->$offset = null; + } + } + +Option 2 +-------- + +In this implementation we will dynamically invoke getters/setters. +Again we use PHPs dynamic nature to invoke methods on a subtype +from a supertype at runtime. This implementation has the following +caveats: + +- It relies on a naming convention +- The semantics of offsetExists can differ +- offsetUnset will not work with typehinted setters + +.. code-block:: php + + {"get$offset"}(); + return $value !== null; + } + + public function offsetSet($offset, $value) + { + $this->{"set$offset"}($value); + } + + public function offsetGet($offset) + { + return $this->{"get$offset"}(); + } + + public function offsetUnset($offset) + { + $this->{"set$offset"}(null); + } + } + +Read-only +--------- + +You can slightly tweak option 1 or option 2 in order to make array +access read-only. This will also circumvent some of the caveats of +each option. Simply make offsetSet and offsetUnset throw an +exception (i.e. BadMethodCallException). + +.. code-block:: php + + `_ +for all our domain objects. + +Implementing NotifyPropertyChanged +---------------------------------- + +The NOTIFY policy is based on the assumption that the entities +notify interested listeners of changes to their properties. For +that purpose, a class that wants to use this policy needs to +implement the ``NotifyPropertyChanged`` interface from the +``Doctrine\Common`` namespace. + +.. code-block:: php + + _listeners[] = $listener; + } + + /** Notifies listeners of a change. */ + protected function _onPropertyChanged($propName, $oldValue, $newValue) + { + if ($this->_listeners) { + foreach ($this->_listeners as $listener) { + $listener->propertyChanged($this, $propName, $oldValue, $newValue); + } + } + } + } + +Then, in each property setter of concrete, derived domain classes, +you need to invoke \_onPropertyChanged as follows to notify +listeners: + +.. code-block:: php + + data) { // check: is it actually modified? + $this->_onPropertyChanged('data', $this->data, $data); + $this->data = $data; + } + } + } + +The check whether the new value is different from the old one is +not mandatory but recommended. That way you can avoid unnecessary +updates and also have full control over when you consider a +property changed. \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-wakeup-or-clone.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-wakeup-or-clone.rst.txt new file mode 100644 index 0000000..1a595ff --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/implementing-wakeup-or-clone.rst.txt @@ -0,0 +1,77 @@ +Implementing Wakeup or Clone +============================ + +.. sectionauthor:: Roman Borschel (roman@code-factory.org) + +As explained in the +:doc:`restrictions for document classes in the manual <../reference/architecture>`. +it is usually not allowed for a document to implement ``__wakeup`` +or ``__clone``, because Doctrine makes special use of them. +However, it is quite easy to make use of these methods in a safe +way by guarding the custom wakeup or clone code with a document +identity check, as demonstrated in the following sections. + +Safely implementing \_\_wakeup +------------------------------ + +To safely implement ``__wakeup``, simply enclose your +implementation code in an identity check as follows: + +.. code-block:: php + + id) { + // ... Your code here as normal ... + } + // otherwise do nothing, do NOT throw an exception! + } + + //... + } + +Safely implementing \_\_clone +----------------------------- + +Safely implementing ``__clone`` is pretty much the same: + +.. code-block:: php + + id) { + // ... Your code here as normal ... + } + // otherwise do nothing, do NOT throw an exception! + } + + //... + } + +Summary +------- + +As you have seen, it is quite easy to safely make use of +``__wakeup`` and ``__clone`` in your documents without adding any +really Doctrine-specific or Doctrine-dependant code. + +These implementations are possible and safe because when Doctrine +invokes these methods, the documents never have an identity (yet). +Furthermore, it is possibly a good idea to check for the identity +in your code anyway, since it's rarely the case that you want to +unserialize or clone a document with no identity. \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/mapping-classes-to-orm-and-odm.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/mapping-classes-to-orm-and-odm.rst.txt new file mode 100644 index 0000000..fb8f294 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/mapping-classes-to-orm-and-odm.rst.txt @@ -0,0 +1,232 @@ +Mapping Classes to the ORM and ODM +================================== + +Because of the non intrusive design of Doctrine it is possible for you to have plain PHP classes +that are mapped to both a relational database with the Doctrine2 Object Relational Mapper and +MongoDB with the Doctrine MongoDB Object Document Mapper, or any other persistence layer that +implements the Doctrine Common `persistence`_ interfaces. + +Test Subject +------------ + +For this cookbook entry we need to define a class that can be persisted to both MySQL and MongoDB. +We'll use a ``BlogPost`` as you may want to write some generic blogging functionality that has support +for multiple Doctrine persistence layers: + +.. code-block:: php + + + + + + + + + + + + .. code-block:: yaml + + Documents\BlogPost: + repositoryClass: Doctrine\Blog\ORM\BlogPostRepository + id: + id: + type: integer + fields: + title: + type: string + body: + type: text + +Now you are able to persist the ``Documents\BlogPost`` with an instance of ``EntityManager``: + +.. code-block:: php + + setTitle('test'); + + $em->persist($blogPost); + $em->flush(); + +You can find the blog post: + +.. code-block:: php + + getRepository('Documents\BlogPost')->findOneByTitle('test'); + +MongoDB ODM +~~~~~~~~~~~ + +Now map the same class to the Doctrine MongoDB ODM: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + .. code-block:: yaml + + Documents\BlogPost: + repositoryClass: Doctrine\Blog\ODM\MongoDB\BlogPostRepository + fields: + id: + type: id + title: + type: string + body: + type: text + +Now the same class is able to be persisted in the same way using an instance of ``DocumentManager``: + +.. code-block:: php + + setTitle('test'); + + $dm->persist($blogPost); + $dm->flush(); + +You can find the blog post: + +.. code-block:: php + + getRepository('Documents\BlogPost')->findOneByTitle('test'); + +Repository Classes +------------------ + +You can implement the same repository interface for the ORM and MongoDB ODM easily: + +.. code-block:: php + + findOneBy(array('id' => $id)); + } + } + +Now define the same repository methods for the MongoDB ODM: + +.. code-block:: php + + findOneBy(array('id' => $id)); + } + } + +As you can see the repositories are the same and the final returned data is the same vanilla +PHP objects. The data is transparently injected to the objects for you automatically so you +are not forced to extend some base class or shape your domain in any certain way for it to work +with the Doctrine persistence layers. + +.. _persistence: https://github.com/doctrine/common/tree/master/lib/Doctrine/Common/Persistence diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/resolve-target-document-listener.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/resolve-target-document-listener.rst.txt new file mode 100644 index 0000000..cd0a384 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/resolve-target-document-listener.rst.txt @@ -0,0 +1,139 @@ +Keeping Your Modules Independent +================================ + +One of the goals of using modules is to create discrete units of functionality +that do not have many (if any) dependencies, allowing you to use that +functionality in other applications without including unnecessary items. + +Doctrine MongoDB ODM includes a utility called +``ResolveTargetDocumentListener``, that functions by intercepting certain calls +inside Doctrine and rewriting ``targetDocument`` parameters in your metadata +mapping at runtime. This allows your bundle to use an interface or abstract +class in its mappings while still allowing the mapping to resolve to a concrete +document class at runtime. + +This functionality allows you to define relationships between different +documents without creating hard dependencies. + +Background +---------- + +In the following example, we have an `InvoiceModule` that provides invoicing +functionality, and a `CustomerModule` that contains customer management tools. +We want to keep these separated, because they can be used in other systems +without each other; however, we'd like to use them together in our application. + +In this case, we have an ``Invoice`` document with a relationship to a +non-existent object, an ``InvoiceSubjectInterface``. The goal is to get +the ``ResolveTargetDocumentListener`` to replace any mention of the interface +with a real class that implements that interface. + +Configuration +------------- + +We're going to use the following basic documents (which are incomplete +for brevity) to explain how to set up and use the +``ResolveTargetDocumentListener``. + +A Customer document: + +.. code-block:: php + + addResolveTargetDocument( + 'Acme\\InvoiceModule\\Model\\InvoiceSubjectInterface', + 'Acme\\CustomerModule\\Document\\Customer', + array() + ); + + // Add the ResolveTargetDocumentListener + $evm->addEventListener(\Doctrine\ODM\MongoDB\Events::loadClassMetadata, $rtdl); + + // Create the document manager as you normally would + $dm = \Doctrine\ODM\MongoDB\DocumentManager::create($connectionOptions, $config, $evm); + +Final Thoughts +-------------- + +With ``ResolveTargetDocumentListener``, we are able to decouple our bundles so +that they are usable by themselves and easier to maintain independently, while +still being able to define relationships between different objects. diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/simple-search-engine.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/simple-search-engine.rst.txt new file mode 100644 index 0000000..13192a9 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/simple-search-engine.rst.txt @@ -0,0 +1,170 @@ +Simple Search Engine +==================== + +It is very easy to implement a simple keyword search engine with MongoDB. Because of +its flexible schema less nature we can store the keywords we want to search through directly +on the document. MongoDB is capable of indexing the embedded documents so the results are fast +and scalable. + +Sample Model: Product +--------------------- + +Imagine you had a ``Product`` document and you want to search the products by keywords. You can +setup a document like the following with a ``$keywords`` property that is mapped as a collection: + +.. code-block:: php + + setTitle('Nike Air Jordan 2011'); + $product->addKeyword('nike shoes'); + $product->addKeyword('jordan shoes'); + $product->addKeyword('air jordan'); + $product->addKeyword('shoes'); + $product->addKeyword('2011'); + + $dm->persist($product); + $dm->flush(); + +The above example populates the keywords manually but you could very easily write some code which +automatically generates your keywords from a string built by the Product that may include the title, +description and other fields. You could also use a tool like the `AlchemyAPI`_ if you want to do +some more intelligent keyword extraction. + +Searching Keywords +------------------ + +Searching the keywords in the ``Product`` collection is easy! You can run a query like the following +to find documents that have at least one of the keywords: + +.. code-block:: php + + createQueryBuilder('Product') + ->field('keywords')->in($keywords); + +You can make the query more strict by using the ``all()`` method instead of ``in()``: + +.. code-block:: php + + createQueryBuilder('Product') + ->field('keywords')->all($keywords); + +The above query would only return products that have both of the keywords! + +User Input +~~~~~~~~~~ + +You can easily build keywords from a user search form by exploding whitespace and passing +the results to your query. Here is an example: + +.. code-block:: php + + createQueryBuilder('Product') + ->field('keywords')->all($keywords); + +Embedded Documents +------------------ + +If you want to use an embedded document instead of just an array then you can. It will allow you to store +additional information with each keyword, like its weight. + +Definition +~~~~~~~~~~ + +You can setup a ``Keyword`` document like the following: + +.. code-block:: php + + keyword = $keyword; + $this->weight = $weight; + } + + // ... + } + +Now you can embed the ``Keyword`` document many times in the ``Product``: + +.. code-block:: php + + addKeyword(new Keyword('nike shoes', 1)); + +This is a very basic search engine example and can work for many small and simple applications. If you +need better searching functionality you can look at integrating something like `Solr`_ in your project. + +.. _AlchemyAPI: http://www.alchemyapi.com +.. _Solr: http://lucene.apache.org/solr diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/soft-delete-extension.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/soft-delete-extension.rst.txt new file mode 100644 index 0000000..052e03d --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/soft-delete-extension.rst.txt @@ -0,0 +1,224 @@ +Soft Delete Extension +===================== + +Sometimes you may not want to delete data from your database completely, but you want to +disable or temporarily delete some records so they do not appear anymore in your frontend. +Then, later you might want to restore that deleted data like it was never deleted. + +This is possible with the ``SoftDelete`` extension which can be found on `github`_. + +Installation +------------ + +First you just need to get the code by cloning the `github`_ repository: + +.. code-block:: console + + $ git clone git://github.com/doctrine/mongodb-odm-softdelete.git + +Now once you have the code you can setup the autoloader for it: + +.. code-block:: php + + register(); + +Setup +----- + +Now you can autoload the classes you need to setup the ``SoftDeleteManager`` instance you need to manage +the soft delete state of your documents: + +.. code-block:: php + + deletedAt; + } + + // ... + } + +Usage +----- + +Once you have the ``$sdm`` you can start managing the soft delete state of your documents: + +.. code-block:: php + + getRepository('User')->findOneByUsername('jwage'); + $fabpot = $dm->getRepository('User')->findOneByUsername('fabpot'); + $sdm->delete($jwage); + $sdm->delete($fabpot); + $sdm->flush(); + +The call to ``SoftDeleteManager#flush()`` would persist the deleted state to the database +for all the documents it knows about and run a query like the following: + +.. code-block:: javascript + + db.users.update({ _id : { $in : userIds }}, { $set : { deletedAt : new Date() } }) + +Now if we were to restore the documents: + +.. code-block:: php + + restore($jwage); + $sdm->flush(); + +It would execute a query like the following: + +.. code-block:: javascript + + db.users.update({ _id : { $in : userIds }}, { $unset : { deletedAt : true } }) + +Events +------ + +We trigger some additional lifecycle events when documents are soft deleted and restored: + +- Events::preSoftDelete +- Events::postSoftDelete +- Events::preRestore +- Events::postRestore + +Using the events is easy, just define a class like the following: + +.. code-block:: php + + getDocument(); + $sdm = $args->getSoftDeleteManager(); + } + + public function getSubscribedEvents() + { + return array(Events::preSoftDelete); + } + } + +Now we just need to add the event subscriber to the EventManager: + +.. code-block:: php + + addEventSubscriber($eventSubscriber); + +When we soft delete something the preSoftDelete() method will be invoked before any queries are sent +to the database: + +.. code-block:: php + + delete($fabpot); + $sdm->flush(); + +Cascading Soft Deletes +---------------------- + +You can easily implement cascading soft deletes by using events in a certain way. Imagine you have +a User and Post document and you want to soft delete a users posts when you delete him. + +You just need to setup an event listener like the following: + +.. code-block:: php + + getSoftDeleteManager(); + $document = $args->getDocument(); + if ($document instanceof User) { + $sdm->deleteBy('Post', array('user.id' => $document->getId())); + } + } + + public function preRestore(LifecycleEventArgs $args) + { + $sdm = $args->getSoftDeleteManager(); + $document = $args->getDocument(); + if ($document instanceof User) { + $sdm->restoreBy('Post', array('user.id' => $document->getId())); + } + } + + public function getSubscribedEvents() + { + return array( + Events::preSoftDelete, + Events::preRestore + ); + } + } + +Now when you delete an instance of User it will also delete any Post documents where they +reference the User being deleted. If you restore the User, his Post documents will also be restored. + +.. _github: https://github.com/doctrine/mongodb-odm-softdelete diff --git a/build.docset/Contents/Resources/Documents/_sources/cookbook/validation-of-documents.rst.txt b/build.docset/Contents/Resources/Documents/_sources/cookbook/validation-of-documents.rst.txt new file mode 100644 index 0000000..b80d908 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/cookbook/validation-of-documents.rst.txt @@ -0,0 +1,130 @@ +Validation of Documents +======================= + +.. sectionauthor:: Benjamin Eberlei + +Doctrine does not ship with any internal validators, the reason +being that we think all the frameworks out there already ship with +quite decent ones that can be integrated into your Domain easily. +What we offer are hooks to execute any kind of validation. + +.. note:: + + You don't need to validate your documents in the lifecycle + events. Its only one of many options. Of course you can also + perform validations in value setters or any other method of your + documents that are used in your code. + +Documents can register lifecycle event methods with Doctrine that +are called on different occasions. For validation we would need to +hook into the events called before persisting and updating. Even +though we don't support validation out of the box, the +implementation is even simpler than in Doctrine 1 and you will get +the additional benefit of being able to re-use your validation in +any other part of your domain. + +Say we have an ``Order`` with several ``OrderLine`` instances. We +never want to allow any customer to order for a larger sum than he +is allowed to: + +.. code-block:: php + + customer->getOrderLimit(); + + $amount = 0; + foreach ($this->orderLines AS $line) { + $amount += $line->getAmount(); + } + + if ($amount > $orderLimit) { + throw new CustomerOrderLimitExceededException(); + } + } + } + +Now this is some pretty important piece of business logic in your +code, enforcing it at any time is important so that customers with +a unknown reputation don't owe your business too much money. + +We can enforce this constraint in any of the metadata drivers. +First Annotations: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + +Now validation is performed whenever you call +``DocumentManager#persist($order)`` or when you call +``DocumentManager#flush()`` and an order is about to be updated. Any +Exception that happens in the lifecycle callbacks will be cached by +the DocumentManager and the current transaction is rolled back. + +Of course you can do any type of primitive checks, not null, +email-validation, string size, integer and date ranges in your +validation callbacks. + +.. code-block:: php + + plannedShipDate instanceof DateTime)) { + throw new ValidateException(); + } + + if ($this->plannedShipDate->format('U') < time()) { + throw new ValidateException(); + } + + if ($this->customer == null) { + throw new OrderRequiresCustomerException(); + } + } + } + +What is nice about lifecycle events is, you can also re-use the +methods at other places in your domain, for example in combination +with your form library. Additionally there is no limitation in the +number of methods you register on one particular event, i.e. you +can register multiple methods for validation in "PrePersist" or +"PreUpdate" or mix and share them in any combinations between those +two events. + +There is no limit to what you can and can't validate in +"PrePersist" and "PreUpdate" as long as you don't create new document +instances. This was already discussed in the previous blog post on +the Versionable extension, which requires another type of event +called "onFlush". + +Further readings: :doc:`Lifecycle Events <../reference/events>` \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/index.rst.txt b/build.docset/Contents/Resources/Documents/_sources/index.rst.txt new file mode 100644 index 0000000..a54e1bf --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/index.rst.txt @@ -0,0 +1,107 @@ +Doctrine MongoDB ODM's documentation! +===================================== + +The Doctrine MongoDB ODM documentation is comprised of tutorials, a reference section and +cookbook articles that explain different parts of the Object Document mapper. + +Getting Help +------------ + +If this documentation is not helping to answer questions you have about +Doctrine MongoDB ODM don't panic. You can get help from different sources: + +- The `Doctrine Mailing List `_ +- Internet Relay Chat (IRC) in `#doctrine on Freenode `_ +- Report a bug on `GitHub `_. +- On `StackOverflow `_ + +Getting Started +--------------- + + :doc:`Getting Started ` | + :doc:`Introduction ` | + :doc:`Architecture ` + +Mapping Objects onto a Database +------------------------------- + +* **Basic Reference**: + :doc:`Objects and Fields ` | + :doc:`References ` | + :doc:`Bi-Directional References ` | + :doc:`Complex References ` | + :doc:`Indexes ` | + :doc:`Inheritance ` + +* **Embedded Data**: + :doc:`Embedded ` | + :doc:`Trees ` + +* **GridFS**: + :doc:`Storing Files in GridFS ` + +* **Mapping Driver References**: + :doc:`XML ` | + :doc:`YAML ` | + :doc:`Docblock Annotations ` | + :doc:`Metadata Drivers ` + +Working with Objects +-------------------- + +* **Basic Reference**: + :doc:`Documents ` | + :doc:`Repositories ` | + :doc:`Events ` | + :doc:`Migrations ` + +* **Query Reference**: + :doc:`Query Builder API ` | + :doc:`Aggregation Pipeline queries ` | + :doc:`Geo Spatial Queries ` | + :doc:`Slave Okay Queries ` | + :doc:`Find and Update ` | + :doc:`Filters ` | + :doc:`Priming References ` | + :doc:`Eager Cursors ` | + :doc:`Map Reduce ` + +Advanced Topics +--------------- + +* **Collections**: + :doc:`Capped Collections ` | + :doc:`Storage Strategies ` | + :doc:`Custom Collections ` | + :doc:`Sharded setups ` + +* **Transactions and Concurrency**: + :doc:`Transactions and Concurrency ` + +* **Best Practices**: + :doc:`Best Practices ` + +* **Performance**: + :doc:`Change Tracking Policies ` + +* **Logging**: + :doc:`Logging ` + +Cookbook +-------- + +* **Examples**: + :doc:`Soft Delete ` | + :doc:`Simple Search Engine ` + +* **Tricks**: + :doc:`Blending ORM and MongoDB ODM ` | + :doc:`Mapping classes to ORM and ODM ` + +* **Implementation**: + :doc:`Array Access ` | + :doc:`Notify ChangeTracking Example ` | + :doc:`Using Wakeup Or Clone ` | + :doc:`Validation ` | + :doc:`Simple Search Engine ` | + :doc:`Keeping Your Modules Independent ` diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/aggregation-builder.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/aggregation-builder.rst.txt new file mode 100644 index 0000000..8ded612 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/aggregation-builder.rst.txt @@ -0,0 +1,814 @@ +Aggregation builder +=================== + +.. note:: + This feature is introduced in version 1.2 + +The aggregation framework provides an easy way to process records and return +computed results. The aggregation builder helps to build complex aggregation +pipelines. + +Creating an Aggregation Builder +------------------------------- + +You can easily create a new ``Aggregation\Builder`` object with the +``DocumentManager::createAggregationBuilder()`` method: + +.. code-block:: php + + createAggregationBuilder(\Documents\User::class); + +The first argument indicates the document for which you want to create the +builder. + +Adding pipeline stages +~~~~~~~~~~~~~~~~~~~~~~ + +To add a pipeline stage to the builder, call the corresponding method on the +builder object: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->match() + ->field('purchaseDate') + ->gte($from) + ->lt($to) + ->field('user') + ->references($user) + ->group() + ->field('id') + ->expression('$user') + ->field('numPurchases') + ->sum(1) + ->field('amount') + ->sum('$amount'); + +Just like the query builder, the aggregation builder takes care of converting +``DateTime`` objects into ``MongoDate`` objects. + +Nesting expressions +~~~~~~~~~~~~~~~~~~~ + +You can create more complex aggregation stages by using the ``expr()`` method in +the aggregation builder. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->match() + ->field('purchaseDate') + ->gte($from) + ->lt($to) + ->field('user') + ->references($user) + ->group() + ->field('id') + ->expression( + $builder->expr() + ->field('month') + ->month('purchaseDate') + ->field('year') + ->year('purchaseDate') + ) + ->field('numPurchases') + ->sum(1) + ->field('amount') + ->sum('$amount'); + +This aggregation would group all purchases by their month and year by projecting +those values into an embedded object for the ``id`` field. For example: + +.. code-block:: json + + { + _id: { + month: 1, + year: 2016 + }, + numPurchases: 1, + amount: 27.89 + } + +Executing an aggregation pipeline +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +You can execute a pipeline using the ``execute()`` method. This will run the +aggregation pipeline and return a cursor for you to iterate over the results: + +.. code-block:: php + + createAggregationBuilder(\Documents\User::class); + $result = $builder->execute(); + +If you instead want to look at the built aggregation pipeline, call the +``Builder::getPipeline()`` method. + +Hydration +~~~~~~~~~ + +By default, aggregation results are returned as PHP arrays. This is because the +result of an aggregation pipeline may look completely different from the source +document. In order to get hydrated aggregation results, you first have to map +a ``QueryResultDocument``. These are written like regular mapped documents, but +they can't be persisted to the database. + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + .. code-block:: yaml + + Documents\User: + type: queryResultDocument + fields: + user: + name: _id + targetDocument: Documents\User + numPurchases: + type: int + amount: + type: float + +Once you have mapped the document, use the ``hydrate()`` method to tell the +aggregation builder about this document: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->hydrate(\Documents\UserPurchases::class) + ->match() + ->field('purchaseDate') + ->gte($from) + ->lt($to) + ->field('user') + ->references($user) + ->group() + ->field('id') + ->expression('$user') + ->field('numPurchases') + ->sum(1) + ->field('amount') + ->sum('$amount'); + +When you run the queries, all results will be returned as instances of the +specified document. + +.. note:: + + Query result documents can use all features regular documents can use: you + can map embedded documents, define references, and even use discriminators + to get different result documents according to the aggregation result. + +Aggregation pipeline stages +--------------------------- + +MongoDB provides the following aggregation pipeline stages: + +- `$addFields `_ +- `$bucket `_ +- `$bucketAuto `_ +- `$collStats `_ +- `$count `_ +- `$facet `_ +- `$geoNear `_ +- `$graphLookup `_ +- `$group `_ +- `$indexStats `_ +- `$limit `_ +- `$lookup `_ +- `$match `_ +- `$out `_ +- `$project `_ +- `$redact `_ +- `$replaceRoot `_ +- `$sample `_ +- `$skip `_ +- `$sort `_ +- `$sortByCount `_ +- `$unwind `_ + +.. note:: + + The ``$lookup``, ``$sample`` and ``$indexStats`` stages were added in MongoDB + 3.2. The ``$addFields``, ``$bucket``, ``$bucketAuto``, ``$sortByCount``, + ``$replaceRoot``, ``$facet``, ``$graphLookup``, ``$coun`` and ``$collStats`` + stages were added in MongoDB 3.4. + +$addFields +~~~~~~~~~~ + +Adds new fields to documents. ``$addFields`` outputs documents that contain all +existing fields from the input documents and newly added fields. + +The ``$addFields`` stage is equivalent to a ``$project`` stage that explicitly +specifies all existing fields in the input documents and adds the new fields. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->addFields() + ->field('purchaseYear') + ->year('$purchaseDate'); + +$bucket +~~~~~~~ + +Categorizes incoming documents into groups, called buckets, based on a specified +expression and bucket boundaries. + +Each bucket is represented as a document in the output. The document for each +bucket contains an _id field, whose value specifies the inclusive lower bound of +the bucket and a count field that contains the number of documents in the bucket. +The count field is included by default when the output is not specified. + +``$bucket`` only produces output documents for buckets that contain at least one +input document. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->bucket() + ->groupBy('$itemCount') + ->boundaries(1, 2, 3, 4, 5, '5+') + ->defaultBucket('5+') + ->output() + ->field('lowestValue') + ->min('$value') + ->field('highestValue') + ->max('$value') + ; + +$bucketAuto +~~~~~~~~~~~ + +Similar to ``$bucket``, except that boundaries are automatically determined in +an attempt to evenly distribute the documents into the specified number of +buckets. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->bucketAuto() + ->groupBy('$itemCount') + ->buckets(5) + ->output() + ->field('lowestValue') + ->min('$value') + ->field('highestValue') + ->max('$value') + ; + +$collStats +~~~~~~~~~~ + +The ``$collStats`` stage returns statistics regarding a collection or view. + +$count +~~~~~~ + +Returns a document that contains a count of the number of documents input to the +stage. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->match() + ->field('itemCount') + ->eq(1) + ->count('numSingleItemOrders') + ; + +The example above returns a single document with the ``numSingleItemOrders`` +containing the number of orders found. + +$facet +~~~~~~ + +Processes multiple aggregation pipelines within a single stage on the same set +of input documents. Each sub-pipeline has its own field in the output document +where its results are stored as an array of documents. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->facet() + ->field('groupedByItemCount') + ->pipeline( + $dm->createAggregationBuilder(\Documents\Orders::class)->group() + ->field('id') + ->expression('$itemCount') + ->field('lowestValue') + ->min('$value') + ->field('highestValue') + ->max('$value') + ->field('totalValue') + ->sum('$value') + ->field('averageValue') + ->avg('$value') + ) + ->field('groupedByYear') + ->pipeline( + $dm->createAggregationBuilder(\Documents\Orders::class)->group() + ->field('id') + ->year('purchaseDate') + ->field('lowestValue') + ->min('$value') + ->field('highestValue') + ->max('$value') + ->field('totalValue') + ->sum('$value') + ->field('averageValue') + ->avg('$value') + ) + ; + +$geoNear +~~~~~~~~ + +The ``$geoNear`` stage finds and outputs documents in order of nearest to +farthest from a specified point. + +.. code-block:: php + + dm->createAggregationBuilder(\Documents\City::class); + $builder + ->geoNear(120, 40) + ->spherical(true) + ->distanceField('distance') + // Convert radians to kilometers (use 3963.192 for miles) + ->distanceMultiplier(6378.137); + +.. note:: + + The ``$geoNear`` stage must be the first stage in the pipeline and the + collection must contain a single geospatial index. You must include the + ``distanceField`` option for the stage to work. + +$graphLookup +~~~~~~~~~~~~ + +Performs a recursive search on a collection, with options for restricting the +search by recursion depth and query filter. The ``$graphLookup`` stage can be +used to resolve association graphs and flatten them into a single list. + +.. code-block:: php + + dm->createAggregationBuilder(\Documents\Traveller::class); + $builder + ->graphLookup('nearestAirport') + ->connectFromField('connections') + ->maxDepth(2) + ->depthField('numConnections') + ->alias('destinations'); + +.. note:: + + The target document of the reference used in ``connectFromField`` must be + the very same document. The aggregation builder will throw an exception if + you try to resolve a different document. + +.. note:: + + Due to a limitation in MongoDB, the ``$graphLookup`` stage can not be used + with references that are stored as DBRef. To use references in a + ``$graphLookup`` stage, store the reference as ID or ``ref``. This is + explained in the :doc:`Reference mapping ` chapter. + +.. _aggregation_builder_group: + +$group +~~~~~~ + +The ``$group`` stage is used to do calculations based on previously matched +documents: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->match() + ->field('user') + ->references($user) + ->group() + ->field('id') + ->expression( + $builder->expr() + ->field('month') + ->month('purchaseDate') + ->field('year') + ->year('purchaseDate') + ) + ->field('numPurchases') + ->sum(1) + ->field('amount') + ->sum('$amount'); + +$indexStats +~~~~~~~~~~~ + +The ``$indexStats`` stage returns statistics regarding the use of each index for +the collection. More information can be found in the `official Documentation `_ + +$lookup +~~~~~~~ + +.. note:: + + The ``$lookup`` stage was introduced in MongoDB 3.2. Using it on older servers + will result in an error. + +The ``$lookup`` stage is used to fetch documents from different collections in +pipeline stages. Take the following relationship for example: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->lookup('items') + ->alias('items'); + +The resulting array will contain all matched item documents in an array. This has +to be considered when looking up one-to-one relationships: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->lookup('user') + ->alias('user') + ->unwind('$user'); + +MongoDB will always return an array, even if the lookup only returned a single +document. Thus, when looking up one-to-one references the result must be flattened +using the ``$unwind`` operator. + +.. note:: + + Due to a limitation in MongoDB, the ``$lookup`` stage can not be used with + references that are stored as DBRef. To use references in a ``$lookup`` + stage, store the reference as ID or ``ref``. This is explained in the + :doc:`Reference mapping ` chapter. + +You can also configure your lookup manually if you don't have it mapped in your +document: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->lookup('unmappedCollection') + ->localField('_id') + ->foreignField('userId') + ->alias('items'); + +$match +~~~~~~ + +The ``$match`` stage lets you filter documents according to certain criteria. It +works just like the query builder: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->match() + ->field('purchaseDate') + ->gte($from) + ->lt($to) + ->field('user') + ->references($user); + +You can also use fields defined in previous stages: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->project() + ->excludeIdField() + ->includeFields(['purchaseDate', 'user']) + ->field('purchaseYear') + ->year('$purchaseDate') + ->match() + ->field('purchaseYear') + ->equals(2016); + +$out +~~~~ + +The ``$out`` stage is used to store the result of the aggregation pipeline in a +collection instead of returning an iterable cursor of results. This must be the +last stage in an aggregation pipeline. + +If the collection specified by the ``$out`` operation already exists, then upon +completion of the aggregation, the existing collection is atomically replaced. +Any indexes that existed on the collection are left intact. If the aggregation +fails, the ``$out`` operation does not remove the data from an existing +collection. + +.. note:: + + The aggregation pipeline will fail to complete if the result would violate + any unique index constraints, including those on the ``id`` field. + +$project +~~~~~~~~ + +The ``$project`` stage lets you reshape the current document or define a completely +new one: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->project() + ->excludeIdField() + ->includeFields(['purchaseDate', 'user']) + ->field('purchaseYear') + ->year('$purchaseDate'); + +$redact +~~~~~~~ + +The redact stage can be used to restrict the contents of the documents based on +information stored in the documents themselves. You can read more about the +``$redact`` stage in the `MongoDB documentation `_. + +The following example taken from the official documentation checks the ``level`` +field on all document levels and evaluates it to grant or deny access: + +.. code-block:: json + + { + _id: 1, + level: 1, + acct_id: "xyz123", + cc: { + level: 5, + type: "yy", + num: 000000000000, + exp_date: ISODate("2015-11-01T00:00:00.000Z"), + billing_addr: { + level: 5, + addr1: "123 ABC Street", + city: "Some City" + }, + shipping_addr: [ + { + level: 3, + addr1: "987 XYZ Ave", + city: "Some City" + }, + { + level: 3, + addr1: "PO Box 0123", + city: "Some City" + } + ] + }, + status: "A" + } + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->redact() + ->cond( + $builder->expr()->gte('$$level', 5), + '$$PRUNE', + '$$DESCEND' + ) + +$replaceRoot +~~~~~~~~~~~~ + +Promotes a specified document to the top level and replaces all other fields. +The operation replaces all existing fields in the input document, including the +``_id`` field. You can promote an existing embedded document to the top level, +or create a new document for promotion. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->replaceRoot('$embeddedField'); + + $builder = $dm->createAggregationBuilder(\Documents\Orders::class); + $builder + ->replaceRoot() + ->field('averagePricePerItem') + ->divide('$value', '$itemCount'); + +$sample +~~~~~~~ + +The sample stage can be used to randomly select a subset of documents in the +aggregation pipeline. It behaves like the ``$limit`` stage, but instead of +returning the first ``n`` documents it returns ``n`` random documents. + +$sort, $limit and $skip +~~~~~~~~~~~~~~~~~~~~~~~ + +The ``$sort``, ``$limit`` and ``$skip`` stages behave like the corresponding +query options, allowing you to control the order and subset of results returned +by the aggregation pipeline. + +$sortByCount +~~~~~~~~~~~~ + +Groups incoming documents based on the value of a specified expression, then +computes the count of documents in each distinct group. + +Each output document contains two fields: an _id field containing the distinct +grouping value, and a count field containing the number of documents belonging +to that grouping or category. + +The documents are sorted by count in descending order. + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder->sortByCount('$items'); + +The example above is equivalent to the following pipeline: + +.. code-block:: php + + createAggregationBuilder(\Documents\Orders::class); + $builder + ->group() + ->field('_id') + ->expression('$items') + ->field('count') + ->sum(1) + ->sort(['count' => -1]) + ; + +$unwind +~~~~~~~ + +The ``$unwind`` stage flattens an array in a document, returning a copy for each +item. Take this sample document: + +.. code-block:: json + + { + _id: { + month: 1, + year: 2016 + }, + purchaseDates: [ + '2016-01-07', + '2016-03-10', + '2016-06-25' + ] + } + +To flatten the ``purchaseDates`` array, we would apply the following pipeline +stage: + +.. code-block:: php + + createAggregationBuilder(\Documents\User::class); + $builder->unwind('$purchaseDates'); + +The stage would return three documents, each containing a single purchase date: + +.. code-block:: json + + { + _id: { + month: 1, + year: 2016 + }, + purchaseDates: '2016-01-07' + }, + { + _id: { + month: 1, + year: 2016 + }, + purchaseDates: '2016-03-10' + }, + { + _id: { + month: 1, + year: 2016 + }, + purchaseDates: '2016-06-25' + } diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/annotations-reference.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/annotations-reference.rst.txt new file mode 100644 index 0000000..5539c10 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/annotations-reference.rst.txt @@ -0,0 +1,1482 @@ +Annotations Reference +===================== + +In this chapter a reference of every Doctrine 2 ODM Annotation is +given with short explanations on their context and usage. + +@AlsoLoad +--------- + +Specify one or more MongoDB fields to use for loading data if the original field +does not exist. + +.. code-block:: php + + firstName, $this->lastName) = explode(' ', $name); + } + +For additional information on using `@AlsoLoad`_, see +:doc:`Migrations `. + +@Bin +---- + +Alias of `@Field`_, with "type" attribute set to "bin". Converts value to +`MongoBinData`_ with ``MongoBinData::GENERIC`` sub-type. + +.. code-block:: php + + `. + + +@Collection +----------- + +Alias of `@Field`_, with "type" attribute set to "collection". Stores and +retrieves the value as a numerically indexed array. + +.. code-block:: php + + ` hierarchy. +It takes a string as its only argument, which specifies the database field to +store a class name or key (if a discriminator map is used). ODM uses this field +during hydration to select the instantiation class. + +.. code-block:: php + + ` hierarchy. +It takes an array as its only argument, which maps keys to class names. The +class names may be fully qualified or relative to the current namespace. When +a document is persisted to the database, its class name key will be stored in +the discriminator field instead of the |FQCN|. + +.. code-block:: php + + ` query method to populate the property with the +calculated distance value. + +.. code-block:: php + + dm->createQuery('City') + ->geoNear(50, 60) + ->limit(1) + ->getQuery() + ->getSingleResult(); + echo $city->distance; + +@Document +--------- + +Required annotation to mark a PHP class as a document, whose peristence will be +managed by ODM. + +Optional attributes: + +- + db - By default, the document manager will use the MongoDB database defined + in the configuration, but this option may be used to override the database + for a particular document class. +- + collection - By default, the collection name is derived from the document's + class name, but this option may be used to override that behavior. +- + repositoryClass - Specifies a custom repository class to use. +- + indexes - Specifies an array of indexes for this document. +- + readOnly - Prevents document from being updated: it can only be inserted, + upserted or removed. +- + requireIndexes - Specifies whether or not queries for this document should + require indexes by default. This may also be specified per query. +- + writeConcern - Specifies the write concern for this document that overwrites + the default write concern specified in the configuration. It does not overwrite + a write concern given as :ref:`option ` to the ``flush`` + method when committing your documents. + +.. code-block:: php + + amount = (float) $amount; + } + //... + } + + /** @Document(db="finance", collection="wallets") */ + class Wallet + { + /** @EmbedOne(targetDocument="Money") */ + private $money; + + public function setMoney(Money $money) + { + $this->money = $money; + } + //... + } + //... + $wallet = new Wallet(); + $wallet->setMoney(new Money(34.39)); + $dm->persist($wallet); + $dm->flush(); + +Unlike normal documents, embedded documents cannot specify their own database or +collection. That said, a single embedded document class may be used with +multiple document classes, and even other embedded documents! + +Optional attributes: + +- + indexes - Specifies an array of indexes for this embedded document, to be + included in the schemas of any embedding documents. + +@Field +------ + +Marks an annotated instance variable for persistence. Values for this field will +be saved to and loaded from the document store as part of the document class' +lifecycle. + +Optional attributes: + +- + type - Name of the ODM type, which will determine the value's representation + in PHP and BSON (i.e. MongoDB). See :ref:`doctrine_mapping_types` for a list + of types. Defaults to "string". +- + name - By default, the property name is used for the field name in MongoDB; + however, this option may be used to specify a database field name. +- + nullable - By default, ODM will ``$unset`` fields in MongoDB if the PHP value + is null. Specify true for this option to force ODM to store a null value in + the database instead of unsetting the field. + +Examples: + +.. code-block:: php + + ` attribute. + +.. code-block:: php + + downloads++; + } + + // ... + } + +Now, update a Package instance like so: + +.. code-block:: php + + incrementDownloads(); + $dm->flush(); + +The query sent to Mongo would resemble the following: + +.. code-block:: json + + { "$inc": { "downloads": 1 } } + +The field will be incremented by the difference between the new and old values. +This is useful if many requests are attempting to update the field concurrently. + +.. note:: + + This annotation is deprecated and will be removed in ODM 2.0. Please use the + `@Field`_ annotation with type "int" or "float" and use the "increment" + strategy. + +@Index +------ + +This annotation is used inside of the class-level `@Document`_ or +`@EmbeddedDocument`_ annotations to specify indexes to be created on the +collection (or embedding document's collection in the case of +`@EmbeddedDocument`_). It may also be used at the property-level to define +single-field indexes. + +Optional attributes: + +- + keys - Mapping of indexed fields to their ordering or index type. ODM will + allow "asc" and "desc" to be used in place of ``1`` and ``-1``, + respectively. Special index types (e.g. "2dsphere") should be specified as + strings. This is required when `@Index`_ is used at the class level. +- + options - Options for creating the index + +The ``keys`` and ``options`` attributes correspond to the arguments for +`MongoCollection::createIndex() `_. +ODM allows mapped field names (i.e. PHP property names) to be used when defining +``keys``. + +.. code-block:: php + + `. ``SINGLE_COLLECTION`` and +``COLLECTION_PER_CLASS`` are currently supported. + +Examples: + +.. code-block:: php + + `. +This is only compatible with the ``int`` type, and cannot be combined with `@Id`_. + +.. code-block:: php + + ` for additional information. + +.. code-block:: php + + _` +that will be applied when querying for the annotated document. + +.. code-block:: php + + `. +This is only compatible with ``int`` and ``date`` field types, and cannot be combined with `@Id`_. + +.. code-block:: php + + ` and +:ref:`reference-many ` collections in separate write operations, +which do not bump the document version. Users employing document versioning are +encouraged to use the :ref:`atomicSet ` or +:ref:`atomicSetArray ` strategies for such collections, which +will ensure that collections are updated in the same write operation as the +versioned parent document. + +.. _BSON specification: http://bsonspec.org/spec.html +.. _DBRef: https://docs.mongodb.com/manual/reference/database-references/#dbrefs +.. _geoNear command: https://docs.mongodb.com/manual/reference/command/geoNear/ +.. _GridFS: https://docs.mongodb.com/manual/core/gridfs/ +.. _MongoBinData: http://php.net/manual/en/class.mongobindata.php +.. _MongoDate: http://php.net/manual/en/class.mongodate.php +.. _MongoGridFSFile: http://php.net/manual/en/class.mongogridfsfile.php +.. _MongoId: http://php.net/manual/en/class.mongoid.php +.. _MongoMaxKey: http://php.net/manual/en/class.mongomaxkey.php +.. _MongoMinKey: http://php.net/manual/en/class.mongominkey.php +.. _MongoTimestamp: http://php.net/manual/en/class.mongotimestamp.php +.. |FQCN| raw:: html + FQCN diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/architecture.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/architecture.rst.txt new file mode 100644 index 0000000..6b4fe7d --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/architecture.rst.txt @@ -0,0 +1,124 @@ +Architecture +============ + +This chapter gives an overview of the overall architecture, +terminology and constraints of Doctrine. It is recommended to +read this chapter carefully. + +Documents +--------- + +A document is a lightweight, persistent domain object. A document can +be any regular PHP class observing the following restrictions: + +- A document class must not be final or contain final methods. +- All persistent properties/field of any document class should + always be private or protected, otherwise lazy-loading might not + work as expected. +- A document class must not implement ``__clone`` or + :doc:`do so safely <../cookbook/implementing-wakeup-or-clone>`. +- A document class must not implement ``__wakeup`` or + :doc:`do so safely <../cookbook/implementing-wakeup-or-clone>`. + Also consider implementing + `Serializable `_ + instead. +- Any two document classes in a class hierarchy that inherit + directly or indirectly from one another must not have a mapped + property with the same name. That is, if B inherits from A then B + must not have a mapped field with the same name as an already + mapped field that is inherited from A. + +Documents support inheritance, polymorphic associations, and +polymorphic queries. Both abstract and concrete classes can be +documents. Documents may extend non-document classes as well as document +classes, and non-document classes may extend document classes. + +.. tip:: + + The constructor of a document is only ever invoked when + *you* construct a new instance with the *new* keyword. Doctrine + never calls document constructors, thus you are free to use them as + you wish and even have it require arguments of any type. + +Document states +~~~~~~~~~~~~~~~ + +A document instance can be characterized as being NEW, MANAGED, DETACHED or REMOVED. + +- A NEW document instance has no persistent identity, and is not yet + associated with a DocumentManager and a UnitOfWork (i.e. those just + created with the "new" operator). +- A MANAGED document instance is an instance with a persistent + identity that is associated with a DocumentManager and whose + persistence is thus managed. +- A DETACHED document instance is an instance with a persistent + identity that is not (or no longer) associated with a + DocumentManager and a UnitOfWork. +- A REMOVED document instance is an instance with a persistent + identity, associated with a DocumentManager, that will be removed + from the database upon transaction commit. + +Persistent fields +~~~~~~~~~~~~~~~~~ + +The persistent state of a document is represented by instance +variables. An instance variable must be directly accessed only from +within the methods of the document by the document instance itself. +Instance variables must not be accessed by clients of the document. +The state of the document is available to clients only through the +document's methods, i.e. accessor methods (getter/setter methods) or +other business methods. + +Collection-valued persistent fields and properties must be defined +in terms of the ``Doctrine\Common\Collections\Collection`` +interface. The collection implementation type may be used by the +application to initialize fields or properties before the document is +made persistent. Once the document becomes managed (or detached), +subsequent access must be through the interface type. + +Serializing documents +~~~~~~~~~~~~~~~~~~~~~ + +Serializing documents can be problematic and is not really +recommended, at least not as long as a document instance still holds +references to proxy objects or is still managed by an +DocumentManager. If you intend to serialize (and unserialize) document +instances that still hold references to proxy objects you may run +into problems with private properties because of technical +limitations. Proxy objects implement ``__sleep`` and it is not +possible for ``__sleep`` to return names of private properties in +parent classes. On the other hand it is not a solution for proxy +objects to implement ``Serializable`` because Serializable does not +work well with any potential cyclic object references (at least we +did not find a way yet, if you did, please contact us). + +The DocumentManager +------------------- + +The ``DocumentManager`` class is a central access point to the ODM +functionality provided by Doctrine. The ``DocumentManager`` API is +used to manage the persistence of your objects and to query for +persistent objects. + +Transactional write-behind +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +An ``DocumentManager`` and the underlying ``UnitOfWork`` employ a +strategy called "transactional write-behind" that delays the +execution of query statements in order to execute them in the most +efficient way and to execute them at the end of a transaction so +that all write locks are quickly released. You should see Doctrine +as a tool to synchronize your in-memory objects with the database +in well defined units of work. Work with your objects and modify +them as usual and when you're done call ``DocumentManager#flush()`` +to make your changes persistent. + +The Unit of Work +~~~~~~~~~~~~~~~~ + +Internally an ``DocumentManager`` uses a ``UnitOfWork``, which is a +typical implementation of the +`Unit of Work pattern `_, +to keep track of all the things that need to be done the next time +``flush`` is invoked. You usually do not directly interact with a +``UnitOfWork`` but with the ``DocumentManager`` instead. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/basic-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/basic-mapping.rst.txt new file mode 100644 index 0000000..52900f8 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/basic-mapping.rst.txt @@ -0,0 +1,621 @@ +Basic Mapping +============= + +This chapter explains the basic mapping of objects and properties. +Mapping of references and embedded documents will be covered in the +next chapter "Reference Mapping". + +Mapping Drivers +--------------- + +Doctrine provides several different ways for specifying object +document mapping metadata: + +- Docblock Annotations +- XML +- YAML +- Raw PHP Code + +.. note:: + + If you're wondering which mapping driver gives the best + performance, the answer is: None. Once the metadata of a class has + been read from the source (annotations, xml or yaml) it is stored + in an instance of the + ``Doctrine\ODM\MongoDB\Mapping\ClassMetadata`` class and these + instances are stored in the metadata cache. Therefore at the end of + the day all drivers perform equally well. If you're not using a + metadata cache (not recommended!) then the XML driver might have a + slight edge in performance due to the powerful native XML support + in PHP. + +Introduction to Docblock Annotations +------------------------------------ + +You've probably used docblock annotations in some form already, +most likely to provide documentation metadata for a tool like +``PHPDocumentor`` (@author, @link, ...). Docblock annotations are a +tool to embed metadata inside the documentation section which can +then be processed by some tool. Doctrine generalizes the concept of +docblock annotations so that they can be used for any kind of +metadata and so that it is easy to define new docblock annotations. +In order to allow more involved annotation values and to reduce the +chances of clashes with other docblock annotations, the Doctrine +docblock annotations feature an alternative syntax that is heavily +inspired by the Annotation syntax introduced in Java 5. + +The implementation of these enhanced docblock annotations is +located in the ``Doctrine\Common\Annotations`` namespace and +therefore part of the Common package. Doctrine docblock annotations +support namespaces and nested annotations among other things. The +Doctrine MongoDB ODM defines its own set of docblock annotations +for supplying object document mapping metadata. + +.. note:: + + If you're not comfortable with the concept of docblock + annotations, don't worry, as mentioned earlier Doctrine 2 provides + XML and YAML alternatives and you could easily implement your own + favorite mechanism for defining ORM metadata. + +Persistent classes +------------------ + +In order to mark a class for object-relational persistence it needs +to be designated as a document. This can be done through the +``@Document`` marker annotation. + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + Documents\User: + type: document + +By default, the document will be persisted to a database named +doctrine and a collection with the same name as the class name. In +order to change that, you can use the ``db`` and ``collection`` +option as follows: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + Documents\User: + type: document + db: my_db + collection: users + +Now instances of ``Documents\User`` will be persisted into a +collection named ``users`` in the database ``my_db``. + +If you want to omit the db attribute you can configure the default db +to use with the ``setDefaultDB`` method: + +.. code-block:: php + + setDefaultDB('my_db'); + +.. _doctrine_mapping_types: + +Doctrine Mapping Types +---------------------- + +A Doctrine Mapping Type defines the mapping between a PHP type and +an MongoDB type. You can even write your own custom mapping types. + +Here is a quick overview of the built-in mapping types: + +- ``bin`` +- ``bin_bytearray`` +- ``bin_custom`` +- ``bin_func`` +- ``bin_md5`` +- ``bin_uuid`` +- ``boolean`` +- ``collection`` +- ``custom_id`` +- ``date`` +- ``file`` +- ``float`` +- ``hash`` +- ``id`` +- ``int`` +- ``key`` +- ``object_id`` +- ``raw`` +- ``string`` +- ``timestamp`` + +You can read more about the available MongoDB types on `php.net `_. + +.. note:: + + The Doctrine mapping types are used to convert the local PHP types to the MongoDB types + when persisting so that your domain is not bound to MongoDB-specific types. For example a + DateTime instance may be converted to MongoDate when you persist your documents, and vice + versa during hydration. + +Generally, the name of each built-in mapping type hints as to how the value will be converted. +This list explains some of the less obvious mapping types: + +- ``bin``: string to MongoBinData instance with a "generic" type (default) +- ``bin_bytearray``: string to MongoBinData instance with a "byte array" type +- ``bin_custom``: string to MongoBinData instance with a "custom" type +- ``bin_func``: string to MongoBinData instance with a "function" type +- ``bin_md5``: string to MongoBinData instance with a "md5" type +- ``bin_uuid``: string to MongoBinData instance with a "uuid" type +- ``collection``: numerically indexed array to MongoDB array +- ``date``: DateTime to MongoDate +- ``hash``: associative array to MongoDB object +- ``id``: string to MongoId by default, but other formats are possible +- ``timestamp``: string to MongoTimestamp +- ``raw``: any type + +.. note:: + + If you are using the hash type, values within the associative array are + passed to MongoDB directly, without being prepared. Only formats suitable for + the Mongo driver should be used. If your hash contains values which are not + suitable you should either use an embedded document or use formats provided + by the MongoDB driver (e.g. ``\MongoDate`` instead of ``\DateTime``). + +Property Mapping +---------------- + +After a class has been marked as a document it can specify +mappings for its instance fields. Here we will only look at simple +fields that hold scalar values like strings, numbers, etc. +References to other objects and embedded objects are covered in the +chapter "Reference Mapping". + +.. _basic_mapping_identifiers: + +Identifiers +~~~~~~~~~~~ + +Every document class needs an identifier. You designate the field +that serves as the identifier with the ``@Id`` marker annotation. +Here is an example: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + Documents\User: + fields: + id: + type: id + id: true + +You can configure custom ID strategies if you don't want to use the default MongoId. +The available strategies are: + +- ``AUTO`` - Uses the native generated MongoId. +- ``ALNUM`` - Generates an alpha-numeric string (based on an incrementing value). +- ``CUSTOM`` - Defers generation to a AbstractIdGenerator implementation specified in the ``class`` option. +- ``INCREMENT`` - Uses another collection to auto increment an integer identifier. +- ``UUID`` - Generates a UUID identifier. +- ``NONE`` - Do not generate any identifier. ID must be manually set. + +Here is an example how to manually set a string identifier for your documents: + +.. configuration-block:: + + .. code-block:: php + + id = $id; + } + + //... + } + + .. code-block:: xml + + + + + + + + + .. code-block:: yaml + + MyPersistentClass: + fields: + id: + type: string + id: true + strategy: NONE + +When using the ``NONE`` strategy you will have to explicitly set an id before persisting the document: + +.. code-block:: php + + setId('my_unique_identifier'); + $dm->persist($document); + $dm->flush(); + +Now you can retrieve the document later: + +.. code-block:: php + + find('MyPersistentClass', 'my_unique_identifier'); + +You can define your own ID generator by extending the +``Doctrine\ODM\MongoDB\Id\AbstractIdGenerator`` class and specifying the class +as an option for the ``CUSTOM`` strategy: + +.. configuration-block:: + + .. code-block:: php + + id = $id; + } + + //... + } + + .. code-block:: xml + + + + + + + + + + + .. code-block:: yaml + + MyPersistentClass: + fields: + id: + id: true + strategy: CUSTOM + type: string + options: + class: Vendor\Specific\Generator + + + +Fields +~~~~~~ + +To mark a property for document persistence the ``@Field`` docblock +annotation can be used. This annotation usually requires at least 1 +attribute to be set, the ``type``. The ``type`` attribute specifies +the Doctrine Mapping Type to use for the field. If the type is not +specified, 'string' is used as the default mapping type since it is +the most flexible. + +Example: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + .. code-block:: yaml + + Documents\User: + fields: + id: + type: id + id: true + username: + type: string + +In that example we mapped the property ``id`` to the field ``id`` +using the mapping type ``id`` and the property ``name`` is mapped +to the field ``name`` with the default mapping type ``string``. As +you can see, by default the mongo field names are assumed to be the +same as the property names. To specify a different name for the +field, you can use the ``name`` attribute of the Field annotation +as follows: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + name: + name: db_name + +Custom Mapping Types +-------------------- + +Doctrine allows you to create new mapping types. This can come in +handy when you're missing a specific mapping type or when you want +to replace the existing implementation of a mapping type. + +In order to create a new mapping type you need to subclass +``Doctrine\ODM\MongoDB\Types\Type`` and implement/override +the methods. Here is an example skeleton of such a custom type +class: + +.. code-block:: php + + sec); + } + + public function closureToPHP() + { + // Return the string body of a PHP closure that will receive $value + // and store the result of a conversion in a $return variable + return '$return = new \DateTime($value);'; + } + + public function convertToDatabaseValue($value) + { + // This is called to convert a PHP value to its Mongo equivalent + return new \MongoDate($value); + } + } + +Restrictions to keep in mind: + +- + If the value of the field is *NULL* the method + ``convertToDatabaseValue()`` is not called. +- + The ``UnitOfWork`` never passes values to the database convert + method that did not change in the request. + +When you have implemented the type you still need to let Doctrine +know about it. This can be achieved through the +``Doctrine\ODM\MongoDB\Types\Type#registerType($name, $class)`` +method. + +Here is an example: + +.. code-block:: php + + + + .. code-block:: yaml + + field: + type: mytype + +Multiple Document Types in a Collection +--------------------------------------- + +You can easily store multiple types of documents in a single collection. This +requires specifying the same collection name, ``discriminatorField``, and +(optionally) ``discriminatorMap`` mapping options for each class that will share +the collection. Here is an example: + +.. code-block:: php + + createQuery(array('Article', 'Album')); + $documents = $query->execute(); + +The above will return a cursor that will allow you to iterate over all +``Article`` and ``Album`` documents in the collections. + +.. |FQCN| raw:: html + FQCN diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/best-practices.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/best-practices.rst.txt new file mode 100644 index 0000000..33913b2 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/best-practices.rst.txt @@ -0,0 +1,70 @@ +Best Practices +============== + +Here are some best practices you can follow when working with the Doctrine MongoDB ODM. + +Constrain relationships as much as possible +------------------------------------------- + +It is important to constrain relationships as much as possible. This means: + +- Impose a traversal direction (avoid bidirectional associations if possible) +- Eliminate nonessential associations + +This has several benefits: + +- Reduced coupling in your domain model +- Simpler code in your domain model (no need to maintain bidirectionality properly) +- Less work for Doctrine + +Use events judiciously +---------------------- + +The event system of Doctrine is great and fast. Even though making +heavy use of events, especially lifecycle events, can have a +negative impact on the performance of your application. Thus you +should use events judiciously. + +Use cascades judiciously +------------------------ + +Automatic cascades of the persist/remove/merge/etc. operations are +very handy but should be used wisely. Do NOT simply add all +cascades to all associations. Think about which cascades actually +do make sense for you for a particular association, given the +scenarios it is most likely used in. + +Don't use special characters +---------------------------- + +Avoid using any non-ASCII characters in class, field, table or +column names. Doctrine itself is not unicode-safe in many places +and will not be until PHP itself is fully unicode-aware. + +Initialize collections in the constructor +----------------------------------------- + +It is recommended best practice to initialize any business +collections in documents in the constructor. + +Example: + +.. code-block:: php + + addresses = new ArrayCollection; + $this->articles = new ArrayCollection; + } + } diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/bidirectional-references.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/bidirectional-references.rst.txt new file mode 100644 index 0000000..6827be5 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/bidirectional-references.rst.txt @@ -0,0 +1,218 @@ +Bi-Directional References +========================= + +By default when you map a bi-directional reference, the reference is maintained on both sides +of the relationship and there is not a single "owning side". Both sides are considered owning +and changes are tracked and persisted separately. Here is an example: + +.. code-block:: php + + setUser($user); + + $post2 = new BlogPost(); + $post2->setUser($user); + + $post3 = new BlogPost(); + $post3->setUser($user); + + $dm->persist($post1); + $dm->persist($post2); + $dm->persist($post3); + $dm->flush(); + +And we retrieve the ``User`` later to access the posts for that user: + +.. code-block:: php + + find('User', $user->id); + + $posts = $user->getPosts(); + foreach ($posts as $post) { + // ... + } + +The above will execute a query like the following to lazily load the collection of posts to +iterate over: + +.. code-block:: javascript + + db.BlogPost.find( { 'user.$id' : user.id } ) + +.. note:: + + Remember that the inverse side, the side which specified ``mappedBy`` is immutable and + any changes to the state of the reference will not be persisted. + +Other Examples +-------------- + +Here are several examples which implement the ``inversedBy`` and ``mappedBy`` options: + +One to One +~~~~~~~~~~~ + +Here is an example where we have a one to one relationship between ``Cart`` and ``Customer``: + +.. code-block:: php + + setCustomer(null); + $dm->flush(); + +.. note:: + + When specifying inverse one-to-one relationships the referenced document is + loaded directly when the owning document is hydrated instead of using a + proxy. In the example above, loading a ``Customer`` object from the database + would also cause the corresponding ``Cart`` to be loaded. This can cause + performance issues when loading many ``Customer`` objects at once. + +Self-Referencing Many to Many +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: php + + name = $name; + $this->friendsWithMe = new \Doctrine\Common\Collections\ArrayCollection(); + $this->myFriends = new \Doctrine\Common\Collections\ArrayCollection(); + } + + public function addFriend(User $user) + { + $user->friendsWithMe[] = $this; + $this->myFriends[] = $user; + } + } + +.. _DBRef: https://docs.mongodb.com/manual/reference/database-references/#dbrefs diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/capped-collections.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/capped-collections.rst.txt new file mode 100644 index 0000000..d48dad0 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/capped-collections.rst.txt @@ -0,0 +1,92 @@ +Capped Collections +================== + +Capped collections are fixed sized collections that have a very +high performance auto-LRU age-out feature (age out is based on +insertion order). + +In addition, capped collections automatically, with high +performance, maintain insertion order for the objects in the +collection; this is very powerful for certain use cases such as +logging. + +Mapping +------- + +You can configure the collection in the ``collection`` attribute of +the ``@Document`` annotation: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + .. code-block:: yaml + + Documents\Category: + type: document + collection: + name: collname + capped: true + size: 100000 + max: 1000 + fields: + id: + type: id + id: true + name: + type: string + +Creating +-------- + +Remember that you must manually create the collections. If you let +MongoDB create the collection lazily the first time it is selected, +it will not be created with the capped configuration. You can +create the collection for a document with the ``SchemaManager`` +that can be acquired from your ``DocumentManager`` instance: + +.. code-block:: php + + getSchemaManager()->createDocumentCollection('Category'); + +You can drop the collection too if it already exists: + +.. code-block:: php + + getSchemaManager()->dropDocumentCollection('Category'); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/change-tracking-policies.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/change-tracking-policies.rst.txt new file mode 100644 index 0000000..5e5bca3 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/change-tracking-policies.rst.txt @@ -0,0 +1,150 @@ +.. _change_tracking_policies: + +Change Tracking Policies +======================== + +Change tracking is the process of determining what has changed in +managed documents since the last time they were synchronized with +the database. + +Doctrine provides 3 different change tracking policies, each having +its particular advantages and disadvantages. The change tracking +policy can be defined on a per-class basis (or more precisely, +per-hierarchy). + +Deferred Implicit +~~~~~~~~~~~~~~~~~ + +The deferred implicit policy is the default change tracking policy +and the most convenient one. With this policy, Doctrine detects the +changes by a property-by-property comparison at commit time and +also detects changes to documents or new documents that are +referenced by other managed documents. Although the most convenient policy, +it can have negative effects on performance if you are dealing with large units +of work. Since Doctrine can't know what has changed, it needs to check +all managed documents for changes every time you invoke DocumentManager#flush(), +making this operation rather costly. + +Deferred Explicit +~~~~~~~~~~~~~~~~~ + +The deferred explicit policy is similar to the deferred implicit +policy in that it detects changes through a property-by-property +comparison at commit time. The difference is that only documents are +considered that have been explicitly marked for change detection +through a call to DocumentManager#persist(document) or through a save +cascade. All other documents are skipped. This policy therefore +gives improved performance for larger units of work while +sacrificing the behavior of "automatic dirty checking". + +Therefore, flush() operations are potentially cheaper with this +policy. The negative aspect this has is that if you have a rather +large application and you pass your objects through several layers +for processing purposes and business tasks you may need to track +yourself which documents have changed on the way so you can pass +them to DocumentManager#persist(). + +This policy can be configured as follows: + +.. code-block:: php + + _listeners[] = $listener; + } + } + +Then, in each property setter of this class or derived classes, you +need to notify all the ``PropertyChangedListener`` instances. As an +example we add a convenience method on ``MyDocument`` that shows this +behavior: + +.. code-block:: php + + _listeners) { + foreach ($this->_listeners as $listener) { + $listener->propertyChanged($this, $propName, $oldValue, $newValue); + } + } + } + + public function setData($data) + { + if ($data != $this->data) { + $this->_onPropertyChanged('data', $this->data, $data); + $this->data = $data; + } + } + } + +You have to invoke ``_onPropertyChanged`` inside every method that +changes the persistent state of ``MyDocument``. + +The check whether the new value is different from the old one is +not mandatory but recommended. That way you also have full control +over when you consider a property changed. + +The negative point of this policy is obvious: You need implement an +interface and write some plumbing code. But also note that we tried +hard to keep this notification functionality abstract. Strictly +speaking, it has nothing to do with the persistence layer. You may +find that property notification events come in handy in many other +scenarios as well. As mentioned earlier, the ``Doctrine\Common`` +namespace is not that evil and consists solely of very small classes +and interfaces that have almost no external dependencies and that you can easily take with you should +you want to swap out the persistence layer. This change tracking policy +does not introduce a dependency on the Doctrine persistence +layer. + +The positive point and main advantage of this policy is its +effectiveness. It has the best performance characteristics of the 3 +policies with larger units of work and a flush() operation is very +cheap when nothing has changed. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/complex-references.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/complex-references.rst.txt new file mode 100644 index 0000000..263e5a9 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/complex-references.rst.txt @@ -0,0 +1,152 @@ +Complex References +================== + +Sometimes you may want to access related documents using custom criteria or from +the inverse side of a relationship. + +You can create an `immutable`_ reference to one or many documents and specify +how that reference is to be loaded. The reference is immutable in that it is +defined only in the mapping, unlike a typical reference where a `MongoDBRef`_ or +identifier (see :ref:`storing_references`) is stored on the document itself. + +The following options may be used for :ref:`one ` and +:ref:`many ` reference mappings: + + - ``criteria`` - Query criteria to apply to the cursor. + - ``repositoryMethod`` - The repository method used to create the cursor. + - ``sort`` - Sort criteria for the cursor. + - ``skip`` - Skip offset to apply to the cursor. + - ``limit`` - Limit to apply to the cursor. + +Basic Example +------------- + +In the following example, ``$comments`` will refer to all Comments for the +BlogPost and ``$last5Comments`` will refer to only the last five Comments. The +``mappedBy`` field is used to determine which Comment field should be used for +querying by the BlogPost's ID. + +.. code-block:: php + + createQueryBuilder() + ->field('blogPost')->references($blogPost); + ->getQuery()->execute(); + } + } + +.. _MongoDBRef: http://php.net/manual/en/class.mongodbref.php +.. _immutable: http://en.wikipedia.org/wiki/Immutable diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/console-commands.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/console-commands.rst.txt new file mode 100644 index 0000000..f697867 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/console-commands.rst.txt @@ -0,0 +1,54 @@ +Console Commands +================ + +Doctrine MongoDB ODM offers some console commands, which utilize Symfony2's +Console component, to ease your development process: + +- ``odm:clear-cache:metadata`` - Clear all metadata cache of the various cache drivers. +- ``odm:query`` - Query mongodb and inspect the outputted results from your document classes. +- ``odm:generate:documents`` - Generate document classes and method stubs from your mapping information. +- ``odm:generate:hydrators`` - Generates hydrator classes for document classes. +- ``odm:generate:proxies`` - Generates proxy classes for document classes. +- ``odm:generate:repositories`` - Generate repository classes from your mapping information. +- ``odm:schema:create`` - Allows you to create databases, collections and indexes for your documents +- ``odm:schema:drop`` - Allows you to drop databases, collections and indexes for your documents +- ``odm:schema:update`` - Allows you to update indexes for your documents +- ``odm:schema:shard`` - Allows you to enable sharding for your documents + +Provided you have an existing ``DocumentManager`` instance, you can setup a +console command easily with the following code: + +.. code-block:: php + + new \Doctrine\ODM\MongoDB\Tools\Console\Helper\DocumentManagerHelper($dm), + )); + + $app = new Application('Doctrine MongoDB ODM'); + $app->setHelperSet($helperSet); + $app->addCommands(array( + new \Doctrine\ODM\MongoDB\Tools\Console\Command\GenerateDocumentsCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\GenerateHydratorsCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\GenerateProxiesCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\GenerateRepositoriesCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\QueryCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\ClearCache\MetadataCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\Schema\CreateCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\Schema\DropCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\Schema\UpdateCommand(), + new \Doctrine\ODM\MongoDB\Tools\Console\Command\Schema\ShardCommand(), + )); + + $app->run(); + +A reference implementation of the console command may be found in the +``tools/sandbox`` directory of the project repository. That command is +configured to store generated hydrators and proxies in the same directory, and +relies on the main project's Composer dependencies. You will want to customize +its configuration files if you intend to use it in your own project. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/custom-collections.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/custom-collections.rst.txt new file mode 100644 index 0000000..40aa155 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/custom-collections.rst.txt @@ -0,0 +1,170 @@ +.. _custom_collection: + +Custom Collections +================== + +.. note:: + This feature was introduced in version 1.1 + +By default, Doctrine uses ``ArrayCollection`` implementation of its ``Collection`` +interface to hold both embedded and referenced documents. That collection may then +be wrapped by a ``PersistentCollection`` to allow for change tracking and other +persistence-related features. + +.. code-block:: php + + sections = new ArrayCollection(); + } + + // ... + } + +For most cases this solution is sufficient but more sophisticated domains could use +their own collections (e.g. a collection that ensures its contained objects are sorted) +or to simply add common filtering methods that otherwise would otherwise be added to +owning document's class. + +Custom Collection Classes +------------------------- + +.. note:: + You may want to check `malarzm/collections `_ + which provides alternative implementations of Doctrine's ``Collection`` interface and + aims to kickstart development of your own collections. + +Using your own ``Collection`` implementation is as simple as specifying the +``collectionClass`` parameter in the ``@EmbedMany`` or ``@ReferenceMany`` mapping +and ensuring that your custom class is initialized in the owning class' constructor: + +.. code-block:: php + + sections = new SectionCollection(); + } + + // ... + } + +If you are satisfied with ``ArrayCollection`` and only want +to sprinkle it with some filtering methods, you may just extend it: + +.. code-block:: php + + filter(function(Section $s) { + return $s->isEnabled(); + }); + } + } + +Alternatively, you may want to implement the whole class from scratch: + +.. code-block:: php + + elements = $elements; + } + + // your implementation of all methods interface requires + } + +Taking Control of the Collection's Constructor +---------------------------------------------- + +By default, Doctrine assumes that it can instantiate your collections in same +manner as an ``ArrayCollection`` (i.e. the only parameter is an optional PHP +array); however, you may want to inject additional dependencies into your +custom collection class(es). This will require you to create a +`PersistentCollectionFactory implementation `_, +which Doctrine will then use to construct its persistent collections. +You may decide to implement this class from scratch or extend our +``AbstractPersistentCollectionFactory``: + +.. code-block:: php + + eventDispatcher = $eventDispatcher; + } + + protected function createCollectionClass($collectionClass) + { + switch ($collectionClass) { + case SectionCollection::class: + return new $collectionClass(array(), $this->eventDispatcher); + default: + return new $collectionClass; + } + } + } + +The factory class must then be registered in the ``Configuration``: + +.. code-block:: php + + get('event_dispatcher'); + $collFactory = new YourPersistentCollectionFactory($eventDispatcher); + $configuration = new Configuration(); + // your other config here + $configuration->setPersistentCollectionFactory($collFactory); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/document-repositories.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/document-repositories.rst.txt new file mode 100644 index 0000000..a86111d --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/document-repositories.rst.txt @@ -0,0 +1,210 @@ +.. _document_repositories: + +Document Repositories +===================== + +.. note:: + + A repository mediates between the domain and data mapping layers using a + collection-like interface for accessing domain objects. + +In Doctrine, a repository is a class that concentrates code responsible for +querying and filtering your documents. ODM provides you with a default +``DocumentRepository`` for all of your documents: + +.. code-block:: php + + getRepository(User::class); + $disabledUsers = $repository->findBy(['disabled' => true, 'activated' => true]); + +The array passed to ``findBy`` specifies the criteria for which documents are matched. +ODM will assist with converting PHP values to equivalent BSON types whenever possible: + +.. code-block:: php + + find(Group::class, 123); + /* @var $repository \Doctrine\ODM\MongoDB\DocumentRepository */ + $repository = $documentManager->getRepository(User::class); + $usersInGroup = $repository->findBy(['group' => $group]); + +The default repository implementation provides the following methods: + +- ``find()`` - finds one document by its identifier. This may skip a database query +if the document is already managed by ODM. +- ``findAll()`` - finds all documents in the collection. +- ``findBy()`` - finds all documents matching the given criteria. Additional query +options may be specified (e.g. sort, limit, skip). +- ``findOneBy()`` - finds one document matching the given criteria. +- ``matching()`` - Finds all documents matching the given criteria, as expressed +with Doctrine's Criteria API. + +.. note:: + + All above methods will include additional criteria specified by :ref:`Filters `. + +.. note:: + + Magic ``findBy`` and ``findOneBy`` calls described below are deprecated in 1.2 and + will be removed in 2.0. + +Additional methods that are not defined explicitly in the repository class may also be +used if they follow a specific naming convention: + +.. code-block:: php + + find(Group::class, 123); + /* @var $repository \Doctrine\ODM\MongoDB\DocumentRepository */ + $repository = $documentManager->getRepository(User::class); + $usersInGroup = $repository->findByGroup($group); + $randomUser = $repository->findOneByStatus('active'); + +In the above example, ``findByGroup()`` and ``findOneByStatus()`` will be handled by +the ``__call`` method, which intercepts calls to undefined methods. If the invoked +method's name starts with "findBy" or "findOneBy", ODM will attempt to infer mapped +properties from the remainder of the method name ("Group" or "Status" as per example). +The above calls are equivalent to: + +.. code-block:: php + + find(Group::class, 123); + /* @var $repository \Doctrine\ODM\MongoDB\DocumentRepository */ + $repository = $documentManager->getRepository(User::class); + $usersInGroup = $repository->findBy(['group' => $group]); + $randomUser = $repository->findOneBy(['status' => 'active']); + +Custom Repositories +------------------- + +A custom repository allows filtering logic to be consolidated into a single class instead +of spreading it throughout a project. A custom repository class may be specified for a +document class like so: + +.. configuration-block:: + + .. code-block:: php + + + + + + .. code-block:: yaml + + Documents\User: + repositoryClass: Repositories\\UserRepository + collection: user + # ... + +The next step is implementing your repository class. In most cases, ODM's default +``DocumentRepository`` class may be extended with additional methods that you need. +More complex cases that require passing additional dependencies to a custom repository +class will be discussed in the next section. + +.. code-block:: php + + findBy(['disabled' => true, 'activated' => true]); + } + } + +It is also possible to change ODM's default ``DocumentRepository`` to your own +implementation for all documents (unless overridden by the mapping): + +.. code-block:: php + + $documentManager->getConfiguration() + ->setDefaultRepositoryClassName(MyDefaultRepository::class); + +Repositories with Additional Dependencies +----------------------------------------- + +.. note:: + + Implementing your own RepositoryFactory is possible since version 1.0, but the + ``AbstractRepositoryFactory`` class used in this example is only available since 1.2. + +By default, Doctrine assumes that it can instantiate your repositories in same manner +as its default one: + +.. code-block:: php + + `_ + +.. code-block:: php + + eventDispatcher = $eventDispatcher; + } + + protected function instantiateRepository($repositoryClassName, DocumentManager $documentManager, ClassMetadata $metadata) + { + switch ($repositoryClassName) { + case UserRepository::class: + return new UserRepository($this->eventDispatcher, $documentManager, $metadata); + default: + return new $repositoryClassName($documentManager, $documentManager->getUnitOfWork(), $metadata); + } + } + } + +The factory class must then be registered in the ``Configuration``: + +.. code-block:: php + + get('event_dispatcher'); + $repoFactory = new YourRepositoryFactory($eventDispatcher); + $configuration = new Configuration(); + // your other config here + $configuration->setRepositoryFactory($repoFactory); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/eager-cursors.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/eager-cursors.rst.txt new file mode 100644 index 0000000..256c828 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/eager-cursors.rst.txt @@ -0,0 +1,46 @@ +Eager Cursors +------------- + +With a typical MongoDB cursor, it stays open during iteration and fetches +batches of documents as you iterate over the cursor. This isn't bad, +but sometimes you want to fetch all of the data eagerly. For example +when dealing with web applications, and you want to only show 50 +documents from a collection you should fetch all the data in your +controller first before going on to the view. + +Benefits: + +- The cursor stays open for a much shorter period of time. + +- Data retrieval and hydration are consolidated operations. + +- Doctrine has the ability to retry the cursor when exceptions during interaction with mongodb are encountered. + +Example: + +.. code-block:: php + + createQueryBuilder('User') + ->eagerCursor(true); + $query = $qb->getQuery(); + $users = $query->execute(); // returns instance of Doctrine\MongoDB\ODM\EagerCursor + +At this point all data is loaded from the database and cursors to MongoDB +have been closed but hydration of the data in to objects has not begun. Once +insertion starts the data will be hydrated in to PHP objects. + +Example: + +.. code-block:: php + + getUsername()."\n"; + } + +Not all documents are converted to objects at once, the hydration is still done +one document at a time during iteration. The only change is that all data is retrieved +first. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/embedded-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/embedded-mapping.rst.txt new file mode 100644 index 0000000..4e2f27e --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/embedded-mapping.rst.txt @@ -0,0 +1,283 @@ +Embedded Mapping +================ + +This chapter explains how embedded documents are mapped in +Doctrine. + +.. _embed_one: + +Embed One +--------- + +Embed a single document: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + User: + type: document + embedOne: + address: + targetDocument: Address + + Address: + type: embeddedDocument + +.. _embed_many: + +Embed Many +---------- + +Embed many documents: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + User: + type: document + embedMany: + phonenumbers: + targetDocument: Phonenumber + + Phonenumber: + type: embeddedDocument + +.. _embed_mixing_document_types: + +Mixing Document Types +--------------------- + +If you want to store different types of embedded documents in the same field, +you can simply omit the ``targetDocument`` option: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + embedMany: + tasks: ~ + +Now the ``$tasks`` property can store any type of document! The class name will +be automatically stored in a field named ``_doctrine_class_name`` within +the embedded document. The field name can be customized with the +``discriminatorField`` option: + +.. configuration-block:: + + .. code-block:: php + + + + + + .. code-block:: yaml + + embedMany: + tasks: + discriminatorField: type + +You can also specify a discriminator map to avoid storing the |FQCN| +in each embedded document: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + embedMany: + tasks: + discriminatorMap: + download: DownloadTask + build: BuildTask + +If you have embedded documents without a discriminator value that need to be +treated correctly you can optionally specify a default value for the +discriminator: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + .. code-block:: yaml + + embedMany: + tasks: + discriminatorMap: + download: DownloadTask + build: BuildTask + defaultDiscriminatorValue: download + +Cascading Operations +-------------------- + +All operations on embedded documents are automatically cascaded. +This is because embedded documents are part of their parent +document and cannot exist without those by nature. + +.. |FQCN| raw:: html + FQCN diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/events.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/events.rst.txt new file mode 100644 index 0000000..5a10c9d --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/events.rst.txt @@ -0,0 +1,717 @@ +Events +====== + +Doctrine features a lightweight event system that is part of the +Common package. + +The Event System +---------------- + +The event system is controlled by the ``EventManager``. It is the +central point of Doctrine's event listener system. Listeners are +registered on the manager and events are dispatched through the +manager. + +.. code-block:: php + + addEventListener(array(self::preFoo, self::postFoo), $this); + } + + public function preFoo(EventArgs $e) + { + $this->preFooInvoked = true; + } + + public function postFoo(EventArgs $e) + { + $this->postFooInvoked = true; + } + } + + // Create a new instance + $test = new EventTest($evm); + +Events can be dispatched by using the ``dispatchEvent()`` method. + +.. code-block:: php + + dispatchEvent(EventTest::preFoo); + $evm->dispatchEvent(EventTest::postFoo); + +You can easily remove a listener with the ``removeEventListener()`` +method. + +.. code-block:: php + + removeEventListener(array(self::preFoo, self::postFoo), $this); + +The Doctrine event system also has a simple concept of event +subscribers. We can define a simple ``TestEventSubscriber`` class +which implements the ``\Doctrine\Common\EventSubscriber`` interface +and implements a ``getSubscribedEvents()`` method which returns an +array of events it should be subscribed to. + +.. code-block:: php + + preFooInvoked = true; + } + + public function getSubscribedEvents() + { + return array(self::preFoo); + } + } + + $eventSubscriber = new TestEventSubscriber(); + $evm->addEventSubscriber($eventSubscriber); + +Now when you dispatch an event any event subscribers will be +notified for that event. + +.. code-block:: php + + dispatchEvent(TestEventSubscriber::preFoo); + +Now test the ``$eventSubscriber`` instance to see if the +``preFoo()`` method was invoked. + +.. code-block:: php + + preFooInvoked) { + echo 'pre foo invoked!'; + } + +.. _lifecycle_events: + +Lifecycle Events +---------------- + +The DocumentManager and UnitOfWork trigger several events during +the life-time of their registered documents. + +- + preRemove - The preRemove event occurs for a given document before + the respective DocumentManager remove operation for that document + is executed. +- + postRemove - The postRemove event occurs for a document after the + document has been removed. It will be invoked after the database + delete operations. +- + prePersist - The prePersist event occurs for a given document + before the respective DocumentManager persist operation for that + document is executed. +- + postPersist - The postPersist event occurs for a document after + the document has been made persistent. It will be invoked after the + database insert operations. Generated primary key values are + available in the postPersist event. +- + preUpdate - The preUpdate event occurs before the database update + operations to document data. +- + postUpdate - The postUpdate event occurs after the database update + operations to document data. +- + preLoad - The preLoad event occurs for a document before the + document has been loaded into the current DocumentManager from the + database or after the refresh operation has been applied to it. +- + postLoad - The postLoad event occurs for a document after the + document has been loaded into the current DocumentManager from the + database or after the refresh operation has been applied to it. +- + loadClassMetadata - The loadClassMetadata event occurs after the + mapping metadata for a class has been loaded from a mapping source + (annotations/xml/yaml). +- + preFlush - The preFlush event occurs before the change-sets of all + managed documents are computed. This both a lifecycle call back and + and listener. +- + postFlush - The postFlush event occurs after the change-sets of all + managed documents are computed. +- + onFlush - The onFlush event occurs after the change-sets of all + managed documents are computed. This event is not a lifecycle + callback. +- + onClear - The onClear event occurs after the UnitOfWork has had + its state cleared. +- + documentNotFound - The documentNotFound event occurs when a proxy object + could not be initialized. This event is not a lifecycle callback. +- + postCollectionLoad - The postCollectionLoad event occurs just after + collection has been initialized (loaded) and before new elements + are re-added to it. + +You can access the Event constants from the ``Events`` class in the +ODM package. + +.. code-block:: php + + createdAt = date('Y-m-d H:i:s'); + } + + /** @PrePersist */ + public function doOtherStuffOnPrePersist(\Doctrine\ODM\MongoDB\Event\LifecycleEventArgs $eventArgs) + { + $this->value = 'changed from prePersist callback!'; + } + + /** @PostPersist */ + public function doStuffOnPostPersist(\Doctrine\ODM\MongoDB\Event\LifecycleEventArgs $eventArgs) + { + $this->value = 'changed from postPersist callback!'; + } + + /** @PreLoad */ + public function doStuffOnPreLoad(\Doctrine\ODM\MongoDB\Event\PreLoadEventArgs $eventArgs) + { + $data =& $eventArgs->getData(); + $data['value'] = 'changed from preLoad callback'; + } + + /** @PostLoad */ + public function doStuffOnPostLoad(\Doctrine\ODM\MongoDB\Event\LifecycleEventArgs $eventArgs) + { + $this->value = 'changed from postLoad callback!'; + } + + /** @PreUpdate */ + public function doStuffOnPreUpdate(\Doctrine\ODM\MongoDB\Event\PreUpdateEventArgs $eventArgs) + { + $this->value = 'changed from preUpdate callback!'; + } + + /** @PreFlush */ + public function preFlush(\Doctrine\ODM\MongoDB\Event\PreFlushEventArgs $eventArgs) + { + $this->value = 'changed from preFlush callback!'; + } + } + +Note that when using annotations you have to apply the +@HasLifecycleCallbacks marker annotation on the document class. + +Listening to Lifecycle Events +----------------------------- + +Lifecycle event listeners are much more powerful than the simple +lifecycle callbacks that are defined on the document classes. They +allow to implement re-usable behaviours between different document +classes, yet require much more detailed knowledge about the inner +workings of the DocumentManager and UnitOfWork. Please read the +*Implementing Event Listeners* section carefully if you are trying +to write your own listener. + +To register an event listener you have to hook it into the +EventManager that is passed to the DocumentManager factory: + +.. code-block:: php + + addEventListener(array(Events::preUpdate), new MyEventListener()); + $eventManager->addEventSubscriber(new MyEventSubscriber()); + + $documentManager = DocumentManager::create($mongo, $config, $eventManager); + +You can also retrieve the event manager instance after the +DocumentManager was created: + +.. code-block:: php + + getEventManager()->addEventListener(array(Events::preUpdate), new MyEventListener()); + $documentManager->getEventManager()->addEventSubscriber(new MyEventSubscriber()); + +Implementing Event Listeners +---------------------------- + +This section explains what is and what is not allowed during +specific lifecycle events of the UnitOfWork. Although you get +passed the DocumentManager in all of these events, you have to +follow this restrictions very carefully since operations in the +wrong event may produce lots of different errors, such as +inconsistent data and lost updates/persists/removes. + +prePersist +~~~~~~~~~~ + +Listen to the ``prePersist`` event: + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::prePersist, $test); + +Define the ``EventTest`` class: + +.. code-block:: php + + getDocument(); + $document->setSomething(); + } + } + +preLoad +~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::preLoad, $test); + +Define the ``EventTest`` class with a ``preLoad()`` method: + +.. code-block:: php + + getData(); + // do something + } + } + +postLoad +~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::postLoad, $test); + +Define the ``EventTest`` class with a ``postLoad()`` method: + +.. code-block:: php + + getDocument(); + // do something + } + } + +preRemove +~~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::preRemove, $test); + +Define the ``EventTest`` class with a ``preRemove()`` method: + +.. code-block:: php + + getDocument(); + // do something + } + } + +preFlush +~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::preFlush, $test); + +Define the ``EventTest`` class with a ``preFlush()`` method: + +.. code-block:: php + + getDocumentManager(); + $uow = $dm->getUnitOfWork(); + // do something + } + } + +onFlush +~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::onFlush, $test); + +Define the ``EventTest`` class with a ``onFlush()`` method: + +.. code-block:: php + + getDocumentManager(); + $uow = $dm->getUnitOfWork(); + // do something + } + } + +postFlush +~~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::postFlush, $test); + +Define the ``EventTest`` class with a ``postFlush()`` method: + +.. code-block:: php + + getDocumentManager(); + $uow = $dm->getUnitOfWork(); + // do something + } + } + +preUpdate +~~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::preUpdate, $test); + +Define the ``EventTest`` class with a ``preUpdate()`` method: + +.. code-block:: php + + getDocument(); + $document->setSomething(); + $dm = $eventArgs->getDocumentManager(); + $class = $dm->getClassMetadata(get_class($document)); + $dm->getUnitOfWork()->recomputeSingleDocumentChangeSet($class, $document); + } + } + +.. note:: + + If you modify a document in the preUpdate event you must call ``recomputeSingleDocumentChangeSet`` + for the modified document in order for the changes to be persisted. + +onClear +~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::onClear, $test); + +Define the ``EventTest`` class with a ``onClear()`` method: + +.. code-block:: php + + getDocumentClass(); + $dm = $eventArgs->getDocumentManager(); + $uow = $dm->getUnitOfWork(); + + // Check if event clears all documents. + if ($eventArgs->clearsAllDocuments()) { + // do something + } + // do something + } + } + +documentNotFound +~~~~~~~~~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::documentNotFound, $test); + +Define the ``EventTest`` class with a ``documentNotFound()`` method: + +.. code-block:: php + + getObject(); + $identifier = $eventArgs->getIdentifier(); + // do something + // To prevent the documentNotFound exception from being thrown, call the disableException() method: + $eventArgs->disableException(); + } + } + + +postUpdate, postRemove, postPersist +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::postUpdate, $test); + $evm->addEventListener(Events::postRemove, $test); + $evm->addEventListener(Events::postPersist, $test); + +Define the ``EventTest`` class with a ``postUpdate()``, ``postRemove()`` and ``postPersist()`` method: + +.. code-block:: php + + getEventManager(); + $evm->addEventListener(Events::postCollectionLoad, $test); + +Define the ``EventTest`` class with a ``postCollectionLoad()`` method: + +.. code-block:: php + + getCollection(); + if ($collection instanceof \Malarzm\Collections\DiffableCollection) { + $collection->snapshot(); + } + } + } + + +Load ClassMetadata Event +------------------------ + +When the mapping information for a document is read, it is +populated in to a ``ClassMetadata`` instance. You can hook in to +this process and manipulate the instance with the ``loadClassMetadata`` event: + +.. code-block:: php + + getMetadataFactory(); + $evm = $dm->getEventManager(); + $evm->addEventListener(Events::loadClassMetadata, $test); + + class EventTest + { + public function loadClassMetadata(\Doctrine\ODM\MongoDB\Event\LoadClassMetadataEventArgs $eventArgs) + { + $classMetadata = $eventArgs->getClassMetadata(); + $fieldMapping = array( + 'fieldName' => 'about', + 'type' => 'string' + ); + $classMetadata->mapField($fieldMapping); + } + } diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/filters.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/filters.rst.txt new file mode 100644 index 0000000..e3dce70 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/filters.rst.txt @@ -0,0 +1,93 @@ +.. _filters: + +Filters +======= + +Doctrine features a filter system that allows the developer to add additional +criteria to queries, regardless of where the query is generated within the +application (e.g. from a query builder, loading referenced documents). This is +useful for excluding documents at a low level, to ensure that they are neither +returned from MongoDB nor hydrated by ODM. + +Example filter class +-------------------- + +Throughout this document, the example ``MyLocaleFilter`` class will be used to +illustrate how the filter feature works. A filter class must extend the base +``Doctrine\ODM\MongoDB\Query\Filter\BsonFilter`` class and implement the +``addFilterCriteria()`` method. This method receives ``ClassMetadata`` and is +invoked whenever a query is prepared for any class. Since filters are typically +designed with a specific class or interface in mind, ``addFilterCriteria()`` +will frequently start by checking ``ClassMetadata`` and returning immediately if +it is not supported. + +Parameters for the query should be set on the filter object by calling the +``BsonFilter::setParameter()`` method. Within the filter class, parameters +should be accessed via ``BsonFilter::getParameter()``. + +.. code-block:: php + + reflClass->implementsInterface('LocaleAware')) { + return array(); + } + + return array('locale' => $this->getParameter('locale')); + } + } + +Configuration +------------- +Filter classes are added to the configuration as following: + +.. code-block:: php + + addFilter('locale', '\Vendor\Filter\MyLocaleFilter'); + +The ``Configuration#addFilter()`` method takes a name for the filter and the +name of the filter class, which will be constructed as necessary. + +An optional third parameter may be used to set parameters at configuration time: + +.. code-block:: php + + addFilter('locale', '\Vendor\Filter\MyLocaleFilter', array('locale' => 'en')); + +Disabling/Enabling Filters and Setting Parameters +------------------------------------------------- + +Filters can be disabled and enabled via the ``FilterCollection``, which is +stored in the ``DocumentManager``. The ``FilterCollection#enable($name)`` method +may be used to enabled and return a filter, after which you may set parameters. + +.. code-block:: php + + getFilterCollection()->enable("locale"); + $filter->setParameter('locale', array('$in' => array('en', 'fr')); + + // Disable the filter (perhaps temporarily to run an unfiltered query) + $filter = $dm->getFilterCollection()->disable("locale"); + +.. warning:: + + Disabling and enabling filters has no effect on managed documents. If you + want to refresh or reload an object after having modified a filter or the + FilterCollection, then you should clear the DocumentManager and re-fetch + your documents so the new filtering rules may be applied. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/find-and-update.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/find-and-update.rst.txt new file mode 100644 index 0000000..8f9dfc2 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/find-and-update.rst.txt @@ -0,0 +1,84 @@ +Find and Modify +=============== + +.. note:: + + From MongoDB.org: + + MongoDB supports a "find, modify, and return" command. This command + can be used to atomically modify a document (at most one) and + return it. Note that, by default, the document returned will not + include the modifications made on the update. + +Doctrine fully integrates the find and modify functionality to the +query builder object so you can easily run these types of queries! + +Update +------ + +For example you can update a job and return it: + +.. code-block:: php + + createQueryBuilder('Job') + // Find the job + ->findAndUpdate() + ->field('in_progress')->equals(false) + ->sort('priority', 'desc') + + // Update found job + ->field('started')->set(new \MongoDate()) + ->field('in_progress')->set(true) + ->getQuery() + ->execute(); + +If you want to update a job and return the new document you can +call the ``returnNew()`` method. + +Here is an example where we return the new updated job document: + +.. code-block:: php + + createQueryBuilder('Job') + // Find the job + ->findAndUpdate() + ->returnNew() + ->field('in_progress')->equals(false) + ->sort('priority', 'desc') + + // Update found job + ->field('started')->set(new \MongoDate()) + ->field('in_progress')->set(true) + ->getQuery() + ->execute(); + +The returned ``$job`` will be a managed ``Job`` instance with the +``started`` and ``in_progress`` fields updated. + +Remove +------ + +You can also remove a document and return it: + +.. code-block:: php + + createQueryBuilder('Job') + ->findAndRemove() + ->sort('priority', 'desc') + ->getQuery() + ->execute(); + +You can read more about the find and modify functionality on the +`MongoDB website `_. + +.. note:: + + If you don't need to return the document, you can use just run a normal update which can + affect multiple documents, as well. For multiple update to happen you need to use + ``->updateMany()`` method of the builder (or ``update()->multiple()`` combination that + was deprecated in version 1.2). diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/geospatial-queries.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/geospatial-queries.rst.txt new file mode 100644 index 0000000..fd22ab9 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/geospatial-queries.rst.txt @@ -0,0 +1,141 @@ +Geospatial Queries +================== + +You can execute some special queries when using geospatial indexes +like checking for documents within a rectangle or circle. + +Mapping +------- + +First, setup some documents like the following: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + indexes: + coordinates: + keys: + coordinates: 2d + +Near Query +---------- + +Now you can execute queries against these documents like the +following. Check for the 10 nearest cities to a given longitude +and latitude with the ``near($longitude, $latitude)`` method: + +.. code-block:: php + + dm->createQuery('City') + ->field('coordinates')->near(-120, 40) + ->execute(); + +.. _geonear: + +GeoNear Command +--------------- + +You can also execute the `geoNear command`_ using the query builder's +``geoNear()`` method. Additional builder methods can be used to set options for +this command (e.g. ``distanceMultipler()``, ``maxDistance()``, ``spherical()``). +Unlike ``near()``, which uses a query operator, ``geoNear()`` does not require +the location field to be specified in the builder, as MongoDB will use the +single geospatial index for the collection. Documents will be returned in order +of nearest to farthest. + +.. code-block:: php + + dm->createQuery('City') + ->geoNear(-120, 40) + ->spherical(true) + // Convert radians to kilometers (use 3963.192 for miles) + ->distanceMultiplier(6378.137) + ->execute(); + +If the model has a property mapped with :ref:`@Distance `, +that field will be set with the calculated distance between the document and the +query coordinates. + +.. code-block:: php + + name, $city->distance); + } + +.. _`geoNear command`: https://docs.mongodb.com/manual/reference/command/geoNear/ + +Within Box +---------- + +You can also query for cities within a given rectangle using the +``withinBox($x1, $y1, $x2, $y2)`` method: + +.. code-block:: php + + dm->createQuery('City') + ->field('coordinates')->withinBox(41, 41, 72, 72) + ->execute(); + +Within Center +------------- + +In addition to boxes you can check for cities within a circle using +the ``withinCenter($x, $y, $radius)`` method: + +.. code-block:: php + + dm->createQuery('City') + ->field('coordinates')->withinCenter(50, 50, 20) + ->execute(); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/indexes.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/indexes.rst.txt new file mode 100644 index 0000000..6c527dd --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/indexes.rst.txt @@ -0,0 +1,549 @@ +Indexes +======= + +Working with indexes in the MongoDB ODM is pretty straight forward. +You can have multiple indexes, they can consist of multiple fields, +they can be unique and you can give them an order. In this chapter +we'll show you examples of indexes using annotations. + +First here is an example where we put an index on a single +property: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + fields: + username: + index: true + + +Index Options +------------- + +You can customize the index with some additional options: + +- + **name** - The name of the index. This can be useful if you are + indexing many keys and Mongo complains about the index name being + too long. +- + **dropDups** - If a unique index is being created and duplicate + values exist, drop all but one duplicate value. +- + **background** - Create indexes in the background while other + operations are taking place. By default, index creation happens + synchronously. If you specify TRUE with this option, index creation + will be asynchronous. +- + **safe** - You can specify a boolean value for checking if the + index creation succeeded. The driver will throw a + MongoCursorException if index creation failed. +- + **expireAfterSeconds** - If you specify this option then the associated + document will be automatically removed when the provided time (in seconds) + has passed. This option is bound to a number of limitations, which + are documented at https://docs.mongodb.com/manual/tutorial/expire-data/. +- + **order** - The order of the index (asc or desc). +- + **unique** - Create a unique index. +- + **sparse** - Create a sparse index. If a unique index is being created + the sparse option will allow duplicate null entries, but the field must be + unique otherwise. +- + **partialFilterExpression** - Create a partial index. Partial indexes only + index the documents in a collection that meet a specified filter expression. + By indexing a subset of the documents in a collection, partial indexes have + lower storage requirements and reduced performance costs for index creation + and maintenance. This feature was introduced with MongoDB 3.2 and is not + available on older versions. + +Unique Index +------------ + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + fields: + username: + index: true + unique: true + order: true + +For your convenience you can quickly specify a unique index with +``@UniqueIndex``: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + fields: + username: + unique: true + order: true + +If you want to specify an index that consists of multiple fields +you can specify them on the class doc block: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + .. code-block:: yaml + + Documents\User: + indexes: + usernameacctid: + options: + unique: true + keys: + accountId: + order: asc + username: + order: asc + +To specify multiple indexes you must use the ``@Indexes`` +annotation: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + + + + + .. code-block:: yaml + + Documents\User: + indexes: + accountId: + keys: + accountId: + order: asc + username: + keys: + username: + order: asc + +Embedded Indexes +---------------- + +You can specify indexes on embedded documents just like you do on normal documents. When Doctrine +creates the indexes for a document it will also create all the indexes from its mapped embedded +documents. + +.. code-block:: php + + ensureIndexes(); + +It will create the indexes from the ``BlogPost`` document but will also create the indexes that are +defined on the ``Comment`` embedded document. The following would be executed on the underlying MongoDB +database: + +.. + + db.BlogPost.ensureIndexes({ 'slug' : 1, 'comments.date': 1 }) + +Also, for your convenience you can create the indexes for your mapped documents from the +:doc:`console `: + +.. + + $ php mongodb.php mongodb:schema:create --index + +.. note:: + + If you are :ref:`mixing document types ` for your + embedded documents, ODM will not be able to create indexes for their fields + unless you specify a discriminator map for the :ref:`embed-one ` + or :ref:`embed-many ` relationship. + +Geospatial Indexing +------------------- + +You can specify a geospatial index by just specifying the keys and +options structures manually: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + indexes: + coordinates: + keys: + coordinates: 2d + +Partial indexes +--------------- + +You can create a partial index by adding a ``partialFilterExpression`` to any +index. + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + .. code-block:: yaml + + indexes: + partialIndexExample: + keys: + coordinates: asc + options: + partialFilterExpression: + version: { $gt: 1 } + +.. note:: + + Partial indexes are only available with MongoDB 3.2 or newer. For more + information on partial filter expressions, read the + `official MongoDB documentation `_. + +Requiring Indexes +----------------- + +.. note:: + Requiring Indexes was deprecated in 1.2 and will be removed in 2.0. + +Sometimes you may want to require indexes for all your queries to ensure you don't let stray unindexed queries +make it to the database and cause performance problems. + + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + + + + + + .. code-block:: yaml + + # Documents.Place.dcm.yml + + Documents\Place: + fields: + id: + id: true + city: + type: string + indexes: + index1: + keys: + city: asc + +When you run queries it will check that it is indexed and throw an exception if it is not indexed: + +.. code-block:: php + + createQueryBuilder('Documents\Place') + ->field('city')->equals('Nashville'); + $query = $qb->getQuery(); + $places = $query->execute(); + +When you execute the query it will throw an exception if `city` was not indexed in the database. You can control +whether or not an exception will be thrown by using the `requireIndexes()` method: + +.. code-block:: php + + requireIndexes(false); + +You can also check if the query is indexed and with the `isIndexed()` method and use it to display your +own notification when a query is unindexed: + +.. code-block:: php + + getQuery(); + if (!$query->isIndexed()) { + $notifier->addError('Cannot execute queries that are not indexed.'); + } + +If you don't want to require indexes for all queries you can set leave `requireIndexes` as false and control +it on a per query basis: + +.. code-block:: php + + requireIndexes(true); + $query = $qb->getQuery(); + $results = $query->execute(); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/inheritance-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/inheritance-mapping.rst.txt new file mode 100644 index 0000000..1f5fec3 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/inheritance-mapping.rst.txt @@ -0,0 +1,280 @@ +.. _inheritance_mapping: + +Inheritance Mapping +=================== + +Doctrine currently offers two supported methods of inheritance: +:ref:`single collection ` and +:ref:`collection per class ` inheritance. + +Mapped Superclasses +------------------- + +A mapped superclass is an abstract or concrete class that provides mapping +information for its subclasses, but is not itself a document. Typically, the +purpose of such a mapped superclass is to define state and mapping information +that is common to multiple document classes. + +Just like non-mapped classes, mapped superclasses may appear in the middle of +an otherwise mapped inheritance hierarchy (through +:ref:`single collection ` or +:ref:`collection per class `) inheritance. + +.. note:: + + A mapped superclass cannot be a document and is not queryable. + +Example: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + Documents\BaseDocument: + type: mappedSuperclass + +.. _single_collection_inheritance: + +Single Collection Inheritance +----------------------------- + +In single collection inheritance, each document is stored in a single collection +and a discriminator field is used to distinguish one document type from another. + +Simple example: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + + + + + + + + .. code-block:: yaml + + Documents\Person: + type: document + inheritanceType: SINGLE_COLLECTION + discriminatorField: type + discriminatorMap: + person: Person + employee: Employee + +The discriminator value allows Doctrine to infer the class name to instantiate +when hydrating a document. If a discriminator map is used, the discriminator +value will be used to look up the class name in the map. + +Now, if we query for a Person and its discriminator value is ``employee``, we +would get an Employee instance back: + +.. code-block:: php + + persist($employee); + $dm->flush(); + + $employee = $dm->find('Person', $employee->getId()); // instanceof Employee + +Even though we queried for a Person, Doctrine will know to return an Employee +instance because of the discriminator map! + +If your document structure has changed and you've added discriminators after +already having a bunch of documents, you can specify a default value for the +discriminator field: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + + + + + + + + + .. code-block:: yaml + + Documents\Person: + type: document + inheritanceType: SINGLE_COLLECTION + discriminatorField: type + defaultDiscriminatorValue: person + discriminatorMap: + person: Person + employee: Employee + +.. _collection_per_class_inheritance: + +Collection Per Class Inheritance +-------------------------------- + +With collection per class inheritance, each document is stored in its own +collection and contains all inherited fields: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + + + + .. code-block:: yaml + + Documents\Person: + type: document + inheritanceType: COLLECTION_PER_CLASS + +A discriminator is not needed with this type of inheritance since the data is +separated in different collections. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/introduction.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/introduction.rst.txt new file mode 100644 index 0000000..2d1f295 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/introduction.rst.txt @@ -0,0 +1,494 @@ +Introduction +============ + +Doctrine MongoDB Object Document Mapper is built for PHP 5.3.0+ and +provides transparent persistence for PHP objects to the popular `MongoDB`_ database by `10gen`_. + +Features Overview +----------------- + +- Transparent persistence. +- Map one or many embedded documents. +- Map one or many referenced documents. +- Create references between documents in different databases. +- Map documents with Annotations, XML, YAML or plain old PHP code. +- Documents can be stored on the `MongoGridFS `_. +- Collection per class(concrete) and single collection inheritance supported. +- Map your Doctrine 2 ORM Entities to the ODM and use mixed data stores. +- Inserts are performed using `MongoCollection::batchInsert() `_ +- Updates are performed using atomic operators. + +Here is a quick example of some PHP object documents that demonstrates a few of the features: + +.. code-block:: php + + id; } + + public function getChanges() { return $this->changes; } + public function incrementChanges() { $this->changes++; } + + public function getNotes() { return $this->notes; } + public function addNote($note) { $this->notes[] = $note; } + + public function getName() { return $this->name; } + public function setName($name) { $this->name = $name; } + + public function getSalary() { return $this->salary; } + public function setSalary($salary) { $this->salary = (int) $salary; } + + public function getStarted() { return $this->started; } + public function setStarted(DateTime $started) { $this->started = $started; } + + public function getLeft() { return $this->left; } + public function setLeft(DateTime $left) { $this->left = $left; } + + public function getAddress() { return $this->address; } + public function setAddress(Address $address) { $this->address = $address; } + } + + /** @ODM\Document */ + class Employee extends BaseEmployee + { + /** @ODM\ReferenceOne(targetDocument="Documents\Manager") */ + private $manager; + + public function getManager() { return $this->manager; } + public function setManager(Manager $manager) { $this->manager = $manager; } + } + + /** @ODM\Document */ + class Manager extends BaseEmployee + { + /** @ODM\ReferenceMany(targetDocument="Documents\Project") */ + private $projects; + + public __construct() { $this->projects = new ArrayCollection(); } + + public function getProjects() { return $this->projects; } + public function addProject(Project $project) { $this->projects[] = $project; } + } + + /** @ODM\EmbeddedDocument */ + class Address + { + /** @ODM\Field(type="string") */ + private $address; + + /** @ODM\Field(type="string") */ + private $city; + + /** @ODM\Field(type="string") */ + private $state; + + /** @ODM\Field(type="string") */ + private $zipcode; + + public function getAddress() { return $this->address; } + public function setAddress($address) { $this->address = $address; } + + public function getCity() { return $this->city; } + public function setCity($city) { $this->city = $city; } + + public function getState() { return $this->state; } + public function setState($state) { $this->state = $state; } + + public function getZipcode() { return $this->zipcode; } + public function setZipcode($zipcode) { $this->zipcode = $zipcode; } + } + + /** @ODM\Document */ + class Project + { + /** @ODM\Id */ + private $id; + + /** @ODM\Field(type="string") */ + private $name; + + public function __construct($name) { $this->name = $name; } + + public function getId() { return $this->id; } + + public function getName() { return $this->name; } + public function setName($name) { $this->name = $name; } + } + +Now those objects can be used just like you weren't using any +persistence layer at all and can be persisted transparently by +Doctrine: + +.. code-block:: php + + setName('Employee'); + $employee->setSalary(50000); + $employee->setStarted(new DateTime()); + + $address = new Address(); + $address->setAddress('555 Doctrine Rd.'); + $address->setCity('Nashville'); + $address->setState('TN'); + $address->setZipcode('37209'); + $employee->setAddress($address); + + $project = new Project('New Project'); + $manager = new Manager(); + $manager->setName('Manager'); + $manager->setSalary(100000); + $manager->setStarted(new DateTime()); + $manager->addProject($project); + + $dm->persist($employee); + $dm->persist($address); + $dm->persist($project); + $dm->persist($manager); + $dm->flush(); + +The above would insert the following: + +:: + + Array + ( + [000000004b0a33690000000001c304c6] => Array + ( + [name] => New Project + ) + + ) + Array + ( + [000000004b0a33660000000001c304c6] => Array + ( + [changes] => 0 + [notes] => Array + ( + ) + + [name] => Manager + [salary] => 100000 + [started] => MongoDate Object + ( + [sec] => 1275265048 + [usec] => 0 + ) + + [projects] => Array + ( + [0] => Array + ( + [$ref] => projects + [$id] => 4c0300188ead0e947a000000 + [$db] => my_db + ) + + ) + + ) + + ) + Array + ( + [000000004b0a336a0000000001c304c6] => Array + ( + [changes] => 0 + [notes] => Array + ( + ) + + [name] => Employee + [salary] => 50000 + [started] => MongoDate Object + ( + [sec] => 1275265048 + [usec] => 0 + ) + + [address] => Array + ( + [address] => 555 Doctrine Rd. + [city] => Nashville + [state] => TN + [zipcode] => 37209 + ) + + ) + + ) + +If we update a property and call ``->flush()`` again we'll get an +efficient update query using the atomic operators: + +.. code-block:: php + + setSalary(200000); + $manager->addNote('Gave user 100k a year raise'); + $manager->incrementChanges(2); + $manager->addProject($newProject); + + $dm->persist($newProject); + $dm->flush(); + +The above could would produce an update that looks something like +this: + +:: + + Array + ( + [$inc] => Array + ( + [changes] => 2 + ) + + [$pushAll] => Array + ( + [notes] => Array + ( + [0] => Gave user 100k a year raise + ) + + [projects] => Array + ( + [0] => Array + ( + [$ref] => projects + [$id] => 4c0310718ead0e767e030000 + [$db] => my_db + ) + + ) + + ) + + [$set] => Array + ( + [salary] => 200000 + ) + + ) + +This is a simple example, but it demonstrates well that you can +transparently persist PHP objects while still utilizing the +atomic operators for updating documents! Continue reading to learn +how to get the Doctrine MongoDB Object Document Mapper setup and +running! + +Setup +----- + +Before we can begin, we'll need to install the Doctrine MongoDB ODM library and +its dependencies. The easiest way to do this is with `Composer`_: + +:: + + $ composer require "doctrine/mongodb-odm" + +Once ODM and its dependencies have been downloaded, we can begin by creating a +``bootstrap.php`` file in our project's root directory, where Composer's +``vendor/`` directory also resides. Let's start by importing some of the classes +we'll use: + +.. code-block:: php + + add('Documents', __DIR__); + +Ultimately, our application will utilize ODM through its ``DocumentManager`` +class. Before we can instantiate a ``DocumentManager``, we need to construct the +``Connection`` and ``Configuration`` objects required by its factory method: + +.. code-block:: php + + setProxyDir(__DIR__ . '/Proxies'); + $config->setProxyNamespace('Proxies'); + $config->setHydratorDir(__DIR__ . '/Hydrators'); + $config->setHydratorNamespace('Hydrators'); + $config->setDefaultDB('doctrine_odm'); + +The easiest way to define mappings for our document classes is with annotations. +We'll need to specify an annotation driver in our configuration (with one or +more paths) and register the annotations for the driver: + +.. code-block:: php + + setMetadataDriverImpl(AnnotationDriver::create(__DIR__ . '/Documents')); + + AnnotationDriver::registerAnnotationClasses(); + +At this point, we have everything necessary to construct a ``DocumentManager``: + +.. code-block:: php + + add('Documents', __DIR__); + + $connection = new Connection(); + + $config = new Configuration(); + $config->setProxyDir(__DIR__ . '/Proxies'); + $config->setProxyNamespace('Proxies'); + $config->setHydratorDir(__DIR__ . '/Hydrators'); + $config->setHydratorNamespace('Hydrators'); + $config->setDefaultDB('doctrine_odm'); + $config->setMetadataDriverImpl(AnnotationDriver::create(__DIR__ . '/Documents')); + + AnnotationDriver::registerAnnotationClasses(); + + $dm = DocumentManager::create($connection, $config); + +That is it! Your ``DocumentManager`` instance is ready to be used! + +Using PHP 7 +----------- + +You can use Doctrine MongoDB ODM with PHP 7, but there are a few extra steps during +the installation. Since the legacy driver (referred to as ``ext-mongo``) is not +available on PHP 7, you will need the new driver (``ext-mongodb``) installed and +use a polyfill to provide the API of the legacy driver. + +To do this, you have to require ``alcaeus/mongo-php-adapter`` before adding a composer +dependency to ODM. To do this, run the following command: + +:: + + $ composer require "alcaeus/mongo-php-adapter" + +Next, manually add a ``provide`` section to your ``composer.json``: + +.. code-block:: json + + "provide": { + "ext-mongo": "1.6.14" + } + +This section needs to be added to work around a composer issue with libraries +providing platform packages (such as ``ext-mongo``). Now, you may install ODM as +described above: + +:: + + $ composer require "doctrine/mongodb-odm" + +.. _MongoDB: https://www.mongodb.com/ +.. _10gen: http://www.10gen.com +.. _Composer: http://getcomposer.org/ diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/logging.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/logging.rst.txt new file mode 100644 index 0000000..c150a1b --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/logging.rst.txt @@ -0,0 +1,31 @@ +Logging +======= + +If you want to turn on logging and receive information about +queries made to the database you can do so on your +``Doctrine\ODM\MongoDB\Configuration`` instance: + +.. code-block:: php + + setLoggerCallable(function(array $log) { + print_r($log); + }); + +You can register any PHP callable and it will be notified with a +single argument that is an array of information about the query +being sent to the database. + +Just like the anonymous function above, you could pass an array +with a object instance and a method to call: + +.. code-block:: php + + setLoggerCallable(array($obj, 'method')); \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/map-reduce.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/map-reduce.rst.txt new file mode 100644 index 0000000..a6115f9 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/map-reduce.rst.txt @@ -0,0 +1,117 @@ +Map Reduce +========== + +The Doctrine MongoDB ODM fully supports the `map reduce`_ functionality via its +:doc:`Query Builder API `. + +.. note:: + + From the MongoDB manual: + + Map-reduce is a data processing paradigm for condensing large volumes of + data into useful aggregated results. In MongoDB, map-reduce operations use + custom JavaScript functions to map, or associate, values to a key. If a key + has multiple values mapped to it, the operation reduces the values for the + key to a single object. + +Imagine a situation where you had an application with a document +named ``Event`` and it was related to a ``User`` document: + +.. code-block:: php + + createQueryBuilder('Documents\User') + ->field('type') + ->equals('sale') + ->map('function() { emit(this.user.$id, 1); }') + ->reduce('function(k, vals) { + var sum = 0; + for (var i in vals) { + sum += vals[i]; + } + return sum; + }'); + $query = $qb->getQuery(); + $results = $query->execute(); + + foreach ($results as $user) { + printf("User %s had %d sale(s).\n", $user['_id'], $user['value']); + } + +.. note:: + + The query builder also has a ``finalize()`` method, which may be used to + specify a `finalize function`_ to be executed after the reduce step. + +When using map reduce with Doctrine, the results are not hydrated into objects. +Instead, the raw results are returned directly from MongoDB. + +The preceding example is equivalent to executing the following command via the +PHP driver directly: + +.. code-block:: php + + selectDB('my_db'); + + $map = new MongoCode('function() { emit(this.user.$id, 1); }'); + $reduce = new MongoCode('function(k, vals) { + var sum = 0; + for (var i in vals) { + sum += vals[i]; + } + return sum; + }'); + + $result = $db->command(array( + 'mapreduce' => 'events', + 'map' => $map, + 'reduce' => $reduce, + 'query' => array('type' => 'sale'), + )); + + foreach ($result['results'] as $user) { + printf("User %s had %d sale(s).\n", $user['_id'], $user['value']); + } + +.. _`map reduce`: https://docs.mongodb.com/manual/core/map-reduce/ +.. _`finalize function`: https://docs.mongodb.com/master/reference/command/mapReduce/#mapreduce-finalize-cmd diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/metadata-drivers.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/metadata-drivers.rst.txt new file mode 100644 index 0000000..9723364 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/metadata-drivers.rst.txt @@ -0,0 +1,196 @@ +Metadata Drivers +================ + +The heart of an object mapper is the mapping information +that glues everything together. It instructs the DocumentManager how +it should behave when dealing with the different documents. + +Core Metadata Drivers +--------------------- + +Doctrine provides a few different ways for you to specify your +metadata: + +- **XML files** (XmlDriver) +- **Class DocBlock Annotations** (AnnotationDriver) +- **YAML files** (YamlDriver) +- **PHP Code in files or static functions** (PhpDriver) + +Something important to note about the above drivers is they are all +an intermediate step to the same end result. The mapping +information is populated to ``Doctrine\ODM\MongoDB\Mapping\ClassMetadata`` +instances. So in the end, Doctrine only ever has to work with the +API of the ``ClassMetadata`` class to get mapping information for +a document. + +.. note:: + + The populated ``ClassMetadata`` instances are also cached + so in a production environment the parsing and populating only ever + happens once. You can configure the metadata cache implementation + using the ``setMetadataCacheImpl()`` method on the + ``Doctrine\ODM\MongoDB\Configuration`` class: + + .. code-block:: php + + getConfiguration()->setMetadataCacheImpl(new ApcCache()); + +If you want to use one of the included core metadata drivers you +just need to configure it. All the drivers are in the +``Doctrine\ODM\MongoDB\Mapping\Driver`` namespace: + +.. code-block:: php + + getConfiguration()->setMetadataDriverImpl($driver); + +Implementing Metadata Drivers +----------------------------- + +In addition to the included metadata drivers you can very easily +implement your own. All you need to do is define a class which +implements the ``Driver`` interface: + +.. code-block:: php + + _loadMappingFile($file); + + // populate ClassMetadataInfo instance from $data + } + + /** + * {@inheritdoc} + */ + protected function _loadMappingFile($file) + { + // parse contents of $file and return php data structure + } + } + +.. note:: + + When using the ``AbstractFileDriver`` it requires that you + only have one document defined per file and the file named after the + class described inside where namespace separators are replaced by + periods. So if you have a document named ``Documents\User`` and you + wanted to write a mapping file for your driver above you would need + to name the file ``Documents.User.dcm.ext`` for it to be + recognized. + +Now you can use your ``MyMetadataDriver`` implementation by setting +it with the ``setMetadataDriverImpl()`` method: + +.. code-block:: php + + getConfiguration()->setMetadataDriverImpl($driver); + +ClassMetadata +------------- + +The last piece you need to know and understand about metadata in +Doctrine is the API of the ``ClassMetadata`` classes. You need to +be familiar with them in order to implement your own drivers but +more importantly to retrieve mapping information for a certain +document when needed. + +You have all the methods you need to manually specify the mapping +information instead of using some mapping file to populate it from. +The base ``ClassMetadataInfo`` class is responsible for only data +storage and is not meant for runtime use. It does not require that +the class actually exists yet so it is useful for describing some +document before it exists and using that information to generate for +example the documents themselves. The class ``ClassMetadata`` +extends ``ClassMetadataInfo`` and adds some functionality required +for runtime usage and requires that the PHP class is present and +can be autoloaded. + +You can read more about the API of the ``ClassMetadata`` classes in +the PHP Mapping chapter. + +Getting ClassMetadata Instances +------------------------------- + +If you want to get the ``ClassMetadata`` instance for a document in +your project to programmatically use some mapping information to +generate some HTML or something similar you can retrieve it through +the ``ClassMetadataFactory``: + +.. code-block:: php + + getMetadataFactory(); + $class = $cmf->getMetadataFor('MyDocumentName'); + +Now you can learn about the document and use the data stored in the +``ClassMetadata`` instance to get all mapped fields for example and +iterate over them: + +.. code-block:: php + + fieldMappings as $fieldMapping) { + echo $fieldMapping['fieldName'] . "\n"; + } \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/migrating-schemas.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/migrating-schemas.rst.txt new file mode 100644 index 0000000..17db2e2 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/migrating-schemas.rst.txt @@ -0,0 +1,219 @@ +Migrating Schemas +================= + +Even though MongoDB is schemaless, introducing some kind of object mapper means +that your object definitions become your schema. You may have a situation where +you rename a property in your object model but need to load values from older +documents where the field is still using the former name. While you could use +MongoDB's `$rename`_ operator to migrate everything, sometimes a lazy migration +is preferable. Doctrine offers a few different methods for dealing with this +problem! + +.. note:: + + The features in this chapter were inspired by `Objectify`_, an object mapper + for the Google App Engine datastore. Additional information may be found in + the `Objectify schema migration`_ documentation. + +Renaming a Field +---------------- + +Let's say you have a simple document that starts off with the following fields: + +.. code-block:: php + + firstName, $this->lastName) = explode(' ', $fullName); + } + } + +The annotation is defined with one or a list of field names. During hydration, +these fields will be checked in order and, for each field present, the annotated +method will be invoked with its value as a single argument. Since the +``firstName`` and ``lastName`` fields are mapped, they would then be updated +when the Person was persisted back to MongoDB. + +Unlike lifecycle callbacks, the ``@AlsoLoad`` method annotation does not require +the :ref:`haslifecyclecallbacks` class annotation to be present. + +Moving Fields +------------- + +Migrating your schema can be a difficult task, but Doctrine provides a few +different methods for dealing with it: + +- **@AlsoLoad** - load values from old fields or transform data through methods +- **@NotSaved** - load values into fields without saving them again +- **@PostLoad** - execute code after all fields have been loaded +- **@PrePersist** - execute code before your document gets saved + +Imagine you have some address-related fields on a Person document: + +.. code-block:: php + + street = $street; + $this->city = $city; + } + } + + /** @Document @HasLifecycleCallbacks */ + class Person + { + /** @Id */ + public $id; + + /** @Field(type="string") */ + public $name; + + /** @NotSaved */ + public $street; + + /** @NotSaved */ + public $city; + + /** @EmbedOne(targetDocument="Address") */ + public $address; + + /** @PostLoad */ + public function postLoad() + { + if ($this->street !== null || $this->city !== null) + { + $this->address = new Address($this->street, $this->city); + } + } + } + +Person's ``street`` and ``city`` fields will be hydrated, but not saved. Once +the Person has loaded, the ``postLoad()`` method will be invoked and construct +a new Address object, which is mapped and will be persisted. + +Alternatively, you could defer this migration until the Person is saved: + +.. code-block:: php + + street !== null || $this->city !== null) + { + $this->address = new Address($this->street, $this->city); + } + } + } + +The :ref:`haslifecyclecallbacks` annotation must be present on the class in +which the method is declared for the lifecycle callback to be registered. + +.. _`$rename`: https://docs.mongodb.com/manual/reference/operator/update/rename/ +.. _`Objectify`: https://github.com/objectify/objectify +.. _`Objectify schema migration`: https://github.com/objectify/objectify/wiki/SchemaMigration +.. _`$or`: https://docs.mongodb.com/manual/reference/operator/query/or/ diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/priming-references.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/priming-references.rst.txt new file mode 100644 index 0000000..d2c296b --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/priming-references.rst.txt @@ -0,0 +1,168 @@ +Priming References +================== + +Priming references allows you to consolidate database queries when working with +:ref:`one ` and :ref:`many ` reference mappings. +This is useful for avoiding the +`n+1 problem `_ in your application. + +Query Builder +------------- + +Consider the following abbreviated model: + +.. code-block:: php + + createQueryBuilder('User') + ->limit(100); + $query = $qb->getQuery(); + $users = $query->execute(); + + foreach ($users as $user) { + /* PersistentCollection::initialize() will be invoked when we begin + * iterating through the user's accounts. Any accounts not already + * managed by the unit of work will need to be queried. + */ + foreach ($user->getAccounts() as $account) { + // ... + } + } + +In this example, ODM would query the database once for the result set of users +and then, for each user, issue a separate query to load any accounts that are +not already being managed by the unit of work. This could result in as many as +100 additional database queries! + +If we expect to iterate through all users and their accounts, we could optimize +this process by loading all of the referenced accounts with one query. The query +builder's ``prime()`` method allows us to do just that. + +.. code-block:: php + + createQueryBuilder('User') + ->field('accounts')->prime(true) + ->limit(100); + $query = $qb->getQuery(); + + /* After querying for the users, ODM will collect the IDs of all referenced + * accounts and load them with a single additional query. + */ + $users = $query->execute(); + + foreach ($users as $user) { + /* Accounts have already been loaded, so iterating through accounts will + * not query an additional query. + */ + foreach ($user->getAccounts() as $account) { + + } + } + +In this case, priming will allow us to load all users and referenced accounts in +two database queries. If the accounts had used an +:ref:`inheritance mapping `, priming might require several +queries (one per discriminated class name). + +.. note:: + + Priming is also compatible with :ref:`simple references ` + and discriminated references. When priming discriminated references, ODM + will issue one query per distinct class among the referenced document(s). + +.. note:: + + Hydration must be enabled in the query builder for priming to work properly. + Disabling hydration will cause the DBRef to be returned for a referenced + document instead of the hydrated document object. + +Inverse references +------------------ + +.. note:: + + This feature was added in version 1.2. + +When using inverse references (references mapped using ``mappedBy`` or +``repositoryMethod``) you can also enable primers on one-to-many references by +specifying them in the mapping: + +.. code-block:: php + + createQueryBuilder($class->name) + ->field($class->identifier)->in($ids); + + if ( ! empty($hints[Query::HINT_SLAVE_OKAY])) { + $qb->slaveOkay(true); + } + + if ( ! empty($hints[Query::HINT_READ_PREFERENCE])) { + $qb->setReadPreference( + $hints[Query::HINT_READ_PREFERENCE], + $hints[Query::HINT_READ_PREFERENCE_TAGS] + ); + } + + $qb->getQuery()->toArray(); + }; + +Firstly, the callable is passed the ``DocumentManager`` of the main query. This +is necessary to create the query used for priming, and ensures that the results +will become managed in the same scope. The ``ClassMetadata`` argument provides +mapping information for the referenced class as well as its name, which is used +to create the query builder. An array of identifiers follows, which is used to +query for the documents to be primed. Lastly, the ``UnitOfWork`` hints from the +original query are provided so that the priming query can apply them as well. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/query-builder-api.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/query-builder-api.rst.txt new file mode 100644 index 0000000..71518cb --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/query-builder-api.rst.txt @@ -0,0 +1,998 @@ +Query Builder API +================= + +.. role:: math(raw) + :format: html latex + +Querying for documents with Doctrine is just as simple as if you +weren't using Doctrine at all. Of course you always have your +traditional ``find()`` and ``findOne()`` methods but you also have +a ``Query`` object with a fluent API for defining the query that +should be executed. + +The ``Query`` object supports several types of queries + +- FIND +- FIND_AND_UPDATE +- FIND_AND_REMOVE +- INSERT +- UPDATE +- REMOVE +- GROUP +- MAP_REDUCE +- DISTINCT_FIELD +- GEO_LOCATION + +This section will show examples for the different types of queries. + +Finding Documents +----------------- + +You have a few different ways to find documents. You can use the ``find()`` method +to find a document by its identifier: + +.. code-block:: php + + find('User', $id); + +The ``find()`` method is just a convenience shortcut method to: + +.. code-block:: php + + getRepository('User')->find($id); + +.. note:: + + The ``find()`` method checks the local in memory identity map for the document + before querying the database for the document. + +On the ``DocumentRepository`` you have a few other methods for finding documents: + +- ``findBy`` - find documents by an array of criteria +- ``findOneBy`` - find one document by an array of criteria + +.. code-block:: php + + getRepository('User')->findBy(array('type' => 'employee')); + $user = $dm->getRepository('User')->findOneBy(array('username' => 'jwage')); + +Creating a Query Builder +------------------------ + +You can easily create a new ``Query\Builder`` object with the +``DocumentManager::createQueryBuilder()`` method: + +.. code-block:: php + + createQueryBuilder('User'); + +The first and only argument is optional, you can specify it later +with the ``find()``, ``update()`` (deprecated), ``updateOne()``, +``updateMany()`` or ``remove()`` method: + +.. code-block:: php + + createQueryBuilder(); + + // ... + + $qb->find('User'); + +Executing Queries +~~~~~~~~~~~~~~~~~ + +You can execute a query by getting a ``Query`` through the ``getQuery()`` method: + +.. code-block:: php + + createQueryBuilder('User'); + $query = $qb->getQuery(); + +Now you can ``execute()`` that query and it will return a cursor for you to iterate over the results: + +.. code-block:: php + + execute(); + +Debugging Queries +~~~~~~~~~~~~~~~~~ + +While building not complicated queries is really simple sometimes it might be hard to wrap your head +around more sophisticated queries that involves building separate expressions to work properly. If +you are not sure if your the query constructed with Builder is in fact correct you may want to ``debug()`` it + +.. code-block:: php + + createQueryBuilder('User'); + $query = $qb->getQuery(); + $debug = $query->debug(); + +At this point your query is *prepared* - that means ODM done all its job in renaming fields to match their +database name, added discriminator fields, applied filters, created correct references and all other things +you employ ODM to. The array returned by ``->debug()`` is what is passed to the underlying driver for the +query to be performed. + +Eager Cursors +~~~~~~~~~~~~~ + +You can configure queries to return an eager cursor instead of a normal mongodb cursor using the ``Builder#eagerCursor()`` method: + +.. code-block:: php + + createQueryBuilder('User') + ->eagerCursor(true); + $query = $qb->getQuery(); + $cursor = $query->execute(); // instanceof Doctrine\ODM\MongoDB\EagerCursor + +Iterating over the ``$cursor`` will fetch all the data in a short and small cursor all at once and will hydrate +one document at a time in to an object as you iterate: + +.. code-block:: php + + createQueryBuilder('User') + ->field('username')->equals('jwage') + ->getQuery() + ->getSingleResult(); + +Selecting Fields +~~~~~~~~~~~~~~~~ + +You can limit the fields that are returned in the results by using +the ``select()`` method: + +.. code-block:: php + + createQueryBuilder('User') + ->select('username', 'password'); + $query = $qb->getQuery(); + $users = $query->execute(); + +In the results only the data from the username and password will be +returned. + +Index hints +~~~~~~~~~~~ + +You can force MongoDB to use a specific index for a query with the ``hint()`` method (see `hint `_) + +.. code-block:: php + + createQueryBuilder('User') + ->hint('user_pass_idx'); + $query = $qb->getQuery(); + $users = $query->execute(); + +.. note:: + + Combining ``select()`` and ``hint()`` on appropriate indexes can result in very fast + `covered queries `_ + +Selecting Distinct Values +~~~~~~~~~~~~~~~~~~~~~~~~~ + +Sometimes you may want to get an array of distinct values in a +collection. You can accomplish this using the ``distinct()`` +method: + +.. code-block:: php + + createQueryBuilder('User') + ->distinct('age') + ->getQuery() + ->execute(); + +The above would give you an ``ArrayCollection`` of all the distinct user ages! + +.. note:: + + MongoDB's `distinct command `_ + does not support sorting, so you cannot combine ``distinct()`` with + ``sort()``. If you would like to sort the results of a distinct query, you + will need to do so in PHP after executing the query. + +Refreshing Documents +~~~~~~~~~~~~~~~~~~~~ + +When a query (e.g. geoNear, find) returns one or more hydrated documents whose +identifiers are already in the identity map, ODM returns the managed document +instances for those results. In this case, a managed document's data may differ +from whatever was just returned by the database query. + +The query builder's ``refresh()`` method may be used to instruct ODM to override +the managed document with data from the query result. This is comparable to +calling ``DocumentManager::refresh()`` for a managed document. The document's +changeset will be reset in the process. + +.. code-block:: php + + createQueryBuilder('User') + ->field('username')->equals('jwage') + ->refresh() + ->getQuery() + ->getSingleResult(); + + // Jon's user will have the latest data, even if it was already managed + +Refreshing is not applicable if hydration is disabled. + +Fetching Documents as Read-Only +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Similar to ``refresh()``, ``readOnly()`` instructs ODM to not only hydrate the +latest data but also to create new document's instance (i.e. if found document +would be already managed by Doctrine, new instance will be returned) and not +register it in ``UnitOfWork``. + +This technique can prove especially useful when using ``select()`` with no intent +to update fetched documents. + +.. code-block:: php + + createQueryBuilder('User') + ->field('username')->equals('malarzm') + ->readOnly() + ->getQuery() + ->getSingleResult(); + + // Maciej's user will have the latest data, and will not be the same object + // as the one that was already managed (if it was) + +Read-Only is not applicable if hydration is disabled. + +.. note:: + + Read-only mode is not deep, i.e. any references (be it owning or inverse) of + fetched WILL be managed by Doctrine. This is a shortcoming of current + implementation, may change in future and will not be considered a BC break + (will be treated as a feature instead). + +.. note:: + + To manage a document previously fetched in read-only mode, always use the + `merge` method of the DocumentManager. Using `persist` in these cases can + have unwanted side effects. + +Disabling Hydration +~~~~~~~~~~~~~~~~~~~ + +For find queries the results by default are hydrated and you get +document objects back instead of arrays. You can disable this and +get the raw results directly back from mongo by using the +``hydrate(false)`` method: + +.. code-block:: php + + createQueryBuilder('User') + ->hydrate(false) + ->getQuery() + ->execute(); + + print_r($users); + +Limiting Results +~~~~~~~~~~~~~~~~ + +You can limit results similar to how you would in a relational +database with a limit and offset by using the ``limit()`` and +``skip()`` method. + +Here is an example where we get the third page of blog posts when +we show twenty at a time: + +.. code-block:: php + + createQueryBuilder('BlogPost') + ->limit(20) + ->skip(40) + ->getQuery() + ->execute(); + +Sorting Results +~~~~~~~~~~~~~~~ + +You can sort the results by using the ``sort()`` method: + +.. code-block:: php + + createQueryBuilder('Article') + ->sort('createdAt', 'desc'); + +If you want to an additional sort you can call ``sort()`` again. The calls are stacked and ordered +in the order you call the method: + +.. code-block:: php + + sort('featured', 'desc'); + +Map Reduce +~~~~~~~~~~ + +You can also run map reduced find queries using the ``Query`` +object: + +.. code-block:: php + + dm->createQueryBuilder('Event') + ->field('type')->equals('sale') + ->map('function() { emit(this.userId, 1); }') + ->reduce("function(k, vals) { + var sum = 0; + for (var i in vals) { + sum += vals[i]; + } + return sum; + }"); + $query = $qb->getQuery(); + $results = $query->execute(); + +.. note:: + + When you specify a ``map()`` and ``reduce()`` operation + the results will not be hydrated and the raw results from the map + reduce operation will be returned. + +If you just want to reduce the results using a javascript function +you can just call the ``where()`` method: + +.. code-block:: php + + createQueryBuilder('User') + ->where("function() { return this.type == 'admin'; }"); + +You can read more about the `$where operator `_ in the Mongo docs. + +Conditional Operators +~~~~~~~~~~~~~~~~~~~~~ + +The conditional operators in Mongo are available to limit the returned results through a easy to use API. Doctrine abstracts this to a fluent object oriented interface with a fluent API. Here is a list of all the conditional operation methods you can use on the `Query\Builder` object. + +* ``where($javascript)`` +* ``in($values)`` +* ``notIn($values)`` +* ``equals($value)`` +* ``notEqual($value)`` +* ``gt($value)`` +* ``gte($value)`` +* ``lt($value)`` +* ``lte($value)`` +* ``range($start, $end)`` +* ``size($size)`` +* ``exists($bool)`` +* ``type($type)`` +* ``all($values)`` +* ``mod($mod)`` +* ``addOr($expr)`` +* ``references($document)`` +* ``includesReferenceTo($document)`` + +Query for active administrator users: + +.. code-block:: php + + createQueryBuilder('User') + ->field('type')->equals('admin') + ->field('active')->equals(true); + +Query for articles that have some tags: + +.. code-block:: php + + createQueryBuilder('Article') + ->field('tags.name')->in(array('tag1', 'tag2')); + +Read more about the +`$in operator `_ +in the Mongo docs + +Query for articles that do not have some tags: + +.. code-block:: php + + createQueryBuilder('Article') + ->field('tags.name')->notIn(array('tag3')); + +Read more about the +`$nin operator `_ +in the Mongo docs. + +.. code-block:: php + + createQueryBuilder('User') + ->field('type')->notEqual('admin'); + +Read more about the +`$ne operator `_ +in the Mongo docs. + +Query for accounts with an amount due greater than 30: + +.. code-block:: php + + createQueryBuilder('Account') + ->field('amount_due')->gt(30); + +Query for accounts with an amount due greater than or equal to 30: + +.. code-block:: php + + createQueryBuilder('Account') + ->field('amount_due')->gte(30); + +Query for accounts with an amount due less than 30: + +.. code-block:: php + + createQueryBuilder('Account') + ->field('amount_due')->lt(30); + +Query for accounts with an amount due less than or equal to 30: + +.. code-block:: php + + createQueryBuilder('Account') + ->field('amount_due')->lte(30); + +Query for accounts with an amount due between 10 and 20: + +.. code-block:: php + + createQueryBuilder('Account') + ->field('amount_due')->range(10, 20); + +Read more about +`conditional operators `_ +in the Mongo docs. + +Query for articles with no comments: + +.. code-block:: php + + createQueryBuilder('Article') + ->field('comments')->size(0); + +Read more about the +`$size operator `_ +in the Mongo docs. + +Query for users that have a login field before it was renamed to +username: + +.. code-block:: php + + createQueryBuilder('User') + ->field('login')->exists(true); + +Read more about the +`$exists operator `_ +in the Mongo docs. + +Query for users that have a type field that is of integer bson +type: + +.. code-block:: php + + createQueryBuilder('User') + ->field('type')->type('integer'); + +Read more about the +`$type operator `_ +in the Mongo docs. + +Query for users that are in all the specified Groups: + +.. code-block:: php + + createQueryBuilder('User') + ->field('groups')->all(array('Group 1', 'Group 2')); + +Read more about the +`$all operator `_ +in the Mongo docs. + +.. code-block:: php + + createQueryBuilder('Transaction') + ->field('field')->mod('field', array(10, 1)); + +Read more about the +`$mod operator `_ in the Mongo docs. + +Query for users who have subscribed or are in a trial. + +.. code-block:: php + + createQueryBuilder('User'); + $qb->addOr($qb->expr()->field('subscriber')->equals(true)); + $qb->addOr($qb->expr()->field('inTrial')->equals(true)); + +Read more about the +`$or operator `_ in the Mongo docs. + +The ``references()`` method may be used to query the owning side of a +:ref:`@ReferenceOne ` relationship. In the +following example, we query for all articles written by a particular user. + +.. code-block:: php + + createQueryBuilder('Article') + ->field('user')->references($user); + +The ``includesReferenceTo()`` method may be used to query the owning side of a +:ref:`@ReferenceMany ` relationship. In +the following example, we query for the user(s) that have access to a particular +account. + +.. code-block:: php + + createQueryBuilder('User') + ->field('accounts')->includesReferenceTo($account); + +Text Search +~~~~~~~~~~~ + +You can use the +`$text operator `_ +to run a text search against a field with a text index. To do so, create a +document with a text index: + +.. code-block:: php + + createQueryBuilder('Document') + ->text('words you are looking for'); + +To fetch the calculated score for the text search, use the ``selectMeta()`` +method: + +.. code-block:: php + + createQueryBuilder('Document') + ->selectMeta('score', 'textScore') + ->text('words you are looking for'); + +You can also change the language used for stemming using the ``language()`` +method: + +.. code-block:: php + + createQueryBuilder('Document') + ->language('it') + ->text('parole che stai cercando'); + + +Update Queries +~~~~~~~~~~~~~~ + +Doctrine also supports executing atomic update queries using the `Query\Builder` +object. You can use the conditional operations in combination with the ability to +change document field values atomically. Additionally if you are modifying a field +that is a reference you can pass managed document to the Builder and let ODM build +``DBRef`` object for you. + +You have several modifier operations +available to you that make it easy to update documents in Mongo: + +* ``set($name, $value, $atomic = true)`` +* ``setNewObj($newObj)`` +* ``inc($name, $value)`` +* ``unsetField($field)`` +* ``push($field, $value)`` +* ``pushAll($field, array $valueArray)`` +* ``addToSet($field, $value)`` +* ``addManyToSet($field, array $values)`` +* ``popFirst($field)`` +* ``popLast($field)`` +* ``pull($field, $value)`` +* ``pullAll($field, array $valueArray)`` + +Updating multiple documents +--------------------------- + +By default Mongo updates only one document unless ``multi`` option is provided and true. +In ODM the distinction is done by explicitly calling ``updateMany()`` method of the builder: + +.. code-block:: php + + createQueryBuilder('User') + ->updateMany() + ->field('someField')->set('newValue') + ->field('username')->equals('sgoettschkes') + ->getQuery() + ->execute(); + +.. note:: + ``updateMany()`` and ``updateOne()`` methods were introduced in version 1.2. If you're + using one of previous version you need to use ``update()`` combined with ``multiple(true)``. + +Modifier Operations +------------------- + +Change a users password: + +.. code-block:: php + + createQueryBuilder('User') + ->updateOne() + ->field('password')->set('newpassword') + ->field('username')->equals('jwage') + ->getQuery() + ->execute(); + +If you want to just set the values of an entirely new object you +can do so by passing false as the third argument of ``set()`` to +tell it the update is not an atomic one: + +.. code-block:: php + + createQueryBuilder('User') + ->updateOne() + ->field('username')->set('jwage', false) + ->field('password')->set('password', false) + // ... set other remaining fields + ->field('username')->equals('jwage') + ->getQuery() + ->execute(); + +Read more about the +`$set modifier `_ +in the Mongo docs. + +You can set an entirely new object to update as well: + +.. code-block:: php + + createQueryBuilder('User') + ->setNewObj(array( + 'username' => 'jwage', + 'password' => 'password', + // ... other fields + )) + ->field('username')->equals('jwage') + ->getQuery() + ->execute(); + +Increment the value of a document: + +.. code-block:: php + + createQueryBuilder('Package') + ->field('id')->equals('theid') + ->field('downloads')->inc(1) + ->getQuery() + ->execute(); + +Read more about the +`$inc modifier `_ +in the Mongo docs. + +Unset the login field from users where the login field still +exists: + +.. code-block:: php + + createQueryBuilder('User') + ->updateMany() + ->field('login')->unsetField()->exists(true) + ->getQuery() + ->execute(); + +Read more about the +`$unset modifier `_ +in the Mongo docs. + +Append new tag to the tags array: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->push('tag5') + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Read more about the +`$push modifier `_ +in the Mongo docs. + +Append new tags to the tags array: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->pushAll(array('tag6', 'tag7')) + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Read more about the +`$pushAll modifier `_ +in the Mongo docs. + +Add value to array only if its not in the array already: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->addToSet('tag1') + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Read more about the +`$addToSet modifier `_ +in the Mongo docs. + +Add many values to the array only if they do not exist in the array +already: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->addManyToSet(array('tag6', 'tag7')) + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Read more about the +`$addManyToSet modifier `_ +in the Mongo docs. + +Remove first element in an array: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->popFirst() + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Remove last element in an array: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateOne() + ->field('tags')->popLast() + ->field('id')->equals('theid') + ->getQuery() + ->execute(); + +Read more about the +`$pop modifier `_ +in the Mongo docs. + +Remove all occurrences of value from array: + +.. code-block:: php + + createQueryBuilder('Article') + ->updateMany() + ->field('tags')->pull('tag1') + ->getQuery() + ->execute(); + +Read more about the +`$pull modifier `_ +in the Mongo docs. + +.. code-block:: php + + createQueryBuilder('Article') + ->updateMany() + ->field('tags')->pullAll(array('tag1', 'tag2')) + ->getQuery() + ->execute(); + +Read more about the +`$pullAll modifier `_ +in the Mongo docs. + +Remove Queries +-------------- + +In addition to updating you can also issue queries to remove +documents from a collection. It works pretty much the same way as +everything else and you can use the conditional operations to +specify which documents you want to remove. + +Here is an example where we remove users who have never logged in: + +.. code-block:: php + + createQueryBuilder('User') + ->remove() + ->field('num_logins')->equals(0) + ->getQuery() + ->execute(); + +Group Queries +------------- + +.. note:: + + Due to deprecation of ``group`` command in MongoDB 3.4 the ODM + also deprecates its usage through Query Builder in 1.2. Please + use :ref:`$group stage ` of the + Aggregation Builder instead. + +The last type of supported query is a group query. It performs an +operation similar to SQL's GROUP BY command. + +.. code-block:: php + + dm->createQueryBuilder('Documents\User') + ->group(array(), array('count' => 0)) + ->reduce('function (obj, prev) { prev.count++; }') + ->field('a')->gt(1) + ->getQuery() + ->execute(); + +This is the same as if we were to do the group with the raw PHP +code: + +.. code-block:: php + + array( '$gt' => 1)); + $result = $collection->group(array(), array('count' => 0), $reduce, $condition); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/reference-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/reference-mapping.rst.txt new file mode 100644 index 0000000..6280ef6 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/reference-mapping.rst.txt @@ -0,0 +1,495 @@ +Reference Mapping +================= + +This chapter explains how references between documents are mapped with Doctrine. + +Collections +----------- + +Examples of many-valued references in this manual make use of a ``Collection`` +interface and a corresponding ``ArrayCollection`` implementation, which are +defined in the ``Doctrine\Common\Collections`` namespace. These classes have no +dependencies on ODM, and can therefore be used within your domain model and +elsewhere without introducing coupling to the persistence layer. + +ODM also provides a ``PersistentCollection`` implementation of ``Collection``, +which incorporates change-tracking functionality; however, this class is +constructed internally during hydration. As a developer, you should develop with +the ``Collection`` interface in mind so that your code can operate with any +implementation. + +.. note:: + + New in 1.1: you are no longer limited to using ``ArrayCollection`` and can + freely use your own ``Collection`` implementation. For more details please + see :doc:`Custom Collections ` chapter. + +Why are these classes used over PHP arrays? Native arrays cannot be +transparently extended in PHP, which is necessary for many advanced features +provided by the ODM. Although PHP does provide various interfaces that allow +objects to operate like arrays (e.g. ``Traversable``, ``Countable``, +``ArrayAccess``), and even a concrete implementation in ``ArrayObject``, these +objects cannot always be used everywhere that a native array is accepted. +Doctrine's ``Collection`` interface and ``ArrayCollection`` implementation are +conceptually very similar to ``ArrayObject``, with some slight differences and +improvements. + +.. _reference_one: + +Reference One +------------- + +Reference one document: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + Product: + type: document + referenceOne: + shipping: + targetDocument: Documents\Shipping + +.. _reference_many: + +Reference Many +-------------- + +Reference many documents: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + User: + type: document + referenceMany: + accounts: + targetDocument: Documents\Account + +.. _reference_mixing_document_types: + +Mixing Document Types +--------------------- + +If you want to store different types of documents in references, you can simply +omit the ``targetDocument`` option: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + referenceMany: + favorites: ~ + +Now the ``$favorites`` property can store a reference to any type of document! +The class name will be automatically stored in a field named +``_doctrine_class_name`` within the `DBRef`_ object. + +.. note:: + + The MongoDB shell tends to ignore fields other than ``$id`` and ``$ref`` + when displaying `DBRef`_ objects. You can verify the presence of any ``$db`` + and discriminator fields by querying and examining the document with a + driver. See `SERVER-10777 `_ + for additional discussion on this issue. + +The name of the field within the DBRef object can be customized via the +``discriminatorField`` option: + +.. configuration-block:: + + .. code-block:: php + + + + + + .. code-block:: yaml + + referenceMany: + favorites: + discriminatorField: type + +You can also specify a discriminator map to avoid storing the |FQCN| +in each `DBRef`_ object: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + .. code-block:: yaml + + referenceMany: + favorites: + discriminatorMap: + album: Documents\Album + song: Documents\Song + +If you have references without a discriminator value that should be considered +a certain class, you can optionally specify a default discriminator value: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + .. code-block:: yaml + + referenceMany: + favorites: + discriminatorMap: + album: Documents\Album + song: Documents\Song + defaultDiscriminatorValue: album + +.. _storing_references: + +Storing References +------------------ + +By default all references are stored as a `DBRef`_ object with the traditional +``$ref``, ``$id``, and (optionally) ``$db`` fields (in that order). For references to +documents of a single collection, storing the collection (and database) names for +each reference may be redundant. You can use simple references to store the +referenced document's identifier (e.g. ``MongoId``) instead of a `DBRef`_. + +Example: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + referenceOne: + profile: + storeAs: id + +Now, the ``profile`` field will only store the ``MongoId`` of the referenced +Profile document. + +Simple references reduce the amount of storage used, both for the document +itself and any indexes on the reference field; however, simple references cannot +be used with discriminators, since there is no `DBRef`_ object in which to store +a discriminator value. + +In addition to saving references as `DBRef`_ with ``$ref``, ``$id``, and ``$db`` +fields and as ``MongoId``, it is possible to save references as `DBRef`_ without +the ``$db`` field. This solves problems when the database name changes (and also +reduces the amount of storage used). + +The ``storeAs`` option has the following possible values: + +- **dbRefWithDb**: Uses a `DBRef`_ with ``$ref``, ``$id``, and ``$db`` fields (this is the default) +- **dbRef**: Uses a `DBRef`_ with ``$ref`` and ``$id`` +- **ref**: Uses a custom embedded object with an ``id`` field +- **id**: Uses the identifier of the referenced object + +.. note:: + + The ``storeAs=id`` option used to be called a "simple reference". The old syntax is + still recognized (so using ``simple=true`` will imply ``storeAs=id``). + +.. note:: + + For backwards compatibility ``storeAs=dbRefWithDb`` is the default, but +    ``storeAs=ref`` is the recommended setting. + + +Cascading Operations +-------------------- + +By default, Doctrine will not cascade any ``UnitOfWork`` operations to +referenced documents. You must explicitly enable this functionality: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + .. code-block:: yaml + + referenceOne: + profile: + cascade: [persist] + +The valid values are: + +- **all** - cascade all operations by default. +- **detach** - cascade detach operation to referenced documents. +- **merge** - cascade merge operation to referenced documents. +- **refresh** - cascade refresh operation to referenced documents. +- **remove** - cascade remove operation to referenced documents. +- **persist** - cascade persist operation to referenced documents. + +Orphan Removal +-------------- + +There is another concept of cascading that is relevant only when removing documents +from collections. If a Document of type ``A`` contains references to privately +owned Documents ``B`` then if the reference from ``A`` to ``B`` is removed the +document ``B`` should also be removed, because it is not used anymore. + +OrphanRemoval works with both reference one and many mapped fields. + +.. note:: + + When using the ``orphanRemoval=true`` option Doctrine makes the assumption + that the documents are privately owned and will **NOT** be reused by other documents. + If you neglect this assumption your documents will get deleted by Doctrine even if + you assigned the orphaned documents to another one. + +As a better example consider an Addressbook application where you have Contacts, Addresses +and StandingData: + +.. code-block:: php + + addresses = new ArrayCollection(); + } + + public function newStandingData(StandingData $sd) + { + $this->standingData = $sd; + } + + public function removeAddress($pos) + { + unset($this->addresses[$pos]); + } + } + +Now two examples of what happens when you remove the references: + +.. code-block:: php + + find("Addressbook\Contact", $contactId); + $contact->newStandingData(new StandingData("Firstname", "Lastname", "Street")); + $contact->removeAddress(1); + + $dm->flush(); + +In this case you have not only changed the ``Contact`` document itself but +you have also removed the references for standing data and as well as one +address reference. When flush is called not only are the references removed +but both the old standing data and the one address documents are also deleted +from the database. + +.. _`DBRef`: https://docs.mongodb.com/manual/reference/database-references/#dbrefs +.. |FQCN| raw:: html + FQCN diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/sharding.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/sharding.rst.txt new file mode 100644 index 0000000..8e95007 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/sharding.rst.txt @@ -0,0 +1,69 @@ +.. _sharding: + +Sharding +======== + +MongoDB allows you to horizontally scale your database. In order to enable this, +Doctrine MongoDB ODM needs to know about your sharding setup. For basic information +about sharding, please refer to the `MongoDB docs `_. + +Once you have a `sharded cluster `_, +you can enable sharding for a document. You can do this by defining a shard key in +the document: + +.. configuration-block:: + + .. code-block:: php + + + + + + + + + + + .. code-block:: yaml + + Documents\User: + shardKey: + keys: + username: asc + +.. note:: + When a shard key is defined for a document, Doctrine MongoDB ODM will no + longer persist changes to the shard key as these fields become immutable in + a sharded setup. + +Once you've defined a shard key you need to enable sharding for the collection +where the document will be stored. To do this, use the ``odm:schema:shard`` +command. + +.. note:: + + For performance reasons, sharding is not enabled during the + ``odm:schema:create`` and ``odm:schema:update`` commmands. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/slave-okay-queries.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/slave-okay-queries.rst.txt new file mode 100644 index 0000000..8623dbf --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/slave-okay-queries.rst.txt @@ -0,0 +1,71 @@ +Slave Okay Queries +================== + +.. note:: + + ``slaveOkay`` was deprecated in 1.2 - please use `Read Preference `_ + instead. + +Documents +~~~~~~~~~ + +You can configure an entire document to send all reads to the slaves by using the ``slaveOkay`` flag: + +.. code-block:: php + + createQueryBuilder('User') + ->slaveOkay(true); + $query = $qb->getQuery(); + $users = $query->execute(); + +The data in the query above will be read from a slave. Even if you have a ``@ReferenceOne`` or +``@ReferenceMany`` resulting from the query above it will be initialized and loaded from a slave. + +.. code-block:: php + + createQueryBuilder('User') + ->slaveOkay(true); + $query = $qb->getQuery(); + $users = $query->execute(); + + foreach ($users as $user) { + foreach ($user->getAccounts() as $account) { + echo $account->getName(); + } + } diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/storage-strategies.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/storage-strategies.rst.txt new file mode 100644 index 0000000..53ed07d --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/storage-strategies.rst.txt @@ -0,0 +1,97 @@ +.. _storage_strategies: + +Storage Strategies +================== + +Doctrine MongoDB ODM implements several different strategies for persisting changes +to mapped fields. These strategies apply to the following mapping types: + +- :ref:`int` +- :ref:`float` +- :ref:`embed_many` +- :ref:`reference_many` + +For collections, Doctrine tracks changes via the PersistentCollection class. The +strategies described on this page are implemented by the CollectionPersister +class. The ``increment`` strategy cannot be used for collections. + +increment +--------- + +The ``increment`` strategy does not apply to collections but can be used for +``int`` and ``float`` fields. When using the ``increment`` strategy, the field +value will be updated using the `$inc`_ operator. + +addToSet +-------- + +The ``addToSet`` strategy uses MongoDB's `$addToSet`_ operator to insert +elements into the array. This strategy is useful for ensuring that duplicate +values will not be inserted into the collection. Like the `pushAll`_ strategy, +elements are inserted in a separate query after removing deleted elements. + +set +--- + +The ``set`` strategy uses MongoDB's `$set`_ operator to update the entire +collection with a single update query. + +.. note:: + + Doctrine's Collection interface is modeled after PHP's associative arrays, + so they cannot always be represented as a BSON array. If the collection's + keys are not sequential integers starting with zero, the ``set`` strategy + will store the collection as a BSON object instead of an array. Use the + `setArray`_ strategy if you want to ensure that the collection is always + stored as a BSON array. + +setArray +-------- + +The ``setArray`` strategy uses MongoDB's `$set`_ operator, just like the ``set`` +strategy, but will first numerically reindex the collection to ensure that it is +stored as a BSON array. + +pushAll +------- + +The ``pushAll`` strategy uses MongoDB's `$pushAll`_ operator to insert +elements into the array. MongoDB does not allow elements to be added and removed +from an array in a single operation, so this strategy relies on multiple update +queries to remove and insert elements (in that order). + +.. _atomic_set: + +atomicSet +--------- + +The ``atomicSet`` strategy uses MongoDB's `$set`_ operator to update the entire +collection with a single update query. Unlike with ``set`` strategy there will +be only one query for updating both parent document and collection itself. This +strategy can be especially useful when dealing with high concurrency and +:ref:`versioned documents `. + +.. note:: + + The ``atomicSet`` and ``atomicSetArray`` strategies may only be used for + collections mapped directly in a top-level document. + +.. _atomic_set_array: + +atomicSetArray +-------------- + +The ``atomicSetArray`` strategy works exactly like ``atomicSet`` strategy, but +will first numerically reindex the collection to ensure that it is stored as a +BSON array. + +.. note:: + + The ``atomicSet`` and ``atomicSetArray`` strategies may only be used for + collections mapped directly in a top-level document. + +.. _`$addToSet`: https://docs.mongodb.com/manual/reference/operator/update/addToSet/ +.. _`$inc`: https://docs.mongodb.com/manual/reference/operator/update/inc/ +.. _`$pushAll`: https://docs.mongodb.com/manual/reference/operator/update/pushAll/ +.. _`$set`: https://docs.mongodb.com/manual/reference/operator/update/set/ +.. _`$unset`: https://docs.mongodb.com/manual/reference/operator/update/unset/ diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/storing-files-with-mongogridfs.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/storing-files-with-mongogridfs.rst.txt new file mode 100644 index 0000000..18582b7 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/storing-files-with-mongogridfs.rst.txt @@ -0,0 +1,190 @@ +Storing Files with MongoGridFS +============================== + +The PHP Mongo extension provides a nice and convenient way to store +files in chunks of data with the +`MongoGridFS `_. + +It uses two database collections, one to store the metadata for the +file, and another to store the contents of the file. The contents +are stored in chunks to avoid going over the maximum allowed size +of a MongoDB document. + +You can easily setup a Document that is stored using the +MongoGridFS: + +.. code-block:: php + + id; + } + + public function setName($name) + { + $this->name = $name; + } + + public function getName() + { + return $this->name; + } + + public function getFile() + { + return $this->file; + } + + public function setFile($file) + { + $this->file = $file; + } + } + +Notice how we annotated the $file property with @File. This is what +tells the Document that it is to be stored using the MongoGridFS +and the MongoGridFSFile instance is placed in the $file property +for you to access the actual file itself. + +The $uploadDate, $chunkSize and $md5 properties are automatically filled in +for each file stored in GridFS (whether you like that or not). +Feel free to create getters in your document to actually make use of them, +but keep in mind that their values will be initially unset for new objects +until the next time the document is hydrated (fetched from the database). + +First you need to create a new Image: + +.. code-block:: php + + setName('Test image'); + $image->setFile('/path/to/image.png'); + + $dm->persist($image); + $dm->flush(); + +Now you can later query for the Image and render it: + +.. code-block:: php + + createQueryBuilder('Documents\Image') + ->field('name')->equals('Test image') + ->getQuery() + ->getSingleResult(); + + header('Content-type: image/png;'); + echo $image->getFile()->getBytes(); + +You can of course make references to this Image document from +another document. Imagine you had a Profile document and you wanted +every Profile to have a profile image: + +.. code-block:: php + + id; + } + + public function getName() + { + return $this->name; + } + + public function setName($name) + { + $this->name = $name; + } + + public function getImage() + { + return $this->image; + } + + public function setImage(Image $image) + { + $this->image = $image; + } + } + +Now you can create a new Profile and give it an Image: + +.. code-block:: php + + setName('Test image'); + $image->setFile('/path/to/image.png'); + + $profile = new Profile(); + $profile->setName('Jonathan H. Wage'); + $profile->setImage($image); + + $dm->persist($profile); + $dm->flush(); + +If you want to query for the Profile and load the Image reference +in a query you can use: + +.. code-block:: php + + createQueryBuilder('Profile') + ->field('name')->equals('Jonathan H. Wage') + ->getQuery() + ->getSingleResult(); + + $image = $profile->getImage(); + + header('Content-type: image/png;'); + echo $image->getFile()->getBytes(); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/transactions-and-concurrency.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/transactions-and-concurrency.rst.txt new file mode 100644 index 0000000..afa8eed --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/transactions-and-concurrency.rst.txt @@ -0,0 +1,306 @@ +.. Heavily inspired by Doctrine 2 ORM documentation + +Transactions and Concurrency +============================ + +Transactions +------------ + +As per the `documentation `_, MongoDB +write operations are "atomic on the level of a single document". + +Even when updating multiple documents within a single write operation, +though the modification of each document is atomic, +the operation as a whole is not and other operations may interleave. + +As stated in the `FAQ `_, +"MongoDB does not support multi-document transactions" and neither does Doctrine MongoDB ODM. + +Limitation +~~~~~~~~~~ +At the moment, Doctrine MongoDB ODM does not provide any native strategy to emulate multi-document transactions. + +Workaround +~~~~~~~~~~ +To work around this limitation, one can utilize `two phase commits `_. + +Concurrency +----------- + +Doctrine MongoDB ODM offers native support for pessimistic and optimistic locking strategies. +This allows for very fine-grained control over what kind of locking is required for documents in your application. + +.. _transactions_and_concurrency_optimistic_locking: + +Optimistic Locking +~~~~~~~~~~~~~~~~~~ + +Approach +^^^^^^^^ + +Doctrine has integrated support for automatic optimistic locking +via a ``version`` field. Any document that should be +protected against concurrent modifications during long-running +business transactions gets a ``version`` field that is either a simple +number (mapping type: ``int``) or a date (mapping type: ``date``). +When changes to the document are persisted, +the expected version and version increment are incorporated into the update criteria and modifiers, respectively. +If this results in no document being modified by the update (i.e. expected version did not match), +a ``LockException`` is thrown, which indicates that the document was already modified by another query. + +.. note:: + + | Versioning can only be used on *root* (top-level) documents. + +Document Configuration +^^^^^^^^^^^^^^^^^^^^^^ + +The following example designates a version field using the ``int`` type: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + version: + type: int + version: true + + +Alternatively, the ``date`` type may be used: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + version: + type: date + version: true + +Choosing the Field Type +""""""""""""""""""""""" + +When using the ``date`` type in a high-concurrency environment, it is still possible to create multiple documents +with the same version and cause a conflict. This can be avoided by using the ``int`` type. + +Usage +""""" + +When a version conflict is encountered during +``DocumentManager#flush()``, a ``LockException`` is thrown. +This exception can be caught and handled. Potential responses to a +``LockException`` are to present the conflict to the user or +to refresh or reload objects and then retry the update. + +With PHP promoting a share-nothing architecture, +the worst case scenario for a delay between rendering an update form (with existing document data) +and modifying the document after a form submission may be your application's session timeout. +If the document is changed within that time frame by some other request, +it may be preferable to encounter a ``LockException`` when retrieving the document instead of executing the update. + +You can specify the expected version of a document during a query with ``DocumentManager#find()``: + +.. code-block:: php + + find('User', $theDocumentId, LockMode::OPTIMISTIC, $expectedVersion); + + // do the work + + $dm->flush(); + } catch(LockException $e) { + echo "Sorry, but someone else has already changed this document. Please apply the changes again!"; + } + +Alternatively, an expected version may be specified for an existing document with ``DocumentManager#lock()``: + +.. code-block:: php + + find('User', $theDocumentId); + + try { + // assert version + $dm->lock($document, LockMode::OPTIMISTIC, $expectedVersion); + + } catch(LockException $e) { + echo "Sorry, but someone else has already changed this document. Please apply the changes again!"; + } + +Important Implementation Notes +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +You can easily get the optimistic locking workflow wrong if you +compare the wrong versions. + +Workflow +"""""""" + +Say you have Alice and Bob editing a +hypothetical blog post: + +- Alice reads the headline of the blog post being "Foo", at + optimistic lock version 1 (GET Request) +- Bob reads the headline of the blog post being "Foo", at + optimistic lock version 1 (GET Request) +- Bob updates the headline to "Bar", upgrading the optimistic lock + version to 2 (POST Request of a Form) +- Alice updates the headline to "Baz", ... (POST Request of a + Form) + +At the last stage of this scenario the blog post has to be read +again from the database before Alice's headline can be applied. At +this point you will want to check if the blog post is still at +version 1 (which it is not in this scenario). + +In order to correctly utilize optimistic locking, you *must* add the version as hidden form field or, +for more security, session attribute. +Otherwise, you cannot verify that the version at the time of update is the same as what was originally read +from the database when Alice performed her original GET request for the blog post. +Without correlating the version across form submissions, the application could lose updates. + +Example Code +"""""""""""" + +The form (GET Request): + +.. code-block:: php + + find('BlogPost', 123456); + + echo ''; + echo ''; + +And the change headline action (POST Request): + +.. code-block:: php + + find('BlogPost', $postId, LockMode::OPTIMISTIC, $postVersion); + +.. _transactions_and_concurrency_pessimistic_locking: + +Pessimistic Locking +~~~~~~~~~~~~~~~~~~~ + +Doctrine MongoDB ODM also supports pessimistic locking via a configurable ``lock`` field. +This functionality is implemented entirely by Doctrine; MongoDB has no native support for pessimistic locking. + +Document Configuration +^^^^^^^^^^^^^^^^^^^^^^ + +Pessimistic locking requires a document to designate a lock field using the ``int`` type: + +.. configuration-block:: + + .. code-block:: php + + + + .. code-block:: yaml + + lock: + type: int + lock: true + +Lock Modes +^^^^^^^^^^ + +Doctrine MongoDB ODM currently supports two pessimistic lock modes: + +- Pessimistic Write + (``\Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_WRITE``): locks the + underlying document for concurrent read and write operations. +- Pessimistic Read (``\Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_READ``): + locks other concurrent requests that attempt to update or lock documents + in write mode. + +Usage +^^^^^ + +You can use pessimistic locks in two different scenarios: + +1. Using + ``DocumentManager#find($className, $id, \Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_WRITE)`` + or + ``DocumentManager#find($className, $id, \Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_READ)`` +2. Using + ``DocumentManager#lock($document, \Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_WRITE)`` + or + ``DocumentManager#lock($document, \Doctrine\ODM\MongoDB\LockMode::PESSIMISTIC_READ)`` + +.. warning:: + + | A few things could go wrong: + | + | If a request fails to complete (e.g. unhandled exception), you may end up with stale locks. + Said locks would need to be manually released or you would need to devise a strategy to automatically do so. + One way to mitigate stale locks after an application error would be to gracefully catch the exception + and ensure that relevant documents are unlocked before the request ends. + | + | `Deadlock `_ situations are also possible. + Suppose process P1 needs resource R1 and has locked resource R2 + and that another process P2 has locked resource R1 but also needs resource R2. + If both processes continue waiting for the respective resources, the application will be stuck. + When loading a document, Doctrine can immediately throw an exception if it is already locked. + A deadlock could be created by endlessly retrying attempts to acquire the lock. + One can avoid a possible deadlock by designating a maximum number of retry attempts + and automatically releasing any active locks with the request ends, + thereby allowing a process to end gracefully while another completes its task. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/trees.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/trees.rst.txt new file mode 100644 index 0000000..182f784 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/trees.rst.txt @@ -0,0 +1,267 @@ +Trees +===== + +MongoDB lends itself quite well to storing hierarchical data. This +chapter will demonstrate some examples! + +Full Tree in Single Document +---------------------------- + +.. code-block:: php + + createQueryBuilder('BlogPost') + ->selectSlice('replies', 0, 10) + ->getQuery() + ->getSingleResult(); + + $replies = $post->getReplies(); + +You can read more about this pattern on the MongoDB documentation page "Trees in MongoDB" in the +`Full Tree in Single Document `_ section. + +Parent Reference +---------------- + +.. code-block:: php + + createQueryBuilder('Category') + ->field('parent.id')->equals('theid') + ->getQuery() + ->execute(); + +You can read more about this pattern on the MongoDB documentation page "Trees in MongoDB" in the +`Parent Links `_ section. + +Child Reference +--------------- + +.. code-block:: php + + createQueryBuilder('Category') + ->field('id')->equals('theid') + ->getQuery() + ->getSingleResult(); + + $children = $category->getChildren(); + +Query for immediate parent of a category: + +.. code-block:: php + + createQueryBuilder('Category') + ->field('children.id')->equals('theid') + ->getQuery() + ->getSingleResult(); + +You can read more about this pattern on the MongoDB documentation page "Trees in MongoDB" in the +`Child Links `_ section. + +Array of Ancestors +------------------ + +.. code-block:: php + + createQueryBuilder('Category') + ->field('ancestors.id')->equals('theid') + ->getQuery() + ->execute(); + +Query for all ancestors of a category: + +.. code-block:: php + + createQuery('Category') + ->field('id')->equals('theid') + ->getQuery() + ->getSingleResult(); + + $ancestors = $category->getAncestors(); + +You can read more about this pattern on the MongoDB documentation page "Trees in MongoDB" in the +`Array of Ancestors `_ section. + +Materialized Paths +------------------ + +.. code-block:: php + + createQuery('Category') + ->sort('path', 'asc') + ->getQuery() + ->execute(); + +Query for the node 'b' and all its descendants: + +.. code-block:: php + + createQuery('Category') + ->field('path')->equals('/^a,b,/') + ->getQuery() + ->execute(); + +You can read more about this pattern on the MongoDB documentation page "Trees in MongoDB" in the +`Materialized Paths (Full Path in Each Node) `_ section. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/upserting-documents.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/upserting-documents.rst.txt new file mode 100644 index 0000000..0b2db07 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/upserting-documents.rst.txt @@ -0,0 +1,34 @@ +Upserting Documents +=================== + +Upserting documents in the MongoDB ODM is easy. All you really have to do +is specify an ID ahead of time and Doctrine will perform an ``update`` operation +with the ``upsert`` flag internally instead of a ``batchInsert``. + +Example: + +.. code-block:: php + + setId($articleId); + $article->incrementNumViews(); + $dm->persist($article); + $dm->flush(); + +The above would result in an operation like the following: + +.. code-block:: php + + update( + array('_id' => new MongoId($articleId)), + array('$inc' => array('numViews' => 1)), + array('upsert' => true, 'safe' => true) + ); + +The extra benefit is the fact that you don't have to fetch the ``$article`` in order +to append some new data to the document or change something. All you need is the +identifier. \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/working-with-objects.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/working-with-objects.rst.txt new file mode 100644 index 0000000..33efe00 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/working-with-objects.rst.txt @@ -0,0 +1,573 @@ +Working with Objects +==================== + +Understanding +------------- + +In this chapter we will help you understand the ``DocumentManager`` +and the ``UnitOfWork``. A Unit of Work is similar to an +object-level transaction. A new Unit of Work is implicitly started +when a DocumentManager is initially created or after +``DocumentManager#flush()`` has been invoked. A Unit of Work is +committed (and a new one started) by invoking +``DocumentManager#flush()``. + +A Unit of Work can be manually closed by calling +``DocumentManager#close()``. Any changes to objects within this +Unit of Work that have not yet been persisted are lost. + +The size of a Unit of Work +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The size of a Unit of Work mainly refers to the number of managed +documents at a particular point in time. + +The cost of flush() +~~~~~~~~~~~~~~~~~~~ + +How costly a flush operation is in terms of performance mainly +depends on the size. You can get the size of your Unit of Work as +follows: + +.. code-block:: php + + getUnitOfWork()->size(); + +The size represents the number of managed documents in the Unit of +Work. This size affects the performance of flush() operations due +to change tracking and, of course, memory consumption, so you may +want to check it from time to time during development. + +.. caution:: + + Do not invoke ``flush`` after every change to a + document or every single invocation of persist/remove/merge/... + This is an anti-pattern and unnecessarily reduces the performance + of your application. Instead, form units of work that operate on + your objects and call ``flush`` when you are done. While serving a + single HTTP request there should be usually no need for invoking + ``flush`` more than 0-2 times. + +Direct access to a Unit of Work +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +You can get direct access to the Unit of Work by calling +``DocumentManager#getUnitOfWork()``. This will return the +UnitOfWork instance the DocumentManager is currently using. + +.. code-block:: php + + getUnitOfWork(); + +.. note:: + + Directly manipulating a UnitOfWork is not recommended. + When working directly with the UnitOfWork API, respect methods + marked as INTERNAL by not using them and carefully read the API + documentation. + +Persisting documents +-------------------- + +A document can be made persistent by passing it to the +``DocumentManager#persist($document)`` method. By applying the +persist operation on some document, that document becomes MANAGED, +which means that its persistence is from now on managed by an +DocumentManager. As a result the persistent state of such a +document will subsequently be properly synchronized with the +database when ``DocumentManager#flush()`` is invoked. + +.. caution:: + + Invoking the ``persist`` method on a document does NOT + cause an immediate insert to be issued on the database. Doctrine + applies a strategy called "transactional write-behind", which means + that it will delay most operations until + ``DocumentManager#flush()`` is invoked which will then issue all + necessary queries to synchronize your objects with the database in + the most efficient way. + +Example: + +.. code-block:: php + + setUsername('jwage'); + $user->setPassword('changeme'); + $dm->persist($user); + $dm->flush(); + +.. caution:: + + The document identifier is generated during ``persist`` if not previously + specified. Users cannot rely on a document identifier being available during + the ``prePersist`` event. + +The semantics of the persist operation, applied on a document X, +are as follows: + +- + If X is a new document, it becomes managed. The document X will be + entered into the database as a result of the flush operation. +- + If X is a preexisting managed document, it is ignored by the + persist operation. However, the persist operation is cascaded to + documents referenced by X, if the relationships from X to these + other documents are mapped with cascade=PERSIST or cascade=ALL. +- If X is a removed document, it becomes managed. +- If X is a detached document, the behavior is undefined. + +.. caution:: + + Do not pass detached documents to the persist operation. + +.. _flush_options: + +Flush Options +------------- + +When committing your documents you can specify an array of options to the +``flush`` method. With it you can send options to the underlying database +like ``safe``, ``fsync``, etc. + +Example: + +.. code-block:: php + + getRepository('User')->find($userId); + // ... + $user->setPassword('changeme'); + $dm->flush(null, array('safe' => true, 'fsync' => true)); + +You can configure the default flush options on your ``Configuration`` object +if you want to set them globally for all flushes. + +Example: + +.. code-block:: php + + setDefaultCommitOptions(array( + 'safe' => true, + 'fsync' => true + )); + +.. note:: + + Safe is set to true by default for all writes when using the ODM. + +Removing documents +------------------ + +A document can be removed from persistent storage by passing it to +the ``DocumentManager#remove($document)`` method. By applying the +``remove`` operation on some document, that document becomes +REMOVED, which means that its persistent state will be deleted once +``DocumentManager#flush()`` is invoked. The in-memory state of a +document is unaffected by the ``remove`` operation. + +.. caution:: + + Just like ``persist``, invoking ``remove`` on a + document does NOT cause an immediate query to be issued on the + database. The document will be removed on the next invocation of + ``DocumentManager#flush()`` that involves that document. + +Example: + +.. code-block:: php + + remove($user); + $dm->flush(); + +The semantics of the remove operation, applied to a document X are +as follows: + +- + If X is a new document, it is ignored by the remove operation. + However, the remove operation is cascaded to documents referenced + by X, if the relationship from X to these other documents is mapped + with cascade=REMOVE or cascade=ALL. +- + If X is a managed document, the remove operation causes it to + become removed. The remove operation is cascaded to documents + referenced by X, if the relationships from X to these other + documents is mapped with cascade=REMOVE or cascade=ALL. +- + If X is a detached document, an InvalidArgumentException will be + thrown. +- + If X is a removed document, it is ignored by the remove operation. +- + A removed document X will be removed from the database as a result + of the flush operation. + +Detaching documents +------------------- + +A document is detached from a DocumentManager and thus no longer +managed by invoking the ``DocumentManager#detach($document)`` +method on it or by cascading the detach operation to it. Changes +made to the detached document, if any (including removal of the +document), will not be synchronized to the database after the +document has been detached. + +Doctrine will not hold on to any references to a detached +document. + +Example: + +.. code-block:: php + + detach($document); + +The semantics of the detach operation, applied to a document X are +as follows: + + +- + If X is a managed document, the detach operation causes it to + become detached. The detach operation is cascaded to documents + referenced by X, if the relationships from X to these other + documents is mapped with cascade=DETACH or cascade=ALL. Documents + which previously referenced X will continue to reference X. +- + If X is a new or detached document, it is ignored by the detach + operation. +- + If X is a removed document, the detach operation is cascaded to + documents referenced by X, if the relationships from X to these + other documents is mapped with cascade=DETACH or + cascade=ALL/Documents which previously referenced X will continue + to reference X. + +There are several situations in which a document is detached +automatically without invoking the ``detach`` method: + + +- + When ``DocumentManager#clear()`` is invoked, all documents that are + currently managed by the DocumentManager instance become detached. +- + When serializing a document. The document retrieved upon subsequent + unserialization will be detached (This is the case for all + documents that are serialized and stored in some cache). + +The ``detach`` operation is usually not as frequently needed and +used as ``persist`` and ``remove``. + +Merging documents +----------------- + +Merging documents refers to the merging of (usually detached) +documents into the context of a DocumentManager so that they +become managed again. To merge the state of a document into an +DocumentManager use the ``DocumentManager#merge($document)`` +method. The state of the passed document will be merged into a +managed copy of this document and this copy will subsequently be +returned. + +Example: + +.. code-block:: php + + merge($detachedDocument); + // $document now refers to the fully managed copy returned by the merge operation. + // The DocumentManager $dm now manages the persistence of $document as usual. + + The semantics of the merge operation, applied to a document X, are + as follows: + +- + If X is a detached document, the state of X is copied onto a + pre-existing managed document instance X' of the same iddocument or + a new managed copy X' of X is created. +- + If X is a new document instance, an InvalidArgumentException will + be thrown. +- + If X is a removed document instance, an InvalidArgumentException + will be thrown. +- + If X is a managed document, it is ignored by the merge operation, + however, the merge operation is cascaded to documents referenced by + relationships from X if these relationships have been mapped with + the cascade element value MERGE or ALL. +- + For all documents Y referenced by relationships from X having the + cascade element value MERGE or ALL, Y is merged recursively as Y'. + For all such Y referenced by X, X' is set to reference Y'. (Note + that if X is managed then X is the same object as X'.) +- + If X is a document merged to X', with a reference to another + document Y, where cascade=MERGE or cascade=ALL is not specified, + then navigation of the same association from X' yields a reference + to a managed object Y' with the same persistent iddocument as Y. + +The ``merge`` operation is usually not as frequently needed and +used as ``persist`` and ``remove``. The most common scenario for +the ``merge`` operation is to reattach documents to an +DocumentManager that come from some cache (and are therefore +detached) and you want to modify and persist such a document. + +.. note:: + + If you load some detached documents from a cache and you + do not need to persist or delete them or otherwise make use of them + without the need for persistence services there is no need to use + ``merge``. I.e. you can simply pass detached objects from a cache + directly to the view. + +References +---------- + +References between documents and embedded documents are represented +just like in regular object-oriented PHP, with references to other +objects or collections of objects. + +Establishing References +----------------------- + +Establishing a reference to another document is straight forward: + +Here is an example where we add a new comment to an article: + +.. code-block:: php + + getComments()->add($comment); + +Or you can set a single reference: + +.. code-block:: php + + setAddress($address); + +Removing References +------------------- + +Removing an association between two documents is similarly +straight-forward. There are two strategies to do so, by key and by +element. Here are some examples: + +.. code-block:: php + + getComments()->removeElement($comment); + $article->getComments()->remove($ithComment); + +Or you can remove a single reference: + +.. code-block:: php + + setAddress(null); + +When working with collections, keep in mind that a Collection is +essentially an ordered map (just like a PHP array). That is why the +``remove`` operation accepts an index/key. ``removeElement`` is a +separate method that has O(n) complexity, where n is the size of +the map. + +Transitive persistence +---------------------- + +Persisting, removing, detaching and merging individual documents +can become pretty cumbersome, especially when a larger object graph +with collections is involved. Therefore Doctrine provides a +mechanism for transitive persistence through cascading of these +operations. Each reference to another document or a collection of +documents can be configured to automatically cascade certain +operations. By default, no operations are cascaded. + +The following cascade options exist: + + +- + persist : Cascades persist operations to the associated documents. +- remove : Cascades remove operations to the associated documents. +- merge : Cascades merge operations to the associated documents. +- detach : Cascades detach operations to the associated documents. +- + all : Cascades persist, remove, merge and detach operations to + associated documents. + +The following example shows an association to a number of +addresses. If persist() or remove() is invoked on any User +document, it will be cascaded to all associated Address documents +in the $addresses collection. + +.. code-block:: php + + find('User', $id); + +The return value is either the found document instance or null if +no instance could be found with the given identifier. + +Essentially, ``DocumentManager#find()`` is just a shortcut for the +following: + +.. code-block:: php + + getRepository('User')->find($id); + +``DocumentManager#getRepository($documentName)`` returns a +repository object which provides many ways to retrieve documents of +the specified type. By default, the repository instance is of type +``Doctrine\ODM\MongoDB\DocumentRepository``. You can also use +custom repository classes. + +By Simple Conditions +~~~~~~~~~~~~~~~~~~~~ + +To query for one or more documents based on several conditions that +form a logical conjunction, use the ``findBy`` and ``findOneBy`` +methods on a repository as follows: + +.. code-block:: php + + getRepository('User')->findBy(array('age' => 20)); + + // All users that are 20 years old and have a surname of 'Miller' + $users = $dm->getRepository('User')->findBy(array('age' => 20, 'surname' => 'Miller')); + + // A single user by its nickname + $user = $dm->getRepository('User')->findOneBy(array('nickname' => 'romanb')); + +A DocumentRepository also provides a mechanism for more concise +calls through its use of ``__call``. Thus, the following two +examples are equivalent: + +.. code-block:: php + + getRepository('User')->findOneBy(array('nickname' => 'romanb')); + + // A single user by its nickname (__call magic) + $user = $dm->getRepository('User')->findOneByNickname('romanb'); + +.. note:: + + You can learn more about Repositories in a :ref:`dedicated chapter `. + +By Lazy Loading +~~~~~~~~~~~~~~~ + +Whenever you have a managed document instance at hand, you can +traverse and use any associations of that document as if they were +in-memory already. Doctrine will automatically load the associated +objects on demand through the concept of lazy-loading. + +By Query Builder Objects +~~~~~~~~~~~~~~~~ + +The most powerful and flexible method to query for persistent +objects is the Query\Builder object. The Query\Builder object enables you to query +for persistent objects with a fluent object oriented interface. + +You can create a query using +``DocumentManager#createQueryBuilder($documentName = null)``. Here is a +simple example: + +.. code-block:: php + + createQueryBuilder('User') + ->field('age')->range(20, 30); + $q = $qb->getQuery() + $users = $q->execute(); + +By Reference +~~~~~~~~~~~~~~~~ + +To query documents with a ReferenceOne association to another document, use the ``references($document)`` expression: + +.. code-block:: php + + find('Group', $id); + $usersWithGroup = $dm->createQueryBuilder('User') + ->field('group')->references($group) + ->getQuery()->execute(); + +To find documents with a ReferenceMany association that includes a certain document, use the ``includesReferenceTo($document)`` expression: + +.. code-block:: php + + createQueryBuilder('User') + ->field('groups')->includesReferenceTo($group) + ->getQuery()->execute(); diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/xml-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/xml-mapping.rst.txt new file mode 100644 index 0000000..1f56097 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/xml-mapping.rst.txt @@ -0,0 +1,188 @@ +XML Mapping +=========== + +The XML mapping driver enables you to provide the ODM metadata in +form of XML documents. + +The XML driver is backed by an XML Schema document that describes +the structure of a mapping document. The most recent version of the +XML Schema document is available online at +`http://doctrine-project.org/schemas/odm/doctrine-mongo-mapping.xsd `_. +The most convenient way to work with XML mapping files is to use an +IDE/editor that can provide code-completion based on such an XML +Schema document. The following is an outline of a XML mapping +document with the proper xmlns/xsi setup for the latest code in +trunk. + +.. code-block:: xml + + + + ... + + + +.. note:: + + If you do not want to use latest XML Schema document please use link like + `http://doctrine-project.org/schemas/odm/doctrine-mongo-mapping-1.0.0-BETA12.xsd `_. + You can change ``1.0.0-BETA12`` part of the URL to + `any other ODM version `_. + +The XML mapping document of a class is loaded on-demand the first +time it is requested and subsequently stored in the metadata cache. +In order to work, this requires certain conventions: + + +- + Each document/mapped superclass must get its own dedicated XML + mapping document. +- + The name of the mapping document must consist of the fully + qualified name of the class, where namespace separators are + replaced by dots (.). +- + All mapping documents should get the extension ".dcm.xml" to + identify it as a Doctrine mapping file. This is more of a + convention and you are not forced to do this. You can change the + file extension easily enough. + +.. code-block:: php + + setFileExtension('.xml'); + +It is recommended to put all XML mapping documents in a single +folder but you can spread the documents over several folders if you +want to. In order to tell the XmlDriver where to look for your +mapping documents, supply an array of paths as the first argument +of the constructor, like this: + +.. code-block:: php + + setMetadataDriverImpl($driver); + +Simplified XML Driver +~~~~~~~~~~~~~~~~~~~~~ + +The Symfony project sponsored a driver that simplifies usage of the XML Driver. +The changes between the original driver are: + +1. File Extension is .mongodb-odm.xml +2. Filenames are shortened, "MyProject\Documents\User" will become User.mongodb-odm.xml +3. You can add a global file and add multiple documents in this file. + +Configuration of this client works a little bit different: + +.. code-block:: php + + '/path/to/files1', + 'OtherProject\Documents' => '/path/to/files2' + ); + $driver = new \Doctrine\ODM\MongoDB\Mapping\Driver\SimplifiedXmlDriver($namespaces); + $driver->setGlobalBasename('global'); // global.mongodb-odm.xml + +Example +------- + +As a quick start, here is a small example document that makes use +of several common elements: + +.. code-block:: xml + + // Documents.User.dcm.xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Be aware that class-names specified in the XML files should be fully qualified. + +.. note:: + + ``field-name`` is the name of **property in your object** while ``name`` specifies + name of the field **in the database**. Specifying latter is optional and defaults to + ``field-name`` if not set explicitly. + +Reference +--------- + +.. _xml_reference_lock: + +Lock +^^^^ + +The field with the ``lock`` attribute will be used to store lock information for :ref:`pessimistic locking `. +This is only compatible with the ``int`` field type, and cannot be combined with ``id="true"``. + +.. code-block:: xml + + + + + +.. _xml_reference_version: + +Version +^^^^^^^ + +The field with the ``version`` attribute will be used to store version information for :ref:`optimistic locking `. +This is only compatible with ``int`` and ``date`` field types, and cannot be combined with ``id="true"``. + +.. code-block:: xml + + + + + +By default, Doctrine ODM updates :ref:`embed-many ` and +:ref:`reference-many ` collections in separate write operations, +which do not bump the document version. Users employing document versioning are +encouraged to use the :ref:`atomicSet ` or +:ref:`atomicSetArray ` strategies for such collections, which +will ensure that collections are updated in the same write operation as the +versioned parent document. diff --git a/build.docset/Contents/Resources/Documents/_sources/reference/yml-mapping.rst.txt b/build.docset/Contents/Resources/Documents/_sources/reference/yml-mapping.rst.txt new file mode 100644 index 0000000..f26854f --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/reference/yml-mapping.rst.txt @@ -0,0 +1,211 @@ +YAML Mapping +============ + +The YAML mapping driver enables you to provide the ODM metadata in +form of YAML documents. + +The YAML mapping document of a class is loaded on-demand the first +time it is requested and subsequently stored in the metadata cache. +In order to work, this requires certain conventions: + +- + Each document/mapped superclass must get its own dedicated YAML + mapping document. +- + The name of the mapping document must consist of the fully + qualified name of the class, where namespace separators are + replaced by dots (.). +- + All mapping documents should get the extension ".dcm.yml" to + identify it as a Doctrine mapping file. This is more of a + convention and you are not forced to do this. You can change the + file extension easily enough. + +- + +.. code-block:: php + + setFileExtension('.yml'); + +It is recommended to put all YAML mapping documents in a single +folder but you can spread the documents over several folders if you +want to. In order to tell the YamlDriver where to look for your +mapping documents, supply an array of paths as the first argument +of the constructor, like this: + +.. code-block:: php + + setMetadataDriverImpl($driver); + +Simplified YAML Driver +~~~~~~~~~~~~~~~~~~~~~~ + +The Symfony project sponsored a driver that simplifies usage of the YAML Driver. +The changes between the original driver are: + +1. File Extension is .mongodb-odm.yml +2. Filenames are shortened, "MyProject\\Documents\\User" will become User.mongodb-odm.yml +3. You can add a global file and add multiple documents in this file. + +Configuration of this client works a little bit different: + +.. code-block:: php + + 'MyProject\Documents', + '/path/to/files2' => 'OtherProject\Documents' + ); + $driver = new \Doctrine\ODM\MongoDB\Mapping\Driver\SimplifiedYamlDriver($namespaces); + $driver->setGlobalBasename('global'); // global.mongodb-odm.yml + +Example +------- + +As a quick start, here is a small example document that makes use +of several common elements: + +.. code-block:: yaml + + # Documents.User.dcm.yml + + Documents\User: + db: documents + collection: user + fields: + id: + id: true + username: + name: login + type: string + email: + unique: + order: desc + createdAt: + type: date + indexes: + index1: + keys: + username: desc + options: + unique: true + dropDups: true + safe: true + embedOne: + address: + targetDocument: Documents\Address + embedMany: + phonenumbers: + targetDocument: Documents\Phonenumber + referenceOne: + profile: + targetDocument: Documents\Profile + cascade: all + account: + targetDocument: Documents\Account + cascade: all + referenceMany: + groups: + targetDocument: Documents\Group + cascade: all + + # Alternative syntax for the exact same example + # (allows custom key name for embedded document and reference). + Documents\User: + db: documents + collection: user + fields: + id: + id: true + username: + name: login + type: string + email: + unique: + order: desc + createdAt: + type: date + address: + embedded: true + type: one + targetDocument: Documents\Address + phonenumbers: + embedded: true + type: many + targetDocument: Documents\Phonenumber + profile: + reference: true + type: one + targetDocument: Documents\Profile + cascade: all + account: + reference: true + type: one + targetDocument: Documents\Account + cascade: all + groups: + reference: true + type: many + targetDocument: Documents\Group + cascade: all + indexes: + index1: + keys: + username: desc + options: + unique: true + dropDups: true + safe: true + +Be aware that class-names specified in the YAML files should be fully qualified. + +.. note:: + + The ``name`` property is an optional setting to change name of the field + **in the database**. Specifying it is optional and defaults to the name + of mapped field. + +Reference +--------- + +.. _yml_reference_lock: + +Lock +^^^^ + +The field with the ``lock`` property will be used to store lock information for :ref:`pessimistic locking `. +This is only compatible with the ``int`` field type, and cannot be combined with ``id: true``. + +.. code-block:: yaml + + lock: + type: int + lock: true + +.. _yml_reference_version: + +Version +^^^^^^^ + +The field with the ``version`` property will be used to store version information for :ref:`optimistic locking `. +This is only compatible with ``int`` and ``date`` field types, and cannot be combined with ``id: true``. + +.. code-block:: yaml + + version: + type: int + version: true + +By default, Doctrine ODM updates :ref:`embed-many ` and +:ref:`reference-many ` collections in separate write operations, +which do not bump the document version. Users employing document versioning are +encouraged to use the :ref:`atomicSet ` or +:ref:`atomicSetArray ` strategies for such collections, which +will ensure that collections are updated in the same write operation as the +versioned parent document. diff --git a/build.docset/Contents/Resources/Documents/_sources/tutorials/getting-started.rst.txt b/build.docset/Contents/Resources/Documents/_sources/tutorials/getting-started.rst.txt new file mode 100644 index 0000000..0a3698b --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_sources/tutorials/getting-started.rst.txt @@ -0,0 +1,301 @@ +Getting Started +=============== + +Doctrine is a project that aims to handle the persistence of your +domain model in a non-interfering way. Non-relational or no-sql +databases like MongoDB give you flexibility of building data store +around your object model and not vise versa. You can read more on the +initial configuration and setup in :doc:`Introduction to MongoDB Object +Document Mapper <../reference/introduction>`. This section will give you a basic +overview of what could be accomplished using Doctrine MongoDB ODM. + +Example Model: Simple Blog +-------------------------- + +To create the simplest example, let’s assume the following in a simple blog web application: + +- Blog has a user. +- Blog user can make blog posts + +A first prototype +----------------- + +For the above mentioned example, something as simple as this could be modeled with plain PHP classes. +First define the ``User`` document: + +.. code-block:: php + + + + + + + + + + + + + + + + + + + + + + + + + + .. code-block:: yaml + + Documents\User: + fields: + id: + type: id + id: true + name: + type: string + email: + type: string + referenceMany: + posts: + targetDocument: Documents\BlogPost + cascade: all + + Documents\BlogPost: + fields: + id: + type: id + id: true + title: + type: string + body: + type: string + createdAt: + type: date + +That’s it, we have our models, and we can save and retrieve them. Now +all we need to do is to properly instantiate the ``DocumentManager`` +instance. Read more about setting up the Doctrine MongoDB ODM in the +:doc:`Introduction to MongoDB Object Document Mapper <../reference/introduction>`: + +.. code-block:: php + + setProxyDir('/path/to/generate/proxies'); + $config->setProxyNamespace('Proxies'); + $config->setHydratorDir('/path/to/generate/hydrators'); + $config->setHydratorNamespace('Hydrators'); + $config->setMetadataDriverImpl(AnnotationDriver::create('/path/to/document/classes')); + + $dm = DocumentManager::create(new Connection(), $config); + +Usage +----- + +Here is how you would use your models now: + +.. code-block:: php + + setName('Bulat S.'); + $user->setEmail('email@example.com'); + + // tell Doctrine 2 to save $user on the next flush() + $dm->persist($user); + + // create blog post + $post = new BlogPost(); + $post->setTitle('My First Blog Post'); + $post->setBody('MongoDB + Doctrine 2 ODM = awesomeness!'); + $post->setCreatedAt(new DateTime()); + + $user->addPost($post); + + // store everything to MongoDB + $dm->flush(); + +.. note:: + + Note that you do not need to explicitly call persist on the ``$post`` because the operation + will cascade on to the reference automatically. + +Now if you did everything correctly, you should have those two objects +stored in MongoDB in correct collections and databases. You can use the +`php-mongodb-admin project, hosted on github`_ to look at your +``BlogPost`` collection, where you will see only one document: + +:: + + Array + ( + [_id] => 4bec5869fdc212081d000000 + [title] => My First Blog Post + [body] => MongoDB + Doctrine 2 ODM = awesomeness! + [createdAt] => MongoDate Object + ( + [sec] => 1273723200 + [usec] => 0 + ) + ) + +And the ``User`` collection would consist of the following: + +:: + + Array + ( + [_id] => 4bec5869fdc212081d010000 + [name] => Bulat S. + [email] => email@example.com + [posts] => Array + ( + [0] => Array + ( + [$ref] => blog_posts + [$id] => 4bec5869fdc212081d000000 + [$db] => test_database + ) + ) + ) + +You can retrieve the user later by its identifier: + +.. code-block:: php + + find('User', $userId); + +Or you can find the user by name even: + +.. code-block:: php + + getRepository('User')->findOneByName('Bulat S.'); + +If you want to iterate over the posts the user references it is as easy as the following: + +.. code-block:: php + + getPosts(); + foreach ($posts as $post) { + } + +You will notice that working with objects is nothing magical and you only have access to the properties, +getters and setters that you have defined yourself so the semantics are very clear. You can continue +reading about the MongoDB in the :doc:`Introduction to MongoDB Object Document Mapper <../reference/introduction>`. + +.. _php-mongodb-admin project, hosted on github: http://github.com/jwage/php-mongodb-admin diff --git a/build.docset/Contents/Resources/Documents/_static/ajax-loader.gif b/build.docset/Contents/Resources/Documents/_static/ajax-loader.gif new file mode 100644 index 0000000..61faf8c Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/ajax-loader.gif differ diff --git a/build.docset/Contents/Resources/Documents/_static/arrows.jpg b/build.docset/Contents/Resources/Documents/_static/arrows.jpg new file mode 100644 index 0000000..9ea7fae Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/arrows.jpg differ diff --git a/build.docset/Contents/Resources/Documents/_static/basic.css b/build.docset/Contents/Resources/Documents/_static/basic.css new file mode 100644 index 0000000..6df76b0 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/basic.css @@ -0,0 +1,639 @@ +/* + * basic.css + * ~~~~~~~~~ + * + * Sphinx stylesheet -- basic theme. + * + * :copyright: Copyright 2007-2017 by the Sphinx team, see AUTHORS. + * :license: BSD, see LICENSE for details. + * + */ + +/* -- main layout ----------------------------------------------------------- */ + +div.clearer { + clear: both; +} + +/* -- relbar ---------------------------------------------------------------- */ + +div.related { + width: 100%; + font-size: 90%; +} + +div.related h3 { + display: none; +} + +div.related ul { + margin: 0; + padding: 0 0 0 10px; + list-style: none; +} + +div.related li { + display: inline; +} + +div.related li.right { + float: right; + margin-right: 5px; +} + +/* -- sidebar --------------------------------------------------------------- */ + +div.sphinxsidebarwrapper { + padding: 10px 5px 0 10px; +} + +div.sphinxsidebar { + float: left; + width: 230px; + margin-left: -100%; + font-size: 90%; + word-wrap: break-word; + overflow-wrap : break-word; +} + +div.sphinxsidebar ul { + list-style: none; +} + +div.sphinxsidebar ul ul, +div.sphinxsidebar ul.want-points { + margin-left: 20px; + list-style: square; +} + +div.sphinxsidebar ul ul { + margin-top: 0; + margin-bottom: 0; +} + +div.sphinxsidebar form { + margin-top: 10px; +} + +div.sphinxsidebar input { + border: 1px solid #98dbcc; + font-family: sans-serif; + font-size: 1em; +} + +div.sphinxsidebar #searchbox input[type="text"] { + width: 170px; +} + +img { + border: 0; + max-width: 100%; +} + +/* -- search page ----------------------------------------------------------- */ + +ul.search { + margin: 10px 0 0 20px; + padding: 0; +} + +ul.search li { + padding: 5px 0 5px 20px; + background-image: url(file.png); + background-repeat: no-repeat; + background-position: 0 7px; +} + +ul.search li a { + font-weight: bold; +} + +ul.search li div.context { + color: #888; + margin: 2px 0 0 30px; + text-align: left; +} + +ul.keywordmatches li.goodmatch a { + font-weight: bold; +} + +/* -- index page ------------------------------------------------------------ */ + +table.contentstable { + width: 90%; + margin-left: auto; + margin-right: auto; +} + +table.contentstable p.biglink { + line-height: 150%; +} + +a.biglink { + font-size: 1.3em; +} + +span.linkdescr { + font-style: italic; + padding-top: 5px; + font-size: 90%; +} + +/* -- general index --------------------------------------------------------- */ + +table.indextable { + width: 100%; +} + +table.indextable td { + text-align: left; + vertical-align: top; +} + +table.indextable ul { + margin-top: 0; + margin-bottom: 0; + list-style-type: none; +} + +table.indextable > tbody > tr > td > ul { + padding-left: 0em; +} + +table.indextable tr.pcap { + height: 10px; +} + +table.indextable tr.cap { + margin-top: 10px; + background-color: #f2f2f2; +} + +img.toggler { + margin-right: 3px; + margin-top: 3px; + cursor: pointer; +} + +div.modindex-jumpbox { + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; + margin: 1em 0 1em 0; + padding: 0.4em; +} + +div.genindex-jumpbox { + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; + margin: 1em 0 1em 0; + padding: 0.4em; +} + +/* -- domain module index --------------------------------------------------- */ + +table.modindextable td { + padding: 2px; + border-collapse: collapse; +} + +/* -- general body styles --------------------------------------------------- */ + +div.body p, div.body dd, div.body li, div.body blockquote { + -moz-hyphens: auto; + -ms-hyphens: auto; + -webkit-hyphens: auto; + hyphens: auto; +} + +a.headerlink { + visibility: hidden; +} + +h1:hover > a.headerlink, +h2:hover > a.headerlink, +h3:hover > a.headerlink, +h4:hover > a.headerlink, +h5:hover > a.headerlink, +h6:hover > a.headerlink, +dt:hover > a.headerlink, +caption:hover > a.headerlink, +p.caption:hover > a.headerlink, +div.code-block-caption:hover > a.headerlink { + visibility: visible; +} + +div.body p.caption { + text-align: inherit; +} + +div.body td { + text-align: left; +} + +.first { + margin-top: 0 !important; +} + +p.rubric { + margin-top: 30px; + font-weight: bold; +} + +img.align-left, .figure.align-left, object.align-left { + clear: left; + float: left; + margin-right: 1em; +} + +img.align-right, .figure.align-right, object.align-right { + clear: right; + float: right; + margin-left: 1em; +} + +img.align-center, .figure.align-center, object.align-center { + display: block; + margin-left: auto; + margin-right: auto; +} + +.align-left { + text-align: left; +} + +.align-center { + text-align: center; +} + +.align-right { + text-align: right; +} + +/* -- sidebars -------------------------------------------------------------- */ + +div.sidebar { + margin: 0 0 0.5em 1em; + border: 1px solid #ddb; + padding: 7px 7px 0 7px; + background-color: #ffe; + width: 40%; + float: right; +} + +p.sidebar-title { + font-weight: bold; +} + +/* -- topics ---------------------------------------------------------------- */ + +div.topic { + border: 1px solid #ccc; + padding: 7px 7px 0 7px; + margin: 10px 0 10px 0; +} + +p.topic-title { + font-size: 1.1em; + font-weight: bold; + margin-top: 10px; +} + +/* -- admonitions ----------------------------------------------------------- */ + +div.admonition { + margin-top: 10px; + margin-bottom: 10px; + padding: 7px; +} + +div.admonition dt { + font-weight: bold; +} + +div.admonition dl { + margin-bottom: 0; +} + +p.admonition-title { + margin: 0px 10px 5px 0px; + font-weight: bold; +} + +div.body p.centered { + text-align: center; + margin-top: 25px; +} + +/* -- tables ---------------------------------------------------------------- */ + +table.docutils { + border: 0; + border-collapse: collapse; +} + +table caption span.caption-number { + font-style: italic; +} + +table caption span.caption-text { +} + +table.docutils td, table.docutils th { + padding: 1px 8px 1px 5px; + border-top: 0; + border-left: 0; + border-right: 0; + border-bottom: 1px solid #aaa; +} + +table.footnote td, table.footnote th { + border: 0 !important; +} + +th { + text-align: left; + padding-right: 5px; +} + +table.citation { + border-left: solid 1px gray; + margin-left: 1px; +} + +table.citation td { + border-bottom: none; +} + +/* -- figures --------------------------------------------------------------- */ + +div.figure { + margin: 0.5em; + padding: 0.5em; +} + +div.figure p.caption { + padding: 0.3em; +} + +div.figure p.caption span.caption-number { + font-style: italic; +} + +div.figure p.caption span.caption-text { +} + +/* -- field list styles ----------------------------------------------------- */ + +table.field-list td, table.field-list th { + border: 0 !important; +} + +.field-list ul { + margin: 0; + padding-left: 1em; +} + +.field-list p { + margin: 0; +} + +.field-name { + -moz-hyphens: manual; + -ms-hyphens: manual; + -webkit-hyphens: manual; + hyphens: manual; +} + +/* -- other body styles ----------------------------------------------------- */ + +ol.arabic { + list-style: decimal; +} + +ol.loweralpha { + list-style: lower-alpha; +} + +ol.upperalpha { + list-style: upper-alpha; +} + +ol.lowerroman { + list-style: lower-roman; +} + +ol.upperroman { + list-style: upper-roman; +} + +dl { + margin-bottom: 15px; +} + +dd p { + margin-top: 0px; +} + +dd ul, dd table { + margin-bottom: 10px; +} + +dd { + margin-top: 3px; + margin-bottom: 10px; + margin-left: 30px; +} + +dt:target, .highlighted { + background-color: #fbe54e; +} + +dl.glossary dt { + font-weight: bold; + font-size: 1.1em; +} + +.optional { + font-size: 1.3em; +} + +.sig-paren { + font-size: larger; +} + +.versionmodified { + font-style: italic; +} + +.system-message { + background-color: #fda; + padding: 5px; + border: 3px solid red; +} + +.footnote:target { + background-color: #ffa; +} + +.line-block { + display: block; + margin-top: 1em; + margin-bottom: 1em; +} + +.line-block .line-block { + margin-top: 0; + margin-bottom: 0; + margin-left: 1.5em; +} + +.guilabel, .menuselection { + font-family: sans-serif; +} + +.accelerator { + text-decoration: underline; +} + +.classifier { + font-style: oblique; +} + +abbr, acronym { + border-bottom: dotted 1px; + cursor: help; +} + +/* -- code displays --------------------------------------------------------- */ + +pre { + overflow: auto; + overflow-y: hidden; /* fixes display issues on Chrome browsers */ +} + +span.pre { + -moz-hyphens: none; + -ms-hyphens: none; + -webkit-hyphens: none; + hyphens: none; +} + +td.linenos pre { + padding: 5px 0px; + border: 0; + background-color: transparent; + color: #aaa; +} + +table.highlighttable { + margin-left: 0.5em; +} + +table.highlighttable td { + padding: 0 0.5em 0 0.5em; +} + +div.code-block-caption { + padding: 2px 5px; + font-size: small; +} + +div.code-block-caption code { + background-color: transparent; +} + +div.code-block-caption + div > div.highlight > pre { + margin-top: 0; +} + +div.code-block-caption span.caption-number { + padding: 0.1em 0.3em; + font-style: italic; +} + +div.code-block-caption span.caption-text { +} + +div.literal-block-wrapper { + padding: 1em 1em 0; +} + +div.literal-block-wrapper div.highlight { + margin: 0; +} + +code.descname { + background-color: transparent; + font-weight: bold; + font-size: 1.2em; +} + +code.descclassname { + background-color: transparent; +} + +code.xref, a code { + background-color: transparent; + font-weight: bold; +} + +h1 code, h2 code, h3 code, h4 code, h5 code, h6 code { + background-color: transparent; +} + +.viewcode-link { + float: right; +} + +.viewcode-back { + float: right; + font-family: sans-serif; +} + +div.viewcode-block:target { + margin: -1px -10px; + padding: 0 10px; +} + +/* -- math display ---------------------------------------------------------- */ + +img.math { + vertical-align: middle; +} + +div.body div.math p { + text-align: center; +} + +span.eqno { + float: right; +} + +span.eqno a.headerlink { + position: relative; + left: 0px; + z-index: 1; +} + +div.math:hover a.headerlink { + visibility: visible; +} + +/* -- printout stylesheet --------------------------------------------------- */ + +@media print { + div.document, + div.documentwrapper, + div.bodywrapper { + margin: 0 !important; + width: 100%; + } + + div.sphinxsidebar, + div.related, + div.footer, + #top-link { + display: none; + } +} \ No newline at end of file diff --git a/build.docset/Contents/Resources/Documents/_static/bg-gradient.jpg b/build.docset/Contents/Resources/Documents/_static/bg-gradient.jpg new file mode 100644 index 0000000..e48d841 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/bg-gradient.jpg differ diff --git a/build.docset/Contents/Resources/Documents/_static/bl-corner.gif b/build.docset/Contents/Resources/Documents/_static/bl-corner.gif new file mode 100644 index 0000000..f40f7fc Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/bl-corner.gif differ diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.css b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.css new file mode 100644 index 0000000..a3352d7 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.css @@ -0,0 +1,1092 @@ +/*! + * Bootstrap Responsive v2.2.2 + * + * Copyright 2012 Twitter, Inc + * Licensed under the Apache License v2.0 + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Designed and built with all the love in the world @twitter by @mdo and @fat. + */ + +@-ms-viewport { + width: device-width; +} + +.clearfix { + *zoom: 1; +} + +.clearfix:before, +.clearfix:after { + display: table; + line-height: 0; + content: ""; +} + +.clearfix:after { + clear: both; +} + +.hide-text { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; +} + +.input-block-level { + display: block; + width: 100%; + min-height: 30px; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +.hidden { + display: none; + visibility: hidden; +} + +.visible-phone { + display: none !important; +} + +.visible-tablet { + display: none !important; +} + +.hidden-desktop { + display: none !important; +} + +.visible-desktop { + display: inherit !important; +} + +@media (min-width: 768px) and (max-width: 979px) { + .hidden-desktop { + display: inherit !important; + } + .visible-desktop { + display: none !important ; + } + .visible-tablet { + display: inherit !important; + } + .hidden-tablet { + display: none !important; + } +} + +@media (max-width: 767px) { + .hidden-desktop { + display: inherit !important; + } + .visible-desktop { + display: none !important; + } + .visible-phone { + display: inherit !important; + } + .hidden-phone { + display: none !important; + } +} + +@media (min-width: 1200px) { + .row { + margin-left: -30px; + *zoom: 1; + } + .row:before, + .row:after { + display: table; + line-height: 0; + content: ""; + } + .row:after { + clear: both; + } + [class*="span"] { + float: left; + min-height: 1px; + margin-left: 30px; + } + .container, + .navbar-static-top .container, + .navbar-fixed-top .container, + .navbar-fixed-bottom .container { + width: 1170px; + } + .span12 { + width: 1170px; + } + .span11 { + width: 1070px; + } + .span10 { + width: 970px; + } + .span9 { + width: 870px; + } + .span8 { + width: 770px; + } + .span7 { + width: 670px; + } + .span6 { + width: 570px; + } + .span5 { + width: 470px; + } + .span4 { + width: 370px; + } + .span3 { + width: 270px; + } + .span2 { + width: 170px; + } + .span1 { + width: 70px; + } + .offset12 { + margin-left: 1230px; + } + .offset11 { + margin-left: 1130px; + } + .offset10 { + margin-left: 1030px; + } + .offset9 { + margin-left: 930px; + } + .offset8 { + margin-left: 830px; + } + .offset7 { + margin-left: 730px; + } + .offset6 { + margin-left: 630px; + } + .offset5 { + margin-left: 530px; + } + .offset4 { + margin-left: 430px; + } + .offset3 { + margin-left: 330px; + } + .offset2 { + margin-left: 230px; + } + .offset1 { + margin-left: 130px; + } + .row-fluid { + width: 100%; + *zoom: 1; + } + .row-fluid:before, + .row-fluid:after { + display: table; + line-height: 0; + content: ""; + } + .row-fluid:after { + clear: both; + } + .row-fluid [class*="span"] { + display: block; + float: left; + width: 100%; + min-height: 30px; + margin-left: 2.564102564102564%; + *margin-left: 2.5109110747408616%; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + } + .row-fluid [class*="span"]:first-child { + margin-left: 0; + } + .row-fluid .controls-row [class*="span"] + [class*="span"] { + margin-left: 2.564102564102564%; + } + .row-fluid .span12 { + width: 100%; + *width: 99.94680851063829%; + } + .row-fluid .span11 { + width: 91.45299145299145%; + *width: 91.39979996362975%; + } + .row-fluid .span10 { + width: 82.90598290598291%; + *width: 82.8527914166212%; + } + .row-fluid .span9 { + width: 74.35897435897436%; + *width: 74.30578286961266%; + } + .row-fluid .span8 { + width: 65.81196581196582%; + *width: 65.75877432260411%; + } + .row-fluid .span7 { + width: 57.26495726495726%; + *width: 57.21176577559556%; + } + .row-fluid .span6 { + width: 48.717948717948715%; + *width: 48.664757228587014%; + } + .row-fluid .span5 { + width: 40.17094017094017%; + *width: 40.11774868157847%; + } + .row-fluid .span4 { + width: 31.623931623931625%; + *width: 31.570740134569924%; + } + .row-fluid .span3 { + width: 23.076923076923077%; + *width: 23.023731587561375%; + } + .row-fluid .span2 { + width: 14.52991452991453%; + *width: 14.476723040552828%; + } + .row-fluid .span1 { + width: 5.982905982905983%; + *width: 5.929714493544281%; + } + .row-fluid .offset12 { + margin-left: 105.12820512820512%; + *margin-left: 105.02182214948171%; + } + .row-fluid .offset12:first-child { + margin-left: 102.56410256410257%; + *margin-left: 102.45771958537915%; + } + .row-fluid .offset11 { + margin-left: 96.58119658119658%; + *margin-left: 96.47481360247316%; + } + .row-fluid .offset11:first-child { + margin-left: 94.01709401709402%; + *margin-left: 93.91071103837061%; + } + .row-fluid .offset10 { + margin-left: 88.03418803418803%; + *margin-left: 87.92780505546462%; + } + .row-fluid .offset10:first-child { + margin-left: 85.47008547008548%; + *margin-left: 85.36370249136206%; + } + .row-fluid .offset9 { + margin-left: 79.48717948717949%; + *margin-left: 79.38079650845607%; + } + .row-fluid .offset9:first-child { + margin-left: 76.92307692307693%; + *margin-left: 76.81669394435352%; + } + .row-fluid .offset8 { + margin-left: 70.94017094017094%; + *margin-left: 70.83378796144753%; + } + .row-fluid .offset8:first-child { + margin-left: 68.37606837606839%; + *margin-left: 68.26968539734497%; + } + .row-fluid .offset7 { + margin-left: 62.393162393162385%; + *margin-left: 62.28677941443899%; + } + .row-fluid .offset7:first-child { + margin-left: 59.82905982905982%; + *margin-left: 59.72267685033642%; + } + .row-fluid .offset6 { + margin-left: 53.84615384615384%; + *margin-left: 53.739770867430444%; + } + .row-fluid .offset6:first-child { + margin-left: 51.28205128205128%; + *margin-left: 51.175668303327875%; + } + .row-fluid .offset5 { + margin-left: 45.299145299145295%; + *margin-left: 45.1927623204219%; + } + .row-fluid .offset5:first-child { + margin-left: 42.73504273504273%; + *margin-left: 42.62865975631933%; + } + .row-fluid .offset4 { + margin-left: 36.75213675213675%; + *margin-left: 36.645753773413354%; + } + .row-fluid .offset4:first-child { + margin-left: 34.18803418803419%; + *margin-left: 34.081651209310785%; + } + .row-fluid .offset3 { + margin-left: 28.205128205128204%; + *margin-left: 28.0987452264048%; + } + .row-fluid .offset3:first-child { + margin-left: 25.641025641025642%; + *margin-left: 25.53464266230224%; + } + .row-fluid .offset2 { + margin-left: 19.65811965811966%; + *margin-left: 19.551736679396257%; + } + .row-fluid .offset2:first-child { + margin-left: 17.094017094017094%; + *margin-left: 16.98763411529369%; + } + .row-fluid .offset1 { + margin-left: 11.11111111111111%; + *margin-left: 11.004728132387708%; + } + .row-fluid .offset1:first-child { + margin-left: 8.547008547008547%; + *margin-left: 8.440625568285142%; + } + input, + textarea, + .uneditable-input { + margin-left: 0; + } + .controls-row [class*="span"] + [class*="span"] { + margin-left: 30px; + } + input.span12, + textarea.span12, + .uneditable-input.span12 { + width: 1156px; + } + input.span11, + textarea.span11, + .uneditable-input.span11 { + width: 1056px; + } + input.span10, + textarea.span10, + .uneditable-input.span10 { + width: 956px; + } + input.span9, + textarea.span9, + .uneditable-input.span9 { + width: 856px; + } + input.span8, + textarea.span8, + .uneditable-input.span8 { + width: 756px; + } + input.span7, + textarea.span7, + .uneditable-input.span7 { + width: 656px; + } + input.span6, + textarea.span6, + .uneditable-input.span6 { + width: 556px; + } + input.span5, + textarea.span5, + .uneditable-input.span5 { + width: 456px; + } + input.span4, + textarea.span4, + .uneditable-input.span4 { + width: 356px; + } + input.span3, + textarea.span3, + .uneditable-input.span3 { + width: 256px; + } + input.span2, + textarea.span2, + .uneditable-input.span2 { + width: 156px; + } + input.span1, + textarea.span1, + .uneditable-input.span1 { + width: 56px; + } + .thumbnails { + margin-left: -30px; + } + .thumbnails > li { + margin-left: 30px; + } + .row-fluid .thumbnails { + margin-left: 0; + } +} + +@media (min-width: 768px) and (max-width: 979px) { + .row { + margin-left: -20px; + *zoom: 1; + } + .row:before, + .row:after { + display: table; + line-height: 0; + content: ""; + } + .row:after { + clear: both; + } + [class*="span"] { + float: left; + min-height: 1px; + margin-left: 20px; + } + .container, + .navbar-static-top .container, + .navbar-fixed-top .container, + .navbar-fixed-bottom .container { + width: 724px; + } + .span12 { + width: 724px; + } + .span11 { + width: 662px; + } + .span10 { + width: 600px; + } + .span9 { + width: 538px; + } + .span8 { + width: 476px; + } + .span7 { + width: 414px; + } + .span6 { + width: 352px; + } + .span5 { + width: 290px; + } + .span4 { + width: 228px; + } + .span3 { + width: 166px; + } + .span2 { + width: 104px; + } + .span1 { + width: 42px; + } + .offset12 { + margin-left: 764px; + } + .offset11 { + margin-left: 702px; + } + .offset10 { + margin-left: 640px; + } + .offset9 { + margin-left: 578px; + } + .offset8 { + margin-left: 516px; + } + .offset7 { + margin-left: 454px; + } + .offset6 { + margin-left: 392px; + } + .offset5 { + margin-left: 330px; + } + .offset4 { + margin-left: 268px; + } + .offset3 { + margin-left: 206px; + } + .offset2 { + margin-left: 144px; + } + .offset1 { + margin-left: 82px; + } + .row-fluid { + width: 100%; + *zoom: 1; + } + .row-fluid:before, + .row-fluid:after { + display: table; + line-height: 0; + content: ""; + } + .row-fluid:after { + clear: both; + } + .row-fluid [class*="span"] { + display: block; + float: left; + width: 100%; + min-height: 30px; + margin-left: 2.7624309392265194%; + *margin-left: 2.709239449864817%; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + } + .row-fluid [class*="span"]:first-child { + margin-left: 0; + } + .row-fluid .controls-row [class*="span"] + [class*="span"] { + margin-left: 2.7624309392265194%; + } + .row-fluid .span12 { + width: 100%; + *width: 99.94680851063829%; + } + .row-fluid .span11 { + width: 91.43646408839778%; + *width: 91.38327259903608%; + } + .row-fluid .span10 { + width: 82.87292817679558%; + *width: 82.81973668743387%; + } + .row-fluid .span9 { + width: 74.30939226519337%; + *width: 74.25620077583166%; + } + .row-fluid .span8 { + width: 65.74585635359117%; + *width: 65.69266486422946%; + } + .row-fluid .span7 { + width: 57.18232044198895%; + *width: 57.12912895262725%; + } + .row-fluid .span6 { + width: 48.61878453038674%; + *width: 48.56559304102504%; + } + .row-fluid .span5 { + width: 40.05524861878453%; + *width: 40.00205712942283%; + } + .row-fluid .span4 { + width: 31.491712707182323%; + *width: 31.43852121782062%; + } + .row-fluid .span3 { + width: 22.92817679558011%; + *width: 22.87498530621841%; + } + .row-fluid .span2 { + width: 14.3646408839779%; + *width: 14.311449394616199%; + } + .row-fluid .span1 { + width: 5.801104972375691%; + *width: 5.747913483013988%; + } + .row-fluid .offset12 { + margin-left: 105.52486187845304%; + *margin-left: 105.41847889972962%; + } + .row-fluid .offset12:first-child { + margin-left: 102.76243093922652%; + *margin-left: 102.6560479605031%; + } + .row-fluid .offset11 { + margin-left: 96.96132596685082%; + *margin-left: 96.8549429881274%; + } + .row-fluid .offset11:first-child { + margin-left: 94.1988950276243%; + *margin-left: 94.09251204890089%; + } + .row-fluid .offset10 { + margin-left: 88.39779005524862%; + *margin-left: 88.2914070765252%; + } + .row-fluid .offset10:first-child { + margin-left: 85.6353591160221%; + *margin-left: 85.52897613729868%; + } + .row-fluid .offset9 { + margin-left: 79.8342541436464%; + *margin-left: 79.72787116492299%; + } + .row-fluid .offset9:first-child { + margin-left: 77.07182320441989%; + *margin-left: 76.96544022569647%; + } + .row-fluid .offset8 { + margin-left: 71.2707182320442%; + *margin-left: 71.16433525332079%; + } + .row-fluid .offset8:first-child { + margin-left: 68.50828729281768%; + *margin-left: 68.40190431409427%; + } + .row-fluid .offset7 { + margin-left: 62.70718232044199%; + *margin-left: 62.600799341718584%; + } + .row-fluid .offset7:first-child { + margin-left: 59.94475138121547%; + *margin-left: 59.838368402492065%; + } + .row-fluid .offset6 { + margin-left: 54.14364640883978%; + *margin-left: 54.037263430116376%; + } + .row-fluid .offset6:first-child { + margin-left: 51.38121546961326%; + *margin-left: 51.27483249088986%; + } + .row-fluid .offset5 { + margin-left: 45.58011049723757%; + *margin-left: 45.47372751851417%; + } + .row-fluid .offset5:first-child { + margin-left: 42.81767955801105%; + *margin-left: 42.71129657928765%; + } + .row-fluid .offset4 { + margin-left: 37.01657458563536%; + *margin-left: 36.91019160691196%; + } + .row-fluid .offset4:first-child { + margin-left: 34.25414364640884%; + *margin-left: 34.14776066768544%; + } + .row-fluid .offset3 { + margin-left: 28.45303867403315%; + *margin-left: 28.346655695309746%; + } + .row-fluid .offset3:first-child { + margin-left: 25.69060773480663%; + *margin-left: 25.584224756083227%; + } + .row-fluid .offset2 { + margin-left: 19.88950276243094%; + *margin-left: 19.783119783707537%; + } + .row-fluid .offset2:first-child { + margin-left: 17.12707182320442%; + *margin-left: 17.02068884448102%; + } + .row-fluid .offset1 { + margin-left: 11.32596685082873%; + *margin-left: 11.219583872105325%; + } + .row-fluid .offset1:first-child { + margin-left: 8.56353591160221%; + *margin-left: 8.457152932878806%; + } + input, + textarea, + .uneditable-input { + margin-left: 0; + } + .controls-row [class*="span"] + [class*="span"] { + margin-left: 20px; + } + input.span12, + textarea.span12, + .uneditable-input.span12 { + width: 710px; + } + input.span11, + textarea.span11, + .uneditable-input.span11 { + width: 648px; + } + input.span10, + textarea.span10, + .uneditable-input.span10 { + width: 586px; + } + input.span9, + textarea.span9, + .uneditable-input.span9 { + width: 524px; + } + input.span8, + textarea.span8, + .uneditable-input.span8 { + width: 462px; + } + input.span7, + textarea.span7, + .uneditable-input.span7 { + width: 400px; + } + input.span6, + textarea.span6, + .uneditable-input.span6 { + width: 338px; + } + input.span5, + textarea.span5, + .uneditable-input.span5 { + width: 276px; + } + input.span4, + textarea.span4, + .uneditable-input.span4 { + width: 214px; + } + input.span3, + textarea.span3, + .uneditable-input.span3 { + width: 152px; + } + input.span2, + textarea.span2, + .uneditable-input.span2 { + width: 90px; + } + input.span1, + textarea.span1, + .uneditable-input.span1 { + width: 28px; + } +} + +@media (max-width: 767px) { + body { + padding-right: 20px; + padding-left: 20px; + } + .navbar-fixed-top, + .navbar-fixed-bottom, + .navbar-static-top { + margin-right: -20px; + margin-left: -20px; + } + .container-fluid { + padding: 0; + } + .dl-horizontal dt { + float: none; + width: auto; + clear: none; + text-align: left; + } + .dl-horizontal dd { + margin-left: 0; + } + .container { + width: auto; + } + .row-fluid { + width: 100%; + } + .row, + .thumbnails { + margin-left: 0; + } + .thumbnails > li { + float: none; + margin-left: 0; + } + [class*="span"], + .uneditable-input[class*="span"], + .row-fluid [class*="span"] { + display: block; + float: none; + width: 100%; + margin-left: 0; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + } + .span12, + .row-fluid .span12 { + width: 100%; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + } + .row-fluid [class*="offset"]:first-child { + margin-left: 0; + } + .input-large, + .input-xlarge, + .input-xxlarge, + input[class*="span"], + select[class*="span"], + textarea[class*="span"], + .uneditable-input { + display: block; + width: 100%; + min-height: 30px; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + } + .input-prepend input, + .input-append input, + .input-prepend input[class*="span"], + .input-append input[class*="span"] { + display: inline-block; + width: auto; + } + .controls-row [class*="span"] + [class*="span"] { + margin-left: 0; + } + .modal { + position: fixed; + top: 20px; + right: 20px; + left: 20px; + width: auto; + margin: 0; + } + .modal.fade { + top: -100px; + } + .modal.fade.in { + top: 20px; + } +} + +@media (max-width: 480px) { + .nav-collapse { + -webkit-transform: translate3d(0, 0, 0); + } + .page-header h1 small { + display: block; + line-height: 20px; + } + input[type="checkbox"], + input[type="radio"] { + border: 1px solid #ccc; + } + .form-horizontal .control-label { + float: none; + width: auto; + padding-top: 0; + text-align: left; + } + .form-horizontal .controls { + margin-left: 0; + } + .form-horizontal .control-list { + padding-top: 0; + } + .form-horizontal .form-actions { + padding-right: 10px; + padding-left: 10px; + } + .media .pull-left, + .media .pull-right { + display: block; + float: none; + margin-bottom: 10px; + } + .media-object { + margin-right: 0; + margin-left: 0; + } + .modal { + top: 10px; + right: 10px; + left: 10px; + } + .modal-header .close { + padding: 10px; + margin: -10px; + } + .carousel-caption { + position: static; + } +} + +@media (max-width: 979px) { + body { + padding-top: 0; + } + .navbar-fixed-top, + .navbar-fixed-bottom { + position: static; + } + .navbar-fixed-top { + margin-bottom: 20px; + } + .navbar-fixed-bottom { + margin-top: 20px; + } + .navbar-fixed-top .navbar-inner, + .navbar-fixed-bottom .navbar-inner { + padding: 5px; + } + .navbar .container { + width: auto; + padding: 0; + } + .navbar .brand { + padding-right: 10px; + padding-left: 10px; + margin: 0 0 0 -5px; + } + .nav-collapse { + clear: both; + } + .nav-collapse .nav { + float: none; + margin: 0 0 10px; + } + .nav-collapse .nav > li { + float: none; + } + .nav-collapse .nav > li > a { + margin-bottom: 2px; + } + .nav-collapse .nav > .divider-vertical { + display: none; + } + .nav-collapse .nav .nav-header { + color: #777777; + text-shadow: none; + } + .nav-collapse .nav > li > a, + .nav-collapse .dropdown-menu a { + padding: 9px 15px; + font-weight: bold; + color: #777777; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; + } + .nav-collapse .btn { + padding: 4px 10px 4px; + font-weight: normal; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + } + .nav-collapse .dropdown-menu li + li a { + margin-bottom: 2px; + } + .nav-collapse .nav > li > a:hover, + .nav-collapse .dropdown-menu a:hover { + background-color: #f2f2f2; + } + .navbar-inverse .nav-collapse .nav > li > a, + .navbar-inverse .nav-collapse .dropdown-menu a { + color: #999999; + } + .navbar-inverse .nav-collapse .nav > li > a:hover, + .navbar-inverse .nav-collapse .dropdown-menu a:hover { + background-color: #111111; + } + .nav-collapse.in .btn-group { + padding: 0; + margin-top: 5px; + } + .nav-collapse .dropdown-menu { + position: static; + top: auto; + left: auto; + display: none; + float: none; + max-width: none; + padding: 0; + margin: 0 15px; + background-color: transparent; + border: none; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; + -webkit-box-shadow: none; + -moz-box-shadow: none; + box-shadow: none; + } + .nav-collapse .open > .dropdown-menu { + display: block; + } + .nav-collapse .dropdown-menu:before, + .nav-collapse .dropdown-menu:after { + display: none; + } + .nav-collapse .dropdown-menu .divider { + display: none; + } + .nav-collapse .nav > li > .dropdown-menu:before, + .nav-collapse .nav > li > .dropdown-menu:after { + display: none; + } + .nav-collapse .navbar-form, + .nav-collapse .navbar-search { + float: none; + padding: 10px 15px; + margin: 10px 0; + border-top: 1px solid #f2f2f2; + border-bottom: 1px solid #f2f2f2; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + } + .navbar-inverse .nav-collapse .navbar-form, + .navbar-inverse .nav-collapse .navbar-search { + border-top-color: #111111; + border-bottom-color: #111111; + } + .navbar .nav-collapse .nav.pull-right { + float: none; + margin-left: 0; + } + .nav-collapse, + .nav-collapse.collapse { + height: 0; + overflow: hidden; + } + .navbar .btn-navbar { + display: block; + } + .navbar-static .navbar-inner { + padding-right: 10px; + padding-left: 10px; + } +} + +@media (min-width: 980px) { + .nav-collapse.collapse { + height: auto !important; + overflow: visible !important; + } +} diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.min.css b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.min.css new file mode 100644 index 0000000..5cb833f --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap-responsive.min.css @@ -0,0 +1,9 @@ +/*! + * Bootstrap Responsive v2.2.2 + * + * Copyright 2012 Twitter, Inc + * Licensed under the Apache License v2.0 + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Designed and built with all the love in the world @twitter by @mdo and @fat. + */@-ms-viewport{width:device-width}.clearfix{*zoom:1}.clearfix:before,.clearfix:after{display:table;line-height:0;content:""}.clearfix:after{clear:both}.hide-text{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.input-block-level{display:block;width:100%;min-height:30px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.hidden{display:none;visibility:hidden}.visible-phone{display:none!important}.visible-tablet{display:none!important}.hidden-desktop{display:none!important}.visible-desktop{display:inherit!important}@media(min-width:768px) and (max-width:979px){.hidden-desktop{display:inherit!important}.visible-desktop{display:none!important}.visible-tablet{display:inherit!important}.hidden-tablet{display:none!important}}@media(max-width:767px){.hidden-desktop{display:inherit!important}.visible-desktop{display:none!important}.visible-phone{display:inherit!important}.hidden-phone{display:none!important}}@media(min-width:1200px){.row{margin-left:-30px;*zoom:1}.row:before,.row:after{display:table;line-height:0;content:""}.row:after{clear:both}[class*="span"]{float:left;min-height:1px;margin-left:30px}.container,.navbar-static-top .container,.navbar-fixed-top .container,.navbar-fixed-bottom .container{width:1170px}.span12{width:1170px}.span11{width:1070px}.span10{width:970px}.span9{width:870px}.span8{width:770px}.span7{width:670px}.span6{width:570px}.span5{width:470px}.span4{width:370px}.span3{width:270px}.span2{width:170px}.span1{width:70px}.offset12{margin-left:1230px}.offset11{margin-left:1130px}.offset10{margin-left:1030px}.offset9{margin-left:930px}.offset8{margin-left:830px}.offset7{margin-left:730px}.offset6{margin-left:630px}.offset5{margin-left:530px}.offset4{margin-left:430px}.offset3{margin-left:330px}.offset2{margin-left:230px}.offset1{margin-left:130px}.row-fluid{width:100%;*zoom:1}.row-fluid:before,.row-fluid:after{display:table;line-height:0;content:""}.row-fluid:after{clear:both}.row-fluid [class*="span"]{display:block;float:left;width:100%;min-height:30px;margin-left:2.564102564102564%;*margin-left:2.5109110747408616%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.row-fluid [class*="span"]:first-child{margin-left:0}.row-fluid .controls-row [class*="span"]+[class*="span"]{margin-left:2.564102564102564%}.row-fluid .span12{width:100%;*width:99.94680851063829%}.row-fluid .span11{width:91.45299145299145%;*width:91.39979996362975%}.row-fluid .span10{width:82.90598290598291%;*width:82.8527914166212%}.row-fluid .span9{width:74.35897435897436%;*width:74.30578286961266%}.row-fluid .span8{width:65.81196581196582%;*width:65.75877432260411%}.row-fluid .span7{width:57.26495726495726%;*width:57.21176577559556%}.row-fluid .span6{width:48.717948717948715%;*width:48.664757228587014%}.row-fluid .span5{width:40.17094017094017%;*width:40.11774868157847%}.row-fluid .span4{width:31.623931623931625%;*width:31.570740134569924%}.row-fluid .span3{width:23.076923076923077%;*width:23.023731587561375%}.row-fluid .span2{width:14.52991452991453%;*width:14.476723040552828%}.row-fluid .span1{width:5.982905982905983%;*width:5.929714493544281%}.row-fluid .offset12{margin-left:105.12820512820512%;*margin-left:105.02182214948171%}.row-fluid .offset12:first-child{margin-left:102.56410256410257%;*margin-left:102.45771958537915%}.row-fluid .offset11{margin-left:96.58119658119658%;*margin-left:96.47481360247316%}.row-fluid .offset11:first-child{margin-left:94.01709401709402%;*margin-left:93.91071103837061%}.row-fluid .offset10{margin-left:88.03418803418803%;*margin-left:87.92780505546462%}.row-fluid .offset10:first-child{margin-left:85.47008547008548%;*margin-left:85.36370249136206%}.row-fluid .offset9{margin-left:79.48717948717949%;*margin-left:79.38079650845607%}.row-fluid .offset9:first-child{margin-left:76.92307692307693%;*margin-left:76.81669394435352%}.row-fluid .offset8{margin-left:70.94017094017094%;*margin-left:70.83378796144753%}.row-fluid .offset8:first-child{margin-left:68.37606837606839%;*margin-left:68.26968539734497%}.row-fluid .offset7{margin-left:62.393162393162385%;*margin-left:62.28677941443899%}.row-fluid .offset7:first-child{margin-left:59.82905982905982%;*margin-left:59.72267685033642%}.row-fluid .offset6{margin-left:53.84615384615384%;*margin-left:53.739770867430444%}.row-fluid .offset6:first-child{margin-left:51.28205128205128%;*margin-left:51.175668303327875%}.row-fluid .offset5{margin-left:45.299145299145295%;*margin-left:45.1927623204219%}.row-fluid .offset5:first-child{margin-left:42.73504273504273%;*margin-left:42.62865975631933%}.row-fluid .offset4{margin-left:36.75213675213675%;*margin-left:36.645753773413354%}.row-fluid .offset4:first-child{margin-left:34.18803418803419%;*margin-left:34.081651209310785%}.row-fluid .offset3{margin-left:28.205128205128204%;*margin-left:28.0987452264048%}.row-fluid .offset3:first-child{margin-left:25.641025641025642%;*margin-left:25.53464266230224%}.row-fluid .offset2{margin-left:19.65811965811966%;*margin-left:19.551736679396257%}.row-fluid .offset2:first-child{margin-left:17.094017094017094%;*margin-left:16.98763411529369%}.row-fluid .offset1{margin-left:11.11111111111111%;*margin-left:11.004728132387708%}.row-fluid .offset1:first-child{margin-left:8.547008547008547%;*margin-left:8.440625568285142%}input,textarea,.uneditable-input{margin-left:0}.controls-row [class*="span"]+[class*="span"]{margin-left:30px}input.span12,textarea.span12,.uneditable-input.span12{width:1156px}input.span11,textarea.span11,.uneditable-input.span11{width:1056px}input.span10,textarea.span10,.uneditable-input.span10{width:956px}input.span9,textarea.span9,.uneditable-input.span9{width:856px}input.span8,textarea.span8,.uneditable-input.span8{width:756px}input.span7,textarea.span7,.uneditable-input.span7{width:656px}input.span6,textarea.span6,.uneditable-input.span6{width:556px}input.span5,textarea.span5,.uneditable-input.span5{width:456px}input.span4,textarea.span4,.uneditable-input.span4{width:356px}input.span3,textarea.span3,.uneditable-input.span3{width:256px}input.span2,textarea.span2,.uneditable-input.span2{width:156px}input.span1,textarea.span1,.uneditable-input.span1{width:56px}.thumbnails{margin-left:-30px}.thumbnails>li{margin-left:30px}.row-fluid .thumbnails{margin-left:0}}@media(min-width:768px) and (max-width:979px){.row{margin-left:-20px;*zoom:1}.row:before,.row:after{display:table;line-height:0;content:""}.row:after{clear:both}[class*="span"]{float:left;min-height:1px;margin-left:20px}.container,.navbar-static-top .container,.navbar-fixed-top .container,.navbar-fixed-bottom .container{width:724px}.span12{width:724px}.span11{width:662px}.span10{width:600px}.span9{width:538px}.span8{width:476px}.span7{width:414px}.span6{width:352px}.span5{width:290px}.span4{width:228px}.span3{width:166px}.span2{width:104px}.span1{width:42px}.offset12{margin-left:764px}.offset11{margin-left:702px}.offset10{margin-left:640px}.offset9{margin-left:578px}.offset8{margin-left:516px}.offset7{margin-left:454px}.offset6{margin-left:392px}.offset5{margin-left:330px}.offset4{margin-left:268px}.offset3{margin-left:206px}.offset2{margin-left:144px}.offset1{margin-left:82px}.row-fluid{width:100%;*zoom:1}.row-fluid:before,.row-fluid:after{display:table;line-height:0;content:""}.row-fluid:after{clear:both}.row-fluid [class*="span"]{display:block;float:left;width:100%;min-height:30px;margin-left:2.7624309392265194%;*margin-left:2.709239449864817%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.row-fluid [class*="span"]:first-child{margin-left:0}.row-fluid .controls-row [class*="span"]+[class*="span"]{margin-left:2.7624309392265194%}.row-fluid .span12{width:100%;*width:99.94680851063829%}.row-fluid .span11{width:91.43646408839778%;*width:91.38327259903608%}.row-fluid .span10{width:82.87292817679558%;*width:82.81973668743387%}.row-fluid .span9{width:74.30939226519337%;*width:74.25620077583166%}.row-fluid .span8{width:65.74585635359117%;*width:65.69266486422946%}.row-fluid .span7{width:57.18232044198895%;*width:57.12912895262725%}.row-fluid .span6{width:48.61878453038674%;*width:48.56559304102504%}.row-fluid .span5{width:40.05524861878453%;*width:40.00205712942283%}.row-fluid .span4{width:31.491712707182323%;*width:31.43852121782062%}.row-fluid .span3{width:22.92817679558011%;*width:22.87498530621841%}.row-fluid .span2{width:14.3646408839779%;*width:14.311449394616199%}.row-fluid .span1{width:5.801104972375691%;*width:5.747913483013988%}.row-fluid .offset12{margin-left:105.52486187845304%;*margin-left:105.41847889972962%}.row-fluid .offset12:first-child{margin-left:102.76243093922652%;*margin-left:102.6560479605031%}.row-fluid .offset11{margin-left:96.96132596685082%;*margin-left:96.8549429881274%}.row-fluid .offset11:first-child{margin-left:94.1988950276243%;*margin-left:94.09251204890089%}.row-fluid .offset10{margin-left:88.39779005524862%;*margin-left:88.2914070765252%}.row-fluid .offset10:first-child{margin-left:85.6353591160221%;*margin-left:85.52897613729868%}.row-fluid .offset9{margin-left:79.8342541436464%;*margin-left:79.72787116492299%}.row-fluid .offset9:first-child{margin-left:77.07182320441989%;*margin-left:76.96544022569647%}.row-fluid .offset8{margin-left:71.2707182320442%;*margin-left:71.16433525332079%}.row-fluid .offset8:first-child{margin-left:68.50828729281768%;*margin-left:68.40190431409427%}.row-fluid .offset7{margin-left:62.70718232044199%;*margin-left:62.600799341718584%}.row-fluid .offset7:first-child{margin-left:59.94475138121547%;*margin-left:59.838368402492065%}.row-fluid .offset6{margin-left:54.14364640883978%;*margin-left:54.037263430116376%}.row-fluid .offset6:first-child{margin-left:51.38121546961326%;*margin-left:51.27483249088986%}.row-fluid .offset5{margin-left:45.58011049723757%;*margin-left:45.47372751851417%}.row-fluid .offset5:first-child{margin-left:42.81767955801105%;*margin-left:42.71129657928765%}.row-fluid .offset4{margin-left:37.01657458563536%;*margin-left:36.91019160691196%}.row-fluid .offset4:first-child{margin-left:34.25414364640884%;*margin-left:34.14776066768544%}.row-fluid .offset3{margin-left:28.45303867403315%;*margin-left:28.346655695309746%}.row-fluid .offset3:first-child{margin-left:25.69060773480663%;*margin-left:25.584224756083227%}.row-fluid .offset2{margin-left:19.88950276243094%;*margin-left:19.783119783707537%}.row-fluid .offset2:first-child{margin-left:17.12707182320442%;*margin-left:17.02068884448102%}.row-fluid .offset1{margin-left:11.32596685082873%;*margin-left:11.219583872105325%}.row-fluid .offset1:first-child{margin-left:8.56353591160221%;*margin-left:8.457152932878806%}input,textarea,.uneditable-input{margin-left:0}.controls-row [class*="span"]+[class*="span"]{margin-left:20px}input.span12,textarea.span12,.uneditable-input.span12{width:710px}input.span11,textarea.span11,.uneditable-input.span11{width:648px}input.span10,textarea.span10,.uneditable-input.span10{width:586px}input.span9,textarea.span9,.uneditable-input.span9{width:524px}input.span8,textarea.span8,.uneditable-input.span8{width:462px}input.span7,textarea.span7,.uneditable-input.span7{width:400px}input.span6,textarea.span6,.uneditable-input.span6{width:338px}input.span5,textarea.span5,.uneditable-input.span5{width:276px}input.span4,textarea.span4,.uneditable-input.span4{width:214px}input.span3,textarea.span3,.uneditable-input.span3{width:152px}input.span2,textarea.span2,.uneditable-input.span2{width:90px}input.span1,textarea.span1,.uneditable-input.span1{width:28px}}@media(max-width:767px){body{padding-right:20px;padding-left:20px}.navbar-fixed-top,.navbar-fixed-bottom,.navbar-static-top{margin-right:-20px;margin-left:-20px}.container-fluid{padding:0}.dl-horizontal dt{float:none;width:auto;clear:none;text-align:left}.dl-horizontal dd{margin-left:0}.container{width:auto}.row-fluid{width:100%}.row,.thumbnails{margin-left:0}.thumbnails>li{float:none;margin-left:0}[class*="span"],.uneditable-input[class*="span"],.row-fluid [class*="span"]{display:block;float:none;width:100%;margin-left:0;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.span12,.row-fluid .span12{width:100%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.row-fluid [class*="offset"]:first-child{margin-left:0}.input-large,.input-xlarge,.input-xxlarge,input[class*="span"],select[class*="span"],textarea[class*="span"],.uneditable-input{display:block;width:100%;min-height:30px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.input-prepend input,.input-append input,.input-prepend input[class*="span"],.input-append input[class*="span"]{display:inline-block;width:auto}.controls-row [class*="span"]+[class*="span"]{margin-left:0}.modal{position:fixed;top:20px;right:20px;left:20px;width:auto;margin:0}.modal.fade{top:-100px}.modal.fade.in{top:20px}}@media(max-width:480px){.nav-collapse{-webkit-transform:translate3d(0,0,0)}.page-header h1 small{display:block;line-height:20px}input[type="checkbox"],input[type="radio"]{border:1px solid #ccc}.form-horizontal .control-label{float:none;width:auto;padding-top:0;text-align:left}.form-horizontal .controls{margin-left:0}.form-horizontal .control-list{padding-top:0}.form-horizontal .form-actions{padding-right:10px;padding-left:10px}.media .pull-left,.media .pull-right{display:block;float:none;margin-bottom:10px}.media-object{margin-right:0;margin-left:0}.modal{top:10px;right:10px;left:10px}.modal-header .close{padding:10px;margin:-10px}.carousel-caption{position:static}}@media(max-width:979px){body{padding-top:0}.navbar-fixed-top,.navbar-fixed-bottom{position:static}.navbar-fixed-top{margin-bottom:20px}.navbar-fixed-bottom{margin-top:20px}.navbar-fixed-top .navbar-inner,.navbar-fixed-bottom .navbar-inner{padding:5px}.navbar .container{width:auto;padding:0}.navbar .brand{padding-right:10px;padding-left:10px;margin:0 0 0 -5px}.nav-collapse{clear:both}.nav-collapse .nav{float:none;margin:0 0 10px}.nav-collapse .nav>li{float:none}.nav-collapse .nav>li>a{margin-bottom:2px}.nav-collapse .nav>.divider-vertical{display:none}.nav-collapse .nav .nav-header{color:#777;text-shadow:none}.nav-collapse .nav>li>a,.nav-collapse .dropdown-menu a{padding:9px 15px;font-weight:bold;color:#777;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}.nav-collapse .btn{padding:4px 10px 4px;font-weight:normal;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.nav-collapse .dropdown-menu li+li a{margin-bottom:2px}.nav-collapse .nav>li>a:hover,.nav-collapse .dropdown-menu a:hover{background-color:#f2f2f2}.navbar-inverse .nav-collapse .nav>li>a,.navbar-inverse .nav-collapse .dropdown-menu a{color:#999}.navbar-inverse .nav-collapse .nav>li>a:hover,.navbar-inverse .nav-collapse .dropdown-menu a:hover{background-color:#111}.nav-collapse.in .btn-group{padding:0;margin-top:5px}.nav-collapse .dropdown-menu{position:static;top:auto;left:auto;display:none;float:none;max-width:none;padding:0;margin:0 15px;background-color:transparent;border:0;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.nav-collapse .open>.dropdown-menu{display:block}.nav-collapse .dropdown-menu:before,.nav-collapse .dropdown-menu:after{display:none}.nav-collapse .dropdown-menu .divider{display:none}.nav-collapse .nav>li>.dropdown-menu:before,.nav-collapse .nav>li>.dropdown-menu:after{display:none}.nav-collapse .navbar-form,.nav-collapse .navbar-search{float:none;padding:10px 15px;margin:10px 0;border-top:1px solid #f2f2f2;border-bottom:1px solid #f2f2f2;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1);-moz-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1);box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1)}.navbar-inverse .nav-collapse .navbar-form,.navbar-inverse .nav-collapse .navbar-search{border-top-color:#111;border-bottom-color:#111}.navbar .nav-collapse .nav.pull-right{float:none;margin-left:0}.nav-collapse,.nav-collapse.collapse{height:0;overflow:hidden}.navbar .btn-navbar{display:block}.navbar-static .navbar-inner{padding-right:10px;padding-left:10px}}@media(min-width:980px){.nav-collapse.collapse{height:auto!important;overflow:visible!important}} diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.css b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.css new file mode 100644 index 0000000..8ab3cef --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.css @@ -0,0 +1,6039 @@ +/*! + * Bootstrap v2.2.2 + * + * Copyright 2012 Twitter, Inc + * Licensed under the Apache License v2.0 + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Designed and built with all the love in the world @twitter by @mdo and @fat. + */ + +article, +aside, +details, +figcaption, +figure, +footer, +header, +hgroup, +nav, +section { + display: block; +} + +audio, +canvas, +video { + display: inline-block; + *display: inline; + *zoom: 1; +} + +audio:not([controls]) { + display: none; +} + +html { + font-size: 100%; + -webkit-text-size-adjust: 100%; + -ms-text-size-adjust: 100%; +} + +a:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +a:hover, +a:active { + outline: 0; +} + +sub, +sup { + position: relative; + font-size: 75%; + line-height: 0; + vertical-align: baseline; +} + +sup { + top: -0.5em; +} + +sub { + bottom: -0.25em; +} + +img { + width: auto\9; + height: auto; + max-width: 100%; + vertical-align: middle; + border: 0; + -ms-interpolation-mode: bicubic; +} + +#map_canvas img, +.google-maps img { + max-width: none; +} + +button, +input, +select, +textarea { + margin: 0; + font-size: 100%; + vertical-align: middle; +} + +button, +input { + *overflow: visible; + line-height: normal; +} + +button::-moz-focus-inner, +input::-moz-focus-inner { + padding: 0; + border: 0; +} + +button, +html input[type="button"], +input[type="reset"], +input[type="submit"] { + cursor: pointer; + -webkit-appearance: button; +} + +label, +select, +button, +input[type="button"], +input[type="reset"], +input[type="submit"], +input[type="radio"], +input[type="checkbox"] { + cursor: pointer; +} + +input[type="search"] { + -webkit-box-sizing: content-box; + -moz-box-sizing: content-box; + box-sizing: content-box; + -webkit-appearance: textfield; +} + +input[type="search"]::-webkit-search-decoration, +input[type="search"]::-webkit-search-cancel-button { + -webkit-appearance: none; +} + +textarea { + overflow: auto; + vertical-align: top; +} + +@media print { + * { + color: #000 !important; + text-shadow: none !important; + background: transparent !important; + box-shadow: none !important; + } + a, + a:visited { + text-decoration: underline; + } + a[href]:after { + content: " (" attr(href) ")"; + } + abbr[title]:after { + content: " (" attr(title) ")"; + } + .ir a:after, + a[href^="javascript:"]:after, + a[href^="#"]:after { + content: ""; + } + pre, + blockquote { + border: 1px solid #999; + page-break-inside: avoid; + } + thead { + display: table-header-group; + } + tr, + img { + page-break-inside: avoid; + } + img { + max-width: 100% !important; + } + @page { + margin: 0.5cm; + } + p, + h2, + h3 { + orphans: 3; + widows: 3; + } + h2, + h3 { + page-break-after: avoid; + } +} + +.clearfix { + *zoom: 1; +} + +.clearfix:before, +.clearfix:after { + display: table; + line-height: 0; + content: ""; +} + +.clearfix:after { + clear: both; +} + +.hide-text { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; +} + +.input-block-level { + display: block; + width: 100%; + min-height: 30px; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +body { + margin: 0; + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 14px; + line-height: 20px; + color: #333333; + background-color: #ffffff; +} + +a { + color: #0088cc; + text-decoration: none; +} + +a:hover { + color: #005580; + text-decoration: underline; +} + +.img-rounded { + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; +} + +.img-polaroid { + padding: 4px; + background-color: #fff; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.2); + -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); + -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); +} + +.img-circle { + -webkit-border-radius: 500px; + -moz-border-radius: 500px; + border-radius: 500px; +} + +.row { + margin-left: -20px; + *zoom: 1; +} + +.row:before, +.row:after { + display: table; + line-height: 0; + content: ""; +} + +.row:after { + clear: both; +} + +[class*="span"] { + float: left; + min-height: 1px; + margin-left: 20px; +} + +.container, +.navbar-static-top .container, +.navbar-fixed-top .container, +.navbar-fixed-bottom .container { + width: 940px; +} + +.span12 { + width: 940px; +} + +.span11 { + width: 860px; +} + +.span10 { + width: 780px; +} + +.span9 { + width: 700px; +} + +.span8 { + width: 620px; +} + +.span7 { + width: 540px; +} + +.span6 { + width: 460px; +} + +.span5 { + width: 380px; +} + +.span4 { + width: 300px; +} + +.span3 { + width: 220px; +} + +.span2 { + width: 140px; +} + +.span1 { + width: 60px; +} + +.offset12 { + margin-left: 980px; +} + +.offset11 { + margin-left: 900px; +} + +.offset10 { + margin-left: 820px; +} + +.offset9 { + margin-left: 740px; +} + +.offset8 { + margin-left: 660px; +} + +.offset7 { + margin-left: 580px; +} + +.offset6 { + margin-left: 500px; +} + +.offset5 { + margin-left: 420px; +} + +.offset4 { + margin-left: 340px; +} + +.offset3 { + margin-left: 260px; +} + +.offset2 { + margin-left: 180px; +} + +.offset1 { + margin-left: 100px; +} + +.row-fluid { + width: 100%; + *zoom: 1; +} + +.row-fluid:before, +.row-fluid:after { + display: table; + line-height: 0; + content: ""; +} + +.row-fluid:after { + clear: both; +} + +.row-fluid [class*="span"] { + display: block; + float: left; + width: 100%; + min-height: 30px; + margin-left: 2.127659574468085%; + *margin-left: 2.074468085106383%; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +.row-fluid [class*="span"]:first-child { + margin-left: 0; +} + +.row-fluid .controls-row [class*="span"] + [class*="span"] { + margin-left: 2.127659574468085%; +} + +.row-fluid .span12 { + width: 100%; + *width: 99.94680851063829%; +} + +.row-fluid .span11 { + width: 91.48936170212765%; + *width: 91.43617021276594%; +} + +.row-fluid .span10 { + width: 82.97872340425532%; + *width: 82.92553191489361%; +} + +.row-fluid .span9 { + width: 74.46808510638297%; + *width: 74.41489361702126%; +} + +.row-fluid .span8 { + width: 65.95744680851064%; + *width: 65.90425531914893%; +} + +.row-fluid .span7 { + width: 57.44680851063829%; + *width: 57.39361702127659%; +} + +.row-fluid .span6 { + width: 48.93617021276595%; + *width: 48.88297872340425%; +} + +.row-fluid .span5 { + width: 40.42553191489362%; + *width: 40.37234042553192%; +} + +.row-fluid .span4 { + width: 31.914893617021278%; + *width: 31.861702127659576%; +} + +.row-fluid .span3 { + width: 23.404255319148934%; + *width: 23.351063829787233%; +} + +.row-fluid .span2 { + width: 14.893617021276595%; + *width: 14.840425531914894%; +} + +.row-fluid .span1 { + width: 6.382978723404255%; + *width: 6.329787234042553%; +} + +.row-fluid .offset12 { + margin-left: 104.25531914893617%; + *margin-left: 104.14893617021275%; +} + +.row-fluid .offset12:first-child { + margin-left: 102.12765957446808%; + *margin-left: 102.02127659574467%; +} + +.row-fluid .offset11 { + margin-left: 95.74468085106382%; + *margin-left: 95.6382978723404%; +} + +.row-fluid .offset11:first-child { + margin-left: 93.61702127659574%; + *margin-left: 93.51063829787232%; +} + +.row-fluid .offset10 { + margin-left: 87.23404255319149%; + *margin-left: 87.12765957446807%; +} + +.row-fluid .offset10:first-child { + margin-left: 85.1063829787234%; + *margin-left: 84.99999999999999%; +} + +.row-fluid .offset9 { + margin-left: 78.72340425531914%; + *margin-left: 78.61702127659572%; +} + +.row-fluid .offset9:first-child { + margin-left: 76.59574468085106%; + *margin-left: 76.48936170212764%; +} + +.row-fluid .offset8 { + margin-left: 70.2127659574468%; + *margin-left: 70.10638297872339%; +} + +.row-fluid .offset8:first-child { + margin-left: 68.08510638297872%; + *margin-left: 67.9787234042553%; +} + +.row-fluid .offset7 { + margin-left: 61.70212765957446%; + *margin-left: 61.59574468085106%; +} + +.row-fluid .offset7:first-child { + margin-left: 59.574468085106375%; + *margin-left: 59.46808510638297%; +} + +.row-fluid .offset6 { + margin-left: 53.191489361702125%; + *margin-left: 53.085106382978715%; +} + +.row-fluid .offset6:first-child { + margin-left: 51.063829787234035%; + *margin-left: 50.95744680851063%; +} + +.row-fluid .offset5 { + margin-left: 44.68085106382979%; + *margin-left: 44.57446808510638%; +} + +.row-fluid .offset5:first-child { + margin-left: 42.5531914893617%; + *margin-left: 42.4468085106383%; +} + +.row-fluid .offset4 { + margin-left: 36.170212765957444%; + *margin-left: 36.06382978723405%; +} + +.row-fluid .offset4:first-child { + margin-left: 34.04255319148936%; + *margin-left: 33.93617021276596%; +} + +.row-fluid .offset3 { + margin-left: 27.659574468085104%; + *margin-left: 27.5531914893617%; +} + +.row-fluid .offset3:first-child { + margin-left: 25.53191489361702%; + *margin-left: 25.425531914893618%; +} + +.row-fluid .offset2 { + margin-left: 19.148936170212764%; + *margin-left: 19.04255319148936%; +} + +.row-fluid .offset2:first-child { + margin-left: 17.02127659574468%; + *margin-left: 16.914893617021278%; +} + +.row-fluid .offset1 { + margin-left: 10.638297872340425%; + *margin-left: 10.53191489361702%; +} + +.row-fluid .offset1:first-child { + margin-left: 8.51063829787234%; + *margin-left: 8.404255319148938%; +} + +[class*="span"].hide, +.row-fluid [class*="span"].hide { + display: none; +} + +[class*="span"].pull-right, +.row-fluid [class*="span"].pull-right { + float: right; +} + +.container { + margin-right: auto; + margin-left: auto; + *zoom: 1; +} + +.container:before, +.container:after { + display: table; + line-height: 0; + content: ""; +} + +.container:after { + clear: both; +} + +.container-fluid { + padding-right: 20px; + padding-left: 20px; + *zoom: 1; +} + +.container-fluid:before, +.container-fluid:after { + display: table; + line-height: 0; + content: ""; +} + +.container-fluid:after { + clear: both; +} + +p { + margin: 0 0 10px; +} + +.lead { + margin-bottom: 20px; + font-size: 21px; + font-weight: 200; + line-height: 30px; +} + +small { + font-size: 85%; +} + +strong { + font-weight: bold; +} + +em { + font-style: italic; +} + +cite { + font-style: normal; +} + +.muted { + color: #999999; +} + +a.muted:hover { + color: #808080; +} + +.text-warning { + color: #c09853; +} + +a.text-warning:hover { + color: #a47e3c; +} + +.text-error { + color: #b94a48; +} + +a.text-error:hover { + color: #953b39; +} + +.text-info { + color: #3a87ad; +} + +a.text-info:hover { + color: #2d6987; +} + +.text-success { + color: #468847; +} + +a.text-success:hover { + color: #356635; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + margin: 10px 0; + font-family: inherit; + font-weight: bold; + line-height: 20px; + color: inherit; + text-rendering: optimizelegibility; +} + +h1 small, +h2 small, +h3 small, +h4 small, +h5 small, +h6 small { + font-weight: normal; + line-height: 1; + color: #999999; +} + +h1, +h2, +h3 { + line-height: 40px; +} + +h1 { + font-size: 38.5px; +} + +h2 { + font-size: 31.5px; +} + +h3 { + font-size: 24.5px; +} + +h4 { + font-size: 17.5px; +} + +h5 { + font-size: 14px; +} + +h6 { + font-size: 11.9px; +} + +h1 small { + font-size: 24.5px; +} + +h2 small { + font-size: 17.5px; +} + +h3 small { + font-size: 14px; +} + +h4 small { + font-size: 14px; +} + +.page-header { + padding-bottom: 9px; + margin: 20px 0 30px; + border-bottom: 1px solid #eeeeee; +} + +ul, +ol { + padding: 0; + margin: 0 0 10px 25px; +} + +ul ul, +ul ol, +ol ol, +ol ul { + margin-bottom: 0; +} + +li { + line-height: 20px; +} + +ul.unstyled, +ol.unstyled { + margin-left: 0; + list-style: none; +} + +ul.inline, +ol.inline { + margin-left: 0; + list-style: none; +} + +ul.inline > li, +ol.inline > li { + display: inline-block; + padding-right: 5px; + padding-left: 5px; +} + +dl { + margin-bottom: 20px; +} + +dt, +dd { + line-height: 20px; +} + +dt { + font-weight: bold; +} + +dd { + margin-left: 10px; +} + +.dl-horizontal { + *zoom: 1; +} + +.dl-horizontal:before, +.dl-horizontal:after { + display: table; + line-height: 0; + content: ""; +} + +.dl-horizontal:after { + clear: both; +} + +.dl-horizontal dt { + float: left; + width: 160px; + overflow: hidden; + clear: left; + text-align: right; + text-overflow: ellipsis; + white-space: nowrap; +} + +.dl-horizontal dd { + margin-left: 180px; +} + +hr { + margin: 20px 0; + border: 0; + border-top: 1px solid #eeeeee; + border-bottom: 1px solid #ffffff; +} + +abbr[title], +abbr[data-original-title] { + cursor: help; + border-bottom: 1px dotted #999999; +} + +abbr.initialism { + font-size: 90%; + text-transform: uppercase; +} + +blockquote { + padding: 0 0 0 15px; + margin: 0 0 20px; + border-left: 5px solid #eeeeee; +} + +blockquote p { + margin-bottom: 0; + font-size: 16px; + font-weight: 300; + line-height: 25px; +} + +blockquote small { + display: block; + line-height: 20px; + color: #999999; +} + +blockquote small:before { + content: '\2014 \00A0'; +} + +blockquote.pull-right { + float: right; + padding-right: 15px; + padding-left: 0; + border-right: 5px solid #eeeeee; + border-left: 0; +} + +blockquote.pull-right p, +blockquote.pull-right small { + text-align: right; +} + +blockquote.pull-right small:before { + content: ''; +} + +blockquote.pull-right small:after { + content: '\00A0 \2014'; +} + +q:before, +q:after, +blockquote:before, +blockquote:after { + content: ""; +} + +address { + display: block; + margin-bottom: 20px; + font-style: normal; + line-height: 20px; +} + +code, +pre { + padding: 0 3px 2px; + font-family: Monaco, Menlo, Consolas, "Courier New", monospace; + font-size: 12px; + color: #333333; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; +} + +code { + padding: 2px 4px; + color: #d14; + white-space: nowrap; + background-color: #f7f7f9; + border: 1px solid #e1e1e8; +} + +pre { + display: block; + padding: 9.5px; + margin: 0 0 10px; + font-size: 13px; + line-height: 20px; + word-break: break-all; + word-wrap: break-word; + white-space: pre; + white-space: pre-wrap; + background-color: #f5f5f5; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.15); + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +pre.prettyprint { + margin-bottom: 20px; +} + +pre code { + padding: 0; + color: inherit; + white-space: pre; + white-space: pre-wrap; + background-color: transparent; + border: 0; +} + +.pre-scrollable { + max-height: 340px; + overflow-y: scroll; +} + +form { + margin: 0 0 20px; +} + +fieldset { + padding: 0; + margin: 0; + border: 0; +} + +legend { + display: block; + width: 100%; + padding: 0; + margin-bottom: 20px; + font-size: 21px; + line-height: 40px; + color: #333333; + border: 0; + border-bottom: 1px solid #e5e5e5; +} + +legend small { + font-size: 15px; + color: #999999; +} + +label, +input, +button, +select, +textarea { + font-size: 14px; + font-weight: normal; + line-height: 20px; +} + +input, +button, +select, +textarea { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; +} + +label { + display: block; + margin-bottom: 5px; +} + +select, +textarea, +input[type="text"], +input[type="password"], +input[type="datetime"], +input[type="datetime-local"], +input[type="date"], +input[type="month"], +input[type="time"], +input[type="week"], +input[type="number"], +input[type="email"], +input[type="url"], +input[type="search"], +input[type="tel"], +input[type="color"], +.uneditable-input { + display: inline-block; + height: 20px; + padding: 4px 6px; + margin-bottom: 10px; + font-size: 14px; + line-height: 20px; + color: #555555; + vertical-align: middle; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +input, +textarea, +.uneditable-input { + width: 206px; +} + +textarea { + height: auto; +} + +textarea, +input[type="text"], +input[type="password"], +input[type="datetime"], +input[type="datetime-local"], +input[type="date"], +input[type="month"], +input[type="time"], +input[type="week"], +input[type="number"], +input[type="email"], +input[type="url"], +input[type="search"], +input[type="tel"], +input[type="color"], +.uneditable-input { + background-color: #ffffff; + border: 1px solid #cccccc; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -webkit-transition: border linear 0.2s, box-shadow linear 0.2s; + -moz-transition: border linear 0.2s, box-shadow linear 0.2s; + -o-transition: border linear 0.2s, box-shadow linear 0.2s; + transition: border linear 0.2s, box-shadow linear 0.2s; +} + +textarea:focus, +input[type="text"]:focus, +input[type="password"]:focus, +input[type="datetime"]:focus, +input[type="datetime-local"]:focus, +input[type="date"]:focus, +input[type="month"]:focus, +input[type="time"]:focus, +input[type="week"]:focus, +input[type="number"]:focus, +input[type="email"]:focus, +input[type="url"]:focus, +input[type="search"]:focus, +input[type="tel"]:focus, +input[type="color"]:focus, +.uneditable-input:focus { + border-color: rgba(82, 168, 236, 0.8); + outline: 0; + outline: thin dotted \9; + /* IE6-9 */ + + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); +} + +input[type="radio"], +input[type="checkbox"] { + margin: 4px 0 0; + margin-top: 1px \9; + *margin-top: 0; + line-height: normal; +} + +input[type="file"], +input[type="image"], +input[type="submit"], +input[type="reset"], +input[type="button"], +input[type="radio"], +input[type="checkbox"] { + width: auto; +} + +select, +input[type="file"] { + height: 30px; + /* In IE7, the height of the select element cannot be changed by height, only font-size */ + + *margin-top: 4px; + /* For IE7, add top margin to align select with labels */ + + line-height: 30px; +} + +select { + width: 220px; + background-color: #ffffff; + border: 1px solid #cccccc; +} + +select[multiple], +select[size] { + height: auto; +} + +select:focus, +input[type="file"]:focus, +input[type="radio"]:focus, +input[type="checkbox"]:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +.uneditable-input, +.uneditable-textarea { + color: #999999; + cursor: not-allowed; + background-color: #fcfcfc; + border-color: #cccccc; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); + -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); +} + +.uneditable-input { + overflow: hidden; + white-space: nowrap; +} + +.uneditable-textarea { + width: auto; + height: auto; +} + +input:-moz-placeholder, +textarea:-moz-placeholder { + color: #999999; +} + +input:-ms-input-placeholder, +textarea:-ms-input-placeholder { + color: #999999; +} + +input::-webkit-input-placeholder, +textarea::-webkit-input-placeholder { + color: #999999; +} + +.radio, +.checkbox { + min-height: 20px; + padding-left: 20px; +} + +.radio input[type="radio"], +.checkbox input[type="checkbox"] { + float: left; + margin-left: -20px; +} + +.controls > .radio:first-child, +.controls > .checkbox:first-child { + padding-top: 5px; +} + +.radio.inline, +.checkbox.inline { + display: inline-block; + padding-top: 5px; + margin-bottom: 0; + vertical-align: middle; +} + +.radio.inline + .radio.inline, +.checkbox.inline + .checkbox.inline { + margin-left: 10px; +} + +.input-mini { + width: 60px; +} + +.input-small { + width: 90px; +} + +.input-medium { + width: 150px; +} + +.input-large { + width: 210px; +} + +.input-xlarge { + width: 270px; +} + +.input-xxlarge { + width: 530px; +} + +input[class*="span"], +select[class*="span"], +textarea[class*="span"], +.uneditable-input[class*="span"], +.row-fluid input[class*="span"], +.row-fluid select[class*="span"], +.row-fluid textarea[class*="span"], +.row-fluid .uneditable-input[class*="span"] { + float: none; + margin-left: 0; +} + +.input-append input[class*="span"], +.input-append .uneditable-input[class*="span"], +.input-prepend input[class*="span"], +.input-prepend .uneditable-input[class*="span"], +.row-fluid input[class*="span"], +.row-fluid select[class*="span"], +.row-fluid textarea[class*="span"], +.row-fluid .uneditable-input[class*="span"], +.row-fluid .input-prepend [class*="span"], +.row-fluid .input-append [class*="span"] { + display: inline-block; +} + +input, +textarea, +.uneditable-input { + margin-left: 0; +} + +.controls-row [class*="span"] + [class*="span"] { + margin-left: 20px; +} + +input.span12, +textarea.span12, +.uneditable-input.span12 { + width: 926px; +} + +input.span11, +textarea.span11, +.uneditable-input.span11 { + width: 846px; +} + +input.span10, +textarea.span10, +.uneditable-input.span10 { + width: 766px; +} + +input.span9, +textarea.span9, +.uneditable-input.span9 { + width: 686px; +} + +input.span8, +textarea.span8, +.uneditable-input.span8 { + width: 606px; +} + +input.span7, +textarea.span7, +.uneditable-input.span7 { + width: 526px; +} + +input.span6, +textarea.span6, +.uneditable-input.span6 { + width: 446px; +} + +input.span5, +textarea.span5, +.uneditable-input.span5 { + width: 366px; +} + +input.span4, +textarea.span4, +.uneditable-input.span4 { + width: 286px; +} + +input.span3, +textarea.span3, +.uneditable-input.span3 { + width: 206px; +} + +input.span2, +textarea.span2, +.uneditable-input.span2 { + width: 126px; +} + +input.span1, +textarea.span1, +.uneditable-input.span1 { + width: 46px; +} + +.controls-row { + *zoom: 1; +} + +.controls-row:before, +.controls-row:after { + display: table; + line-height: 0; + content: ""; +} + +.controls-row:after { + clear: both; +} + +.controls-row [class*="span"], +.row-fluid .controls-row [class*="span"] { + float: left; +} + +.controls-row .checkbox[class*="span"], +.controls-row .radio[class*="span"] { + padding-top: 5px; +} + +input[disabled], +select[disabled], +textarea[disabled], +input[readonly], +select[readonly], +textarea[readonly] { + cursor: not-allowed; + background-color: #eeeeee; +} + +input[type="radio"][disabled], +input[type="checkbox"][disabled], +input[type="radio"][readonly], +input[type="checkbox"][readonly] { + background-color: transparent; +} + +.control-group.warning .control-label, +.control-group.warning .help-block, +.control-group.warning .help-inline { + color: #c09853; +} + +.control-group.warning .checkbox, +.control-group.warning .radio, +.control-group.warning input, +.control-group.warning select, +.control-group.warning textarea { + color: #c09853; +} + +.control-group.warning input, +.control-group.warning select, +.control-group.warning textarea { + border-color: #c09853; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.control-group.warning input:focus, +.control-group.warning select:focus, +.control-group.warning textarea:focus { + border-color: #a47e3c; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; +} + +.control-group.warning .input-prepend .add-on, +.control-group.warning .input-append .add-on { + color: #c09853; + background-color: #fcf8e3; + border-color: #c09853; +} + +.control-group.error .control-label, +.control-group.error .help-block, +.control-group.error .help-inline { + color: #b94a48; +} + +.control-group.error .checkbox, +.control-group.error .radio, +.control-group.error input, +.control-group.error select, +.control-group.error textarea { + color: #b94a48; +} + +.control-group.error input, +.control-group.error select, +.control-group.error textarea { + border-color: #b94a48; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.control-group.error input:focus, +.control-group.error select:focus, +.control-group.error textarea:focus { + border-color: #953b39; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; +} + +.control-group.error .input-prepend .add-on, +.control-group.error .input-append .add-on { + color: #b94a48; + background-color: #f2dede; + border-color: #b94a48; +} + +.control-group.success .control-label, +.control-group.success .help-block, +.control-group.success .help-inline { + color: #468847; +} + +.control-group.success .checkbox, +.control-group.success .radio, +.control-group.success input, +.control-group.success select, +.control-group.success textarea { + color: #468847; +} + +.control-group.success input, +.control-group.success select, +.control-group.success textarea { + border-color: #468847; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.control-group.success input:focus, +.control-group.success select:focus, +.control-group.success textarea:focus { + border-color: #356635; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; +} + +.control-group.success .input-prepend .add-on, +.control-group.success .input-append .add-on { + color: #468847; + background-color: #dff0d8; + border-color: #468847; +} + +.control-group.info .control-label, +.control-group.info .help-block, +.control-group.info .help-inline { + color: #3a87ad; +} + +.control-group.info .checkbox, +.control-group.info .radio, +.control-group.info input, +.control-group.info select, +.control-group.info textarea { + color: #3a87ad; +} + +.control-group.info input, +.control-group.info select, +.control-group.info textarea { + border-color: #3a87ad; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.control-group.info input:focus, +.control-group.info select:focus, +.control-group.info textarea:focus { + border-color: #2d6987; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; +} + +.control-group.info .input-prepend .add-on, +.control-group.info .input-append .add-on { + color: #3a87ad; + background-color: #d9edf7; + border-color: #3a87ad; +} + +input:focus:invalid, +textarea:focus:invalid, +select:focus:invalid { + color: #b94a48; + border-color: #ee5f5b; +} + +input:focus:invalid:focus, +textarea:focus:invalid:focus, +select:focus:invalid:focus { + border-color: #e9322d; + -webkit-box-shadow: 0 0 6px #f8b9b7; + -moz-box-shadow: 0 0 6px #f8b9b7; + box-shadow: 0 0 6px #f8b9b7; +} + +.form-actions { + padding: 19px 20px 20px; + margin-top: 20px; + margin-bottom: 20px; + background-color: #f5f5f5; + border-top: 1px solid #e5e5e5; + *zoom: 1; +} + +.form-actions:before, +.form-actions:after { + display: table; + line-height: 0; + content: ""; +} + +.form-actions:after { + clear: both; +} + +.help-block, +.help-inline { + color: #595959; +} + +.help-block { + display: block; + margin-bottom: 10px; +} + +.help-inline { + display: inline-block; + *display: inline; + padding-left: 5px; + vertical-align: middle; + *zoom: 1; +} + +.input-append, +.input-prepend { + margin-bottom: 5px; + font-size: 0; + white-space: nowrap; +} + +.input-append input, +.input-prepend input, +.input-append select, +.input-prepend select, +.input-append .uneditable-input, +.input-prepend .uneditable-input, +.input-append .dropdown-menu, +.input-prepend .dropdown-menu { + font-size: 14px; +} + +.input-append input, +.input-prepend input, +.input-append select, +.input-prepend select, +.input-append .uneditable-input, +.input-prepend .uneditable-input { + position: relative; + margin-bottom: 0; + *margin-left: 0; + vertical-align: top; + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.input-append input:focus, +.input-prepend input:focus, +.input-append select:focus, +.input-prepend select:focus, +.input-append .uneditable-input:focus, +.input-prepend .uneditable-input:focus { + z-index: 2; +} + +.input-append .add-on, +.input-prepend .add-on { + display: inline-block; + width: auto; + height: 20px; + min-width: 16px; + padding: 4px 5px; + font-size: 14px; + font-weight: normal; + line-height: 20px; + text-align: center; + text-shadow: 0 1px 0 #ffffff; + background-color: #eeeeee; + border: 1px solid #ccc; +} + +.input-append .add-on, +.input-prepend .add-on, +.input-append .btn, +.input-prepend .btn, +.input-append .btn-group > .dropdown-toggle, +.input-prepend .btn-group > .dropdown-toggle { + vertical-align: top; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.input-append .active, +.input-prepend .active { + background-color: #a9dba9; + border-color: #46a546; +} + +.input-prepend .add-on, +.input-prepend .btn { + margin-right: -1px; +} + +.input-prepend .add-on:first-child, +.input-prepend .btn:first-child { + -webkit-border-radius: 4px 0 0 4px; + -moz-border-radius: 4px 0 0 4px; + border-radius: 4px 0 0 4px; +} + +.input-append input, +.input-append select, +.input-append .uneditable-input { + -webkit-border-radius: 4px 0 0 4px; + -moz-border-radius: 4px 0 0 4px; + border-radius: 4px 0 0 4px; +} + +.input-append input + .btn-group .btn:last-child, +.input-append select + .btn-group .btn:last-child, +.input-append .uneditable-input + .btn-group .btn:last-child { + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.input-append .add-on, +.input-append .btn, +.input-append .btn-group { + margin-left: -1px; +} + +.input-append .add-on:last-child, +.input-append .btn:last-child, +.input-append .btn-group:last-child > .dropdown-toggle { + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.input-prepend.input-append input, +.input-prepend.input-append select, +.input-prepend.input-append .uneditable-input { + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.input-prepend.input-append input + .btn-group .btn, +.input-prepend.input-append select + .btn-group .btn, +.input-prepend.input-append .uneditable-input + .btn-group .btn { + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.input-prepend.input-append .add-on:first-child, +.input-prepend.input-append .btn:first-child { + margin-right: -1px; + -webkit-border-radius: 4px 0 0 4px; + -moz-border-radius: 4px 0 0 4px; + border-radius: 4px 0 0 4px; +} + +.input-prepend.input-append .add-on:last-child, +.input-prepend.input-append .btn:last-child { + margin-left: -1px; + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.input-prepend.input-append .btn-group:first-child { + margin-left: 0; +} + +input.search-query { + padding-right: 14px; + padding-right: 4px \9; + padding-left: 14px; + padding-left: 4px \9; + /* IE7-8 doesn't have border-radius, so don't indent the padding */ + + margin-bottom: 0; + -webkit-border-radius: 15px; + -moz-border-radius: 15px; + border-radius: 15px; +} + +/* Allow for input prepend/append in search forms */ + +.form-search .input-append .search-query, +.form-search .input-prepend .search-query { + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.form-search .input-append .search-query { + -webkit-border-radius: 14px 0 0 14px; + -moz-border-radius: 14px 0 0 14px; + border-radius: 14px 0 0 14px; +} + +.form-search .input-append .btn { + -webkit-border-radius: 0 14px 14px 0; + -moz-border-radius: 0 14px 14px 0; + border-radius: 0 14px 14px 0; +} + +.form-search .input-prepend .search-query { + -webkit-border-radius: 0 14px 14px 0; + -moz-border-radius: 0 14px 14px 0; + border-radius: 0 14px 14px 0; +} + +.form-search .input-prepend .btn { + -webkit-border-radius: 14px 0 0 14px; + -moz-border-radius: 14px 0 0 14px; + border-radius: 14px 0 0 14px; +} + +.form-search input, +.form-inline input, +.form-horizontal input, +.form-search textarea, +.form-inline textarea, +.form-horizontal textarea, +.form-search select, +.form-inline select, +.form-horizontal select, +.form-search .help-inline, +.form-inline .help-inline, +.form-horizontal .help-inline, +.form-search .uneditable-input, +.form-inline .uneditable-input, +.form-horizontal .uneditable-input, +.form-search .input-prepend, +.form-inline .input-prepend, +.form-horizontal .input-prepend, +.form-search .input-append, +.form-inline .input-append, +.form-horizontal .input-append { + display: inline-block; + *display: inline; + margin-bottom: 0; + vertical-align: middle; + *zoom: 1; +} + +.form-search .hide, +.form-inline .hide, +.form-horizontal .hide { + display: none; +} + +.form-search label, +.form-inline label, +.form-search .btn-group, +.form-inline .btn-group { + display: inline-block; +} + +.form-search .input-append, +.form-inline .input-append, +.form-search .input-prepend, +.form-inline .input-prepend { + margin-bottom: 0; +} + +.form-search .radio, +.form-search .checkbox, +.form-inline .radio, +.form-inline .checkbox { + padding-left: 0; + margin-bottom: 0; + vertical-align: middle; +} + +.form-search .radio input[type="radio"], +.form-search .checkbox input[type="checkbox"], +.form-inline .radio input[type="radio"], +.form-inline .checkbox input[type="checkbox"] { + float: left; + margin-right: 3px; + margin-left: 0; +} + +.control-group { + margin-bottom: 10px; +} + +legend + .control-group { + margin-top: 20px; + -webkit-margin-top-collapse: separate; +} + +.form-horizontal .control-group { + margin-bottom: 20px; + *zoom: 1; +} + +.form-horizontal .control-group:before, +.form-horizontal .control-group:after { + display: table; + line-height: 0; + content: ""; +} + +.form-horizontal .control-group:after { + clear: both; +} + +.form-horizontal .control-label { + float: left; + width: 160px; + padding-top: 5px; + text-align: right; +} + +.form-horizontal .controls { + *display: inline-block; + *padding-left: 20px; + margin-left: 180px; + *margin-left: 0; +} + +.form-horizontal .controls:first-child { + *padding-left: 180px; +} + +.form-horizontal .help-block { + margin-bottom: 0; +} + +.form-horizontal input + .help-block, +.form-horizontal select + .help-block, +.form-horizontal textarea + .help-block, +.form-horizontal .uneditable-input + .help-block, +.form-horizontal .input-prepend + .help-block, +.form-horizontal .input-append + .help-block { + margin-top: 10px; +} + +.form-horizontal .form-actions { + padding-left: 180px; +} + +table { + max-width: 100%; + background-color: transparent; + border-collapse: collapse; + border-spacing: 0; +} + +.table { + width: 100%; + margin-bottom: 20px; +} + +.table th, +.table td { + padding: 8px; + line-height: 20px; + text-align: left; + vertical-align: top; + border-top: 1px solid #dddddd; +} + +.table th { + font-weight: bold; +} + +.table thead th { + vertical-align: bottom; +} + +.table caption + thead tr:first-child th, +.table caption + thead tr:first-child td, +.table colgroup + thead tr:first-child th, +.table colgroup + thead tr:first-child td, +.table thead:first-child tr:first-child th, +.table thead:first-child tr:first-child td { + border-top: 0; +} + +.table tbody + tbody { + border-top: 2px solid #dddddd; +} + +.table .table { + background-color: #ffffff; +} + +.table-condensed th, +.table-condensed td { + padding: 4px 5px; +} + +.table-bordered { + border: 1px solid #dddddd; + border-collapse: separate; + *border-collapse: collapse; + border-left: 0; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.table-bordered th, +.table-bordered td { + border-left: 1px solid #dddddd; +} + +.table-bordered caption + thead tr:first-child th, +.table-bordered caption + tbody tr:first-child th, +.table-bordered caption + tbody tr:first-child td, +.table-bordered colgroup + thead tr:first-child th, +.table-bordered colgroup + tbody tr:first-child th, +.table-bordered colgroup + tbody tr:first-child td, +.table-bordered thead:first-child tr:first-child th, +.table-bordered tbody:first-child tr:first-child th, +.table-bordered tbody:first-child tr:first-child td { + border-top: 0; +} + +.table-bordered thead:first-child tr:first-child > th:first-child, +.table-bordered tbody:first-child tr:first-child > td:first-child { + -webkit-border-top-left-radius: 4px; + border-top-left-radius: 4px; + -moz-border-radius-topleft: 4px; +} + +.table-bordered thead:first-child tr:first-child > th:last-child, +.table-bordered tbody:first-child tr:first-child > td:last-child { + -webkit-border-top-right-radius: 4px; + border-top-right-radius: 4px; + -moz-border-radius-topright: 4px; +} + +.table-bordered thead:last-child tr:last-child > th:first-child, +.table-bordered tbody:last-child tr:last-child > td:first-child, +.table-bordered tfoot:last-child tr:last-child > td:first-child { + -webkit-border-bottom-left-radius: 4px; + border-bottom-left-radius: 4px; + -moz-border-radius-bottomleft: 4px; +} + +.table-bordered thead:last-child tr:last-child > th:last-child, +.table-bordered tbody:last-child tr:last-child > td:last-child, +.table-bordered tfoot:last-child tr:last-child > td:last-child { + -webkit-border-bottom-right-radius: 4px; + border-bottom-right-radius: 4px; + -moz-border-radius-bottomright: 4px; +} + +.table-bordered tfoot + tbody:last-child tr:last-child td:first-child { + -webkit-border-bottom-left-radius: 0; + border-bottom-left-radius: 0; + -moz-border-radius-bottomleft: 0; +} + +.table-bordered tfoot + tbody:last-child tr:last-child td:last-child { + -webkit-border-bottom-right-radius: 0; + border-bottom-right-radius: 0; + -moz-border-radius-bottomright: 0; +} + +.table-bordered caption + thead tr:first-child th:first-child, +.table-bordered caption + tbody tr:first-child td:first-child, +.table-bordered colgroup + thead tr:first-child th:first-child, +.table-bordered colgroup + tbody tr:first-child td:first-child { + -webkit-border-top-left-radius: 4px; + border-top-left-radius: 4px; + -moz-border-radius-topleft: 4px; +} + +.table-bordered caption + thead tr:first-child th:last-child, +.table-bordered caption + tbody tr:first-child td:last-child, +.table-bordered colgroup + thead tr:first-child th:last-child, +.table-bordered colgroup + tbody tr:first-child td:last-child { + -webkit-border-top-right-radius: 4px; + border-top-right-radius: 4px; + -moz-border-radius-topright: 4px; +} + +.table-striped tbody > tr:nth-child(odd) > td, +.table-striped tbody > tr:nth-child(odd) > th { + background-color: #f9f9f9; +} + +.table-hover tbody tr:hover td, +.table-hover tbody tr:hover th { + background-color: #f5f5f5; +} + +table td[class*="span"], +table th[class*="span"], +.row-fluid table td[class*="span"], +.row-fluid table th[class*="span"] { + display: table-cell; + float: none; + margin-left: 0; +} + +.table td.span1, +.table th.span1 { + float: none; + width: 44px; + margin-left: 0; +} + +.table td.span2, +.table th.span2 { + float: none; + width: 124px; + margin-left: 0; +} + +.table td.span3, +.table th.span3 { + float: none; + width: 204px; + margin-left: 0; +} + +.table td.span4, +.table th.span4 { + float: none; + width: 284px; + margin-left: 0; +} + +.table td.span5, +.table th.span5 { + float: none; + width: 364px; + margin-left: 0; +} + +.table td.span6, +.table th.span6 { + float: none; + width: 444px; + margin-left: 0; +} + +.table td.span7, +.table th.span7 { + float: none; + width: 524px; + margin-left: 0; +} + +.table td.span8, +.table th.span8 { + float: none; + width: 604px; + margin-left: 0; +} + +.table td.span9, +.table th.span9 { + float: none; + width: 684px; + margin-left: 0; +} + +.table td.span10, +.table th.span10 { + float: none; + width: 764px; + margin-left: 0; +} + +.table td.span11, +.table th.span11 { + float: none; + width: 844px; + margin-left: 0; +} + +.table td.span12, +.table th.span12 { + float: none; + width: 924px; + margin-left: 0; +} + +.table tbody tr.success td { + background-color: #dff0d8; +} + +.table tbody tr.error td { + background-color: #f2dede; +} + +.table tbody tr.warning td { + background-color: #fcf8e3; +} + +.table tbody tr.info td { + background-color: #d9edf7; +} + +.table-hover tbody tr.success:hover td { + background-color: #d0e9c6; +} + +.table-hover tbody tr.error:hover td { + background-color: #ebcccc; +} + +.table-hover tbody tr.warning:hover td { + background-color: #faf2cc; +} + +.table-hover tbody tr.info:hover td { + background-color: #c4e3f3; +} + +[class^="icon-"], +[class*=" icon-"] { + display: inline-block; + width: 14px; + height: 14px; + margin-top: 1px; + *margin-right: .3em; + line-height: 14px; + vertical-align: text-top; + background-image: url("../img/glyphicons-halflings.png"); + background-position: 14px 14px; + background-repeat: no-repeat; +} + +/* White icons with optional class, or on hover/active states of certain elements */ + +.icon-white, +.nav-pills > .active > a > [class^="icon-"], +.nav-pills > .active > a > [class*=" icon-"], +.nav-list > .active > a > [class^="icon-"], +.nav-list > .active > a > [class*=" icon-"], +.navbar-inverse .nav > .active > a > [class^="icon-"], +.navbar-inverse .nav > .active > a > [class*=" icon-"], +.dropdown-menu > li > a:hover > [class^="icon-"], +.dropdown-menu > li > a:hover > [class*=" icon-"], +.dropdown-menu > .active > a > [class^="icon-"], +.dropdown-menu > .active > a > [class*=" icon-"], +.dropdown-submenu:hover > a > [class^="icon-"], +.dropdown-submenu:hover > a > [class*=" icon-"] { + background-image: url("../img/glyphicons-halflings-white.png"); +} + +.icon-glass { + background-position: 0 0; +} + +.icon-music { + background-position: -24px 0; +} + +.icon-search { + background-position: -48px 0; +} + +.icon-envelope { + background-position: -72px 0; +} + +.icon-heart { + background-position: -96px 0; +} + +.icon-star { + background-position: -120px 0; +} + +.icon-star-empty { + background-position: -144px 0; +} + +.icon-user { + background-position: -168px 0; +} + +.icon-film { + background-position: -192px 0; +} + +.icon-th-large { + background-position: -216px 0; +} + +.icon-th { + background-position: -240px 0; +} + +.icon-th-list { + background-position: -264px 0; +} + +.icon-ok { + background-position: -288px 0; +} + +.icon-remove { + background-position: -312px 0; +} + +.icon-zoom-in { + background-position: -336px 0; +} + +.icon-zoom-out { + background-position: -360px 0; +} + +.icon-off { + background-position: -384px 0; +} + +.icon-signal { + background-position: -408px 0; +} + +.icon-cog { + background-position: -432px 0; +} + +.icon-trash { + background-position: -456px 0; +} + +.icon-home { + background-position: 0 -24px; +} + +.icon-file { + background-position: -24px -24px; +} + +.icon-time { + background-position: -48px -24px; +} + +.icon-road { + background-position: -72px -24px; +} + +.icon-download-alt { + background-position: -96px -24px; +} + +.icon-download { + background-position: -120px -24px; +} + +.icon-upload { + background-position: -144px -24px; +} + +.icon-inbox { + background-position: -168px -24px; +} + +.icon-play-circle { + background-position: -192px -24px; +} + +.icon-repeat { + background-position: -216px -24px; +} + +.icon-refresh { + background-position: -240px -24px; +} + +.icon-list-alt { + background-position: -264px -24px; +} + +.icon-lock { + background-position: -287px -24px; +} + +.icon-flag { + background-position: -312px -24px; +} + +.icon-headphones { + background-position: -336px -24px; +} + +.icon-volume-off { + background-position: -360px -24px; +} + +.icon-volume-down { + background-position: -384px -24px; +} + +.icon-volume-up { + background-position: -408px -24px; +} + +.icon-qrcode { + background-position: -432px -24px; +} + +.icon-barcode { + background-position: -456px -24px; +} + +.icon-tag { + background-position: 0 -48px; +} + +.icon-tags { + background-position: -25px -48px; +} + +.icon-book { + background-position: -48px -48px; +} + +.icon-bookmark { + background-position: -72px -48px; +} + +.icon-print { + background-position: -96px -48px; +} + +.icon-camera { + background-position: -120px -48px; +} + +.icon-font { + background-position: -144px -48px; +} + +.icon-bold { + background-position: -167px -48px; +} + +.icon-italic { + background-position: -192px -48px; +} + +.icon-text-height { + background-position: -216px -48px; +} + +.icon-text-width { + background-position: -240px -48px; +} + +.icon-align-left { + background-position: -264px -48px; +} + +.icon-align-center { + background-position: -288px -48px; +} + +.icon-align-right { + background-position: -312px -48px; +} + +.icon-align-justify { + background-position: -336px -48px; +} + +.icon-list { + background-position: -360px -48px; +} + +.icon-indent-left { + background-position: -384px -48px; +} + +.icon-indent-right { + background-position: -408px -48px; +} + +.icon-facetime-video { + background-position: -432px -48px; +} + +.icon-picture { + background-position: -456px -48px; +} + +.icon-pencil { + background-position: 0 -72px; +} + +.icon-map-marker { + background-position: -24px -72px; +} + +.icon-adjust { + background-position: -48px -72px; +} + +.icon-tint { + background-position: -72px -72px; +} + +.icon-edit { + background-position: -96px -72px; +} + +.icon-share { + background-position: -120px -72px; +} + +.icon-check { + background-position: -144px -72px; +} + +.icon-move { + background-position: -168px -72px; +} + +.icon-step-backward { + background-position: -192px -72px; +} + +.icon-fast-backward { + background-position: -216px -72px; +} + +.icon-backward { + background-position: -240px -72px; +} + +.icon-play { + background-position: -264px -72px; +} + +.icon-pause { + background-position: -288px -72px; +} + +.icon-stop { + background-position: -312px -72px; +} + +.icon-forward { + background-position: -336px -72px; +} + +.icon-fast-forward { + background-position: -360px -72px; +} + +.icon-step-forward { + background-position: -384px -72px; +} + +.icon-eject { + background-position: -408px -72px; +} + +.icon-chevron-left { + background-position: -432px -72px; +} + +.icon-chevron-right { + background-position: -456px -72px; +} + +.icon-plus-sign { + background-position: 0 -96px; +} + +.icon-minus-sign { + background-position: -24px -96px; +} + +.icon-remove-sign { + background-position: -48px -96px; +} + +.icon-ok-sign { + background-position: -72px -96px; +} + +.icon-question-sign { + background-position: -96px -96px; +} + +.icon-info-sign { + background-position: -120px -96px; +} + +.icon-screenshot { + background-position: -144px -96px; +} + +.icon-remove-circle { + background-position: -168px -96px; +} + +.icon-ok-circle { + background-position: -192px -96px; +} + +.icon-ban-circle { + background-position: -216px -96px; +} + +.icon-arrow-left { + background-position: -240px -96px; +} + +.icon-arrow-right { + background-position: -264px -96px; +} + +.icon-arrow-up { + background-position: -289px -96px; +} + +.icon-arrow-down { + background-position: -312px -96px; +} + +.icon-share-alt { + background-position: -336px -96px; +} + +.icon-resize-full { + background-position: -360px -96px; +} + +.icon-resize-small { + background-position: -384px -96px; +} + +.icon-plus { + background-position: -408px -96px; +} + +.icon-minus { + background-position: -433px -96px; +} + +.icon-asterisk { + background-position: -456px -96px; +} + +.icon-exclamation-sign { + background-position: 0 -120px; +} + +.icon-gift { + background-position: -24px -120px; +} + +.icon-leaf { + background-position: -48px -120px; +} + +.icon-fire { + background-position: -72px -120px; +} + +.icon-eye-open { + background-position: -96px -120px; +} + +.icon-eye-close { + background-position: -120px -120px; +} + +.icon-warning-sign { + background-position: -144px -120px; +} + +.icon-plane { + background-position: -168px -120px; +} + +.icon-calendar { + background-position: -192px -120px; +} + +.icon-random { + width: 16px; + background-position: -216px -120px; +} + +.icon-comment { + background-position: -240px -120px; +} + +.icon-magnet { + background-position: -264px -120px; +} + +.icon-chevron-up { + background-position: -288px -120px; +} + +.icon-chevron-down { + background-position: -313px -119px; +} + +.icon-retweet { + background-position: -336px -120px; +} + +.icon-shopping-cart { + background-position: -360px -120px; +} + +.icon-folder-close { + background-position: -384px -120px; +} + +.icon-folder-open { + width: 16px; + background-position: -408px -120px; +} + +.icon-resize-vertical { + background-position: -432px -119px; +} + +.icon-resize-horizontal { + background-position: -456px -118px; +} + +.icon-hdd { + background-position: 0 -144px; +} + +.icon-bullhorn { + background-position: -24px -144px; +} + +.icon-bell { + background-position: -48px -144px; +} + +.icon-certificate { + background-position: -72px -144px; +} + +.icon-thumbs-up { + background-position: -96px -144px; +} + +.icon-thumbs-down { + background-position: -120px -144px; +} + +.icon-hand-right { + background-position: -144px -144px; +} + +.icon-hand-left { + background-position: -168px -144px; +} + +.icon-hand-up { + background-position: -192px -144px; +} + +.icon-hand-down { + background-position: -216px -144px; +} + +.icon-circle-arrow-right { + background-position: -240px -144px; +} + +.icon-circle-arrow-left { + background-position: -264px -144px; +} + +.icon-circle-arrow-up { + background-position: -288px -144px; +} + +.icon-circle-arrow-down { + background-position: -312px -144px; +} + +.icon-globe { + background-position: -336px -144px; +} + +.icon-wrench { + background-position: -360px -144px; +} + +.icon-tasks { + background-position: -384px -144px; +} + +.icon-filter { + background-position: -408px -144px; +} + +.icon-briefcase { + background-position: -432px -144px; +} + +.icon-fullscreen { + background-position: -456px -144px; +} + +.dropup, +.dropdown { + position: relative; +} + +.dropdown-toggle { + *margin-bottom: -3px; +} + +.dropdown-toggle:active, +.open .dropdown-toggle { + outline: 0; +} + +.caret { + display: inline-block; + width: 0; + height: 0; + vertical-align: top; + border-top: 4px solid #000000; + border-right: 4px solid transparent; + border-left: 4px solid transparent; + content: ""; +} + +.dropdown .caret { + margin-top: 8px; + margin-left: 2px; +} + +.dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 1000; + display: none; + float: left; + min-width: 160px; + padding: 5px 0; + margin: 2px 0 0; + list-style: none; + background-color: #ffffff; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.2); + *border-right-width: 2px; + *border-bottom-width: 2px; + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; + -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + -webkit-background-clip: padding-box; + -moz-background-clip: padding; + background-clip: padding-box; +} + +.dropdown-menu.pull-right { + right: 0; + left: auto; +} + +.dropdown-menu .divider { + *width: 100%; + height: 1px; + margin: 9px 1px; + *margin: -5px 0 5px; + overflow: hidden; + background-color: #e5e5e5; + border-bottom: 1px solid #ffffff; +} + +.dropdown-menu li > a { + display: block; + padding: 3px 20px; + clear: both; + font-weight: normal; + line-height: 20px; + color: #333333; + white-space: nowrap; +} + +.dropdown-menu li > a:hover, +.dropdown-menu li > a:focus, +.dropdown-submenu:hover > a { + color: #ffffff; + text-decoration: none; + background-color: #0081c2; + background-image: -moz-linear-gradient(top, #0088cc, #0077b3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0077b3)); + background-image: -webkit-linear-gradient(top, #0088cc, #0077b3); + background-image: -o-linear-gradient(top, #0088cc, #0077b3); + background-image: linear-gradient(to bottom, #0088cc, #0077b3); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0); +} + +.dropdown-menu .active > a, +.dropdown-menu .active > a:hover { + color: #ffffff; + text-decoration: none; + background-color: #0081c2; + background-image: -moz-linear-gradient(top, #0088cc, #0077b3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0077b3)); + background-image: -webkit-linear-gradient(top, #0088cc, #0077b3); + background-image: -o-linear-gradient(top, #0088cc, #0077b3); + background-image: linear-gradient(to bottom, #0088cc, #0077b3); + background-repeat: repeat-x; + outline: 0; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0); +} + +.dropdown-menu .disabled > a, +.dropdown-menu .disabled > a:hover { + color: #999999; +} + +.dropdown-menu .disabled > a:hover { + text-decoration: none; + cursor: default; + background-color: transparent; + background-image: none; + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.open { + *z-index: 1000; +} + +.open > .dropdown-menu { + display: block; +} + +.pull-right > .dropdown-menu { + right: 0; + left: auto; +} + +.dropup .caret, +.navbar-fixed-bottom .dropdown .caret { + border-top: 0; + border-bottom: 4px solid #000000; + content: ""; +} + +.dropup .dropdown-menu, +.navbar-fixed-bottom .dropdown .dropdown-menu { + top: auto; + bottom: 100%; + margin-bottom: 1px; +} + +.dropdown-submenu { + position: relative; +} + +.dropdown-submenu > .dropdown-menu { + top: 0; + left: 100%; + margin-top: -6px; + margin-left: -1px; + -webkit-border-radius: 0 6px 6px 6px; + -moz-border-radius: 0 6px 6px 6px; + border-radius: 0 6px 6px 6px; +} + +.dropdown-submenu:hover > .dropdown-menu { + display: block; +} + +.dropup .dropdown-submenu > .dropdown-menu { + top: auto; + bottom: 0; + margin-top: 0; + margin-bottom: -2px; + -webkit-border-radius: 5px 5px 5px 0; + -moz-border-radius: 5px 5px 5px 0; + border-radius: 5px 5px 5px 0; +} + +.dropdown-submenu > a:after { + display: block; + float: right; + width: 0; + height: 0; + margin-top: 5px; + margin-right: -10px; + border-color: transparent; + border-left-color: #cccccc; + border-style: solid; + border-width: 5px 0 5px 5px; + content: " "; +} + +.dropdown-submenu:hover > a:after { + border-left-color: #ffffff; +} + +.dropdown-submenu.pull-left { + float: none; +} + +.dropdown-submenu.pull-left > .dropdown-menu { + left: -100%; + margin-left: 10px; + -webkit-border-radius: 6px 0 6px 6px; + -moz-border-radius: 6px 0 6px 6px; + border-radius: 6px 0 6px 6px; +} + +.dropdown .dropdown-menu .nav-header { + padding-right: 20px; + padding-left: 20px; +} + +.typeahead { + z-index: 1051; + margin-top: 2px; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.well { + min-height: 20px; + padding: 19px; + margin-bottom: 20px; + background-color: #f5f5f5; + border: 1px solid #e3e3e3; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); +} + +.well blockquote { + border-color: #ddd; + border-color: rgba(0, 0, 0, 0.15); +} + +.well-large { + padding: 24px; + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; +} + +.well-small { + padding: 9px; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; +} + +.fade { + opacity: 0; + -webkit-transition: opacity 0.15s linear; + -moz-transition: opacity 0.15s linear; + -o-transition: opacity 0.15s linear; + transition: opacity 0.15s linear; +} + +.fade.in { + opacity: 1; +} + +.collapse { + position: relative; + height: 0; + overflow: hidden; + -webkit-transition: height 0.35s ease; + -moz-transition: height 0.35s ease; + -o-transition: height 0.35s ease; + transition: height 0.35s ease; +} + +.collapse.in { + height: auto; +} + +.close { + float: right; + font-size: 20px; + font-weight: bold; + line-height: 20px; + color: #000000; + text-shadow: 0 1px 0 #ffffff; + opacity: 0.2; + filter: alpha(opacity=20); +} + +.close:hover { + color: #000000; + text-decoration: none; + cursor: pointer; + opacity: 0.4; + filter: alpha(opacity=40); +} + +button.close { + padding: 0; + cursor: pointer; + background: transparent; + border: 0; + -webkit-appearance: none; +} + +.btn { + display: inline-block; + *display: inline; + padding: 4px 12px; + margin-bottom: 0; + *margin-left: .3em; + font-size: 14px; + line-height: 20px; + color: #333333; + text-align: center; + text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75); + vertical-align: middle; + cursor: pointer; + background-color: #f5f5f5; + *background-color: #e6e6e6; + background-image: -moz-linear-gradient(top, #ffffff, #e6e6e6); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#e6e6e6)); + background-image: -webkit-linear-gradient(top, #ffffff, #e6e6e6); + background-image: -o-linear-gradient(top, #ffffff, #e6e6e6); + background-image: linear-gradient(to bottom, #ffffff, #e6e6e6); + background-repeat: repeat-x; + border: 1px solid #bbbbbb; + *border: 0; + border-color: #e6e6e6 #e6e6e6 #bfbfbf; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + border-bottom-color: #a2a2a2; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + *zoom: 1; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); + -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.btn:hover, +.btn:active, +.btn.active, +.btn.disabled, +.btn[disabled] { + color: #333333; + background-color: #e6e6e6; + *background-color: #d9d9d9; +} + +.btn:active, +.btn.active { + background-color: #cccccc \9; +} + +.btn:first-child { + *margin-left: 0; +} + +.btn:hover { + color: #333333; + text-decoration: none; + background-position: 0 -15px; + -webkit-transition: background-position 0.1s linear; + -moz-transition: background-position 0.1s linear; + -o-transition: background-position 0.1s linear; + transition: background-position 0.1s linear; +} + +.btn:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +.btn.active, +.btn:active { + background-image: none; + outline: 0; + -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); + -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.btn.disabled, +.btn[disabled] { + cursor: default; + background-image: none; + opacity: 0.65; + filter: alpha(opacity=65); + -webkit-box-shadow: none; + -moz-box-shadow: none; + box-shadow: none; +} + +.btn-large { + padding: 11px 19px; + font-size: 17.5px; + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; +} + +.btn-large [class^="icon-"], +.btn-large [class*=" icon-"] { + margin-top: 4px; +} + +.btn-small { + padding: 2px 10px; + font-size: 11.9px; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; +} + +.btn-small [class^="icon-"], +.btn-small [class*=" icon-"] { + margin-top: 0; +} + +.btn-mini [class^="icon-"], +.btn-mini [class*=" icon-"] { + margin-top: -1px; +} + +.btn-mini { + padding: 0 6px; + font-size: 10.5px; + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; +} + +.btn-block { + display: block; + width: 100%; + padding-right: 0; + padding-left: 0; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +.btn-block + .btn-block { + margin-top: 5px; +} + +input[type="submit"].btn-block, +input[type="reset"].btn-block, +input[type="button"].btn-block { + width: 100%; +} + +.btn-primary.active, +.btn-warning.active, +.btn-danger.active, +.btn-success.active, +.btn-info.active, +.btn-inverse.active { + color: rgba(255, 255, 255, 0.75); +} + +.btn { + border-color: #c5c5c5; + border-color: rgba(0, 0, 0, 0.15) rgba(0, 0, 0, 0.15) rgba(0, 0, 0, 0.25); +} + +.btn-primary { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #006dcc; + *background-color: #0044cc; + background-image: -moz-linear-gradient(top, #0088cc, #0044cc); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc)); + background-image: -webkit-linear-gradient(top, #0088cc, #0044cc); + background-image: -o-linear-gradient(top, #0088cc, #0044cc); + background-image: linear-gradient(to bottom, #0088cc, #0044cc); + background-repeat: repeat-x; + border-color: #0044cc #0044cc #002a80; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0044cc', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-primary:hover, +.btn-primary:active, +.btn-primary.active, +.btn-primary.disabled, +.btn-primary[disabled] { + color: #ffffff; + background-color: #0044cc; + *background-color: #003bb3; +} + +.btn-primary:active, +.btn-primary.active { + background-color: #003399 \9; +} + +.btn-warning { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #faa732; + *background-color: #f89406; + background-image: -moz-linear-gradient(top, #fbb450, #f89406); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406)); + background-image: -webkit-linear-gradient(top, #fbb450, #f89406); + background-image: -o-linear-gradient(top, #fbb450, #f89406); + background-image: linear-gradient(to bottom, #fbb450, #f89406); + background-repeat: repeat-x; + border-color: #f89406 #f89406 #ad6704; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-warning:hover, +.btn-warning:active, +.btn-warning.active, +.btn-warning.disabled, +.btn-warning[disabled] { + color: #ffffff; + background-color: #f89406; + *background-color: #df8505; +} + +.btn-warning:active, +.btn-warning.active { + background-color: #c67605 \9; +} + +.btn-danger { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #da4f49; + *background-color: #bd362f; + background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f)); + background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f); + background-image: -o-linear-gradient(top, #ee5f5b, #bd362f); + background-image: linear-gradient(to bottom, #ee5f5b, #bd362f); + background-repeat: repeat-x; + border-color: #bd362f #bd362f #802420; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-danger:hover, +.btn-danger:active, +.btn-danger.active, +.btn-danger.disabled, +.btn-danger[disabled] { + color: #ffffff; + background-color: #bd362f; + *background-color: #a9302a; +} + +.btn-danger:active, +.btn-danger.active { + background-color: #942a25 \9; +} + +.btn-success { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #5bb75b; + *background-color: #51a351; + background-image: -moz-linear-gradient(top, #62c462, #51a351); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#51a351)); + background-image: -webkit-linear-gradient(top, #62c462, #51a351); + background-image: -o-linear-gradient(top, #62c462, #51a351); + background-image: linear-gradient(to bottom, #62c462, #51a351); + background-repeat: repeat-x; + border-color: #51a351 #51a351 #387038; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff51a351', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-success:hover, +.btn-success:active, +.btn-success.active, +.btn-success.disabled, +.btn-success[disabled] { + color: #ffffff; + background-color: #51a351; + *background-color: #499249; +} + +.btn-success:active, +.btn-success.active { + background-color: #408140 \9; +} + +.btn-info { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #49afcd; + *background-color: #2f96b4; + background-image: -moz-linear-gradient(top, #5bc0de, #2f96b4); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#2f96b4)); + background-image: -webkit-linear-gradient(top, #5bc0de, #2f96b4); + background-image: -o-linear-gradient(top, #5bc0de, #2f96b4); + background-image: linear-gradient(to bottom, #5bc0de, #2f96b4); + background-repeat: repeat-x; + border-color: #2f96b4 #2f96b4 #1f6377; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2f96b4', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-info:hover, +.btn-info:active, +.btn-info.active, +.btn-info.disabled, +.btn-info[disabled] { + color: #ffffff; + background-color: #2f96b4; + *background-color: #2a85a0; +} + +.btn-info:active, +.btn-info.active { + background-color: #24748c \9; +} + +.btn-inverse { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #363636; + *background-color: #222222; + background-image: -moz-linear-gradient(top, #444444, #222222); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#444444), to(#222222)); + background-image: -webkit-linear-gradient(top, #444444, #222222); + background-image: -o-linear-gradient(top, #444444, #222222); + background-image: linear-gradient(to bottom, #444444, #222222); + background-repeat: repeat-x; + border-color: #222222 #222222 #000000; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff444444', endColorstr='#ff222222', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.btn-inverse:hover, +.btn-inverse:active, +.btn-inverse.active, +.btn-inverse.disabled, +.btn-inverse[disabled] { + color: #ffffff; + background-color: #222222; + *background-color: #151515; +} + +.btn-inverse:active, +.btn-inverse.active { + background-color: #080808 \9; +} + +button.btn, +input[type="submit"].btn { + *padding-top: 3px; + *padding-bottom: 3px; +} + +button.btn::-moz-focus-inner, +input[type="submit"].btn::-moz-focus-inner { + padding: 0; + border: 0; +} + +button.btn.btn-large, +input[type="submit"].btn.btn-large { + *padding-top: 7px; + *padding-bottom: 7px; +} + +button.btn.btn-small, +input[type="submit"].btn.btn-small { + *padding-top: 3px; + *padding-bottom: 3px; +} + +button.btn.btn-mini, +input[type="submit"].btn.btn-mini { + *padding-top: 1px; + *padding-bottom: 1px; +} + +.btn-link, +.btn-link:active, +.btn-link[disabled] { + background-color: transparent; + background-image: none; + -webkit-box-shadow: none; + -moz-box-shadow: none; + box-shadow: none; +} + +.btn-link { + color: #0088cc; + cursor: pointer; + border-color: transparent; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.btn-link:hover { + color: #005580; + text-decoration: underline; + background-color: transparent; +} + +.btn-link[disabled]:hover { + color: #333333; + text-decoration: none; +} + +.btn-group { + position: relative; + display: inline-block; + *display: inline; + *margin-left: .3em; + font-size: 0; + white-space: nowrap; + vertical-align: middle; + *zoom: 1; +} + +.btn-group:first-child { + *margin-left: 0; +} + +.btn-group + .btn-group { + margin-left: 5px; +} + +.btn-toolbar { + margin-top: 10px; + margin-bottom: 10px; + font-size: 0; +} + +.btn-toolbar > .btn + .btn, +.btn-toolbar > .btn-group + .btn, +.btn-toolbar > .btn + .btn-group { + margin-left: 5px; +} + +.btn-group > .btn { + position: relative; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.btn-group > .btn + .btn { + margin-left: -1px; +} + +.btn-group > .btn, +.btn-group > .dropdown-menu, +.btn-group > .popover { + font-size: 14px; +} + +.btn-group > .btn-mini { + font-size: 10.5px; +} + +.btn-group > .btn-small { + font-size: 11.9px; +} + +.btn-group > .btn-large { + font-size: 17.5px; +} + +.btn-group > .btn:first-child { + margin-left: 0; + -webkit-border-bottom-left-radius: 4px; + border-bottom-left-radius: 4px; + -webkit-border-top-left-radius: 4px; + border-top-left-radius: 4px; + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-topleft: 4px; +} + +.btn-group > .btn:last-child, +.btn-group > .dropdown-toggle { + -webkit-border-top-right-radius: 4px; + border-top-right-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + border-bottom-right-radius: 4px; + -moz-border-radius-topright: 4px; + -moz-border-radius-bottomright: 4px; +} + +.btn-group > .btn.large:first-child { + margin-left: 0; + -webkit-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -webkit-border-top-left-radius: 6px; + border-top-left-radius: 6px; + -moz-border-radius-bottomleft: 6px; + -moz-border-radius-topleft: 6px; +} + +.btn-group > .btn.large:last-child, +.btn-group > .large.dropdown-toggle { + -webkit-border-top-right-radius: 6px; + border-top-right-radius: 6px; + -webkit-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + -moz-border-radius-topright: 6px; + -moz-border-radius-bottomright: 6px; +} + +.btn-group > .btn:hover, +.btn-group > .btn:focus, +.btn-group > .btn:active, +.btn-group > .btn.active { + z-index: 2; +} + +.btn-group .dropdown-toggle:active, +.btn-group.open .dropdown-toggle { + outline: 0; +} + +.btn-group > .btn + .dropdown-toggle { + *padding-top: 5px; + padding-right: 8px; + *padding-bottom: 5px; + padding-left: 8px; + -webkit-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); + -moz-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.btn-group > .btn-mini + .dropdown-toggle { + *padding-top: 2px; + padding-right: 5px; + *padding-bottom: 2px; + padding-left: 5px; +} + +.btn-group > .btn-small + .dropdown-toggle { + *padding-top: 5px; + *padding-bottom: 4px; +} + +.btn-group > .btn-large + .dropdown-toggle { + *padding-top: 7px; + padding-right: 12px; + *padding-bottom: 7px; + padding-left: 12px; +} + +.btn-group.open .dropdown-toggle { + background-image: none; + -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); + -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.btn-group.open .btn.dropdown-toggle { + background-color: #e6e6e6; +} + +.btn-group.open .btn-primary.dropdown-toggle { + background-color: #0044cc; +} + +.btn-group.open .btn-warning.dropdown-toggle { + background-color: #f89406; +} + +.btn-group.open .btn-danger.dropdown-toggle { + background-color: #bd362f; +} + +.btn-group.open .btn-success.dropdown-toggle { + background-color: #51a351; +} + +.btn-group.open .btn-info.dropdown-toggle { + background-color: #2f96b4; +} + +.btn-group.open .btn-inverse.dropdown-toggle { + background-color: #222222; +} + +.btn .caret { + margin-top: 8px; + margin-left: 0; +} + +.btn-mini .caret, +.btn-small .caret, +.btn-large .caret { + margin-top: 6px; +} + +.btn-large .caret { + border-top-width: 5px; + border-right-width: 5px; + border-left-width: 5px; +} + +.dropup .btn-large .caret { + border-bottom-width: 5px; +} + +.btn-primary .caret, +.btn-warning .caret, +.btn-danger .caret, +.btn-info .caret, +.btn-success .caret, +.btn-inverse .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.btn-group-vertical { + display: inline-block; + *display: inline; + /* IE7 inline-block hack */ + + *zoom: 1; +} + +.btn-group-vertical > .btn { + display: block; + float: none; + max-width: 100%; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.btn-group-vertical > .btn + .btn { + margin-top: -1px; + margin-left: 0; +} + +.btn-group-vertical > .btn:first-child { + -webkit-border-radius: 4px 4px 0 0; + -moz-border-radius: 4px 4px 0 0; + border-radius: 4px 4px 0 0; +} + +.btn-group-vertical > .btn:last-child { + -webkit-border-radius: 0 0 4px 4px; + -moz-border-radius: 0 0 4px 4px; + border-radius: 0 0 4px 4px; +} + +.btn-group-vertical > .btn-large:first-child { + -webkit-border-radius: 6px 6px 0 0; + -moz-border-radius: 6px 6px 0 0; + border-radius: 6px 6px 0 0; +} + +.btn-group-vertical > .btn-large:last-child { + -webkit-border-radius: 0 0 6px 6px; + -moz-border-radius: 0 0 6px 6px; + border-radius: 0 0 6px 6px; +} + +.alert { + padding: 8px 35px 8px 14px; + margin-bottom: 20px; + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); + background-color: #fcf8e3; + border: 1px solid #fbeed5; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.alert, +.alert h4 { + color: #c09853; +} + +.alert h4 { + margin: 0; +} + +.alert .close { + position: relative; + top: -2px; + right: -21px; + line-height: 20px; +} + +.alert-success { + color: #468847; + background-color: #dff0d8; + border-color: #d6e9c6; +} + +.alert-success h4 { + color: #468847; +} + +.alert-danger, +.alert-error { + color: #b94a48; + background-color: #f2dede; + border-color: #eed3d7; +} + +.alert-danger h4, +.alert-error h4 { + color: #b94a48; +} + +.alert-info { + color: #3a87ad; + background-color: #d9edf7; + border-color: #bce8f1; +} + +.alert-info h4 { + color: #3a87ad; +} + +.alert-block { + padding-top: 14px; + padding-bottom: 14px; +} + +.alert-block > p, +.alert-block > ul { + margin-bottom: 0; +} + +.alert-block p + p { + margin-top: 5px; +} + +.nav { + margin-bottom: 20px; + margin-left: 0; + list-style: none; +} + +.nav > li > a { + display: block; +} + +.nav > li > a:hover { + text-decoration: none; + background-color: #eeeeee; +} + +.nav > li > a > img { + max-width: none; +} + +.nav > .pull-right { + float: right; +} + +.nav-header { + display: block; + padding: 3px 15px; + font-size: 11px; + font-weight: bold; + line-height: 20px; + color: #999999; + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); + text-transform: uppercase; +} + +.nav li + .nav-header { + margin-top: 9px; +} + +.nav-list { + padding-right: 15px; + padding-left: 15px; + margin-bottom: 0; +} + +.nav-list > li > a, +.nav-list .nav-header { + margin-right: -15px; + margin-left: -15px; + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); +} + +.nav-list > li > a { + padding: 3px 15px; +} + +.nav-list > .active > a, +.nav-list > .active > a:hover { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2); + background-color: #0088cc; +} + +.nav-list [class^="icon-"], +.nav-list [class*=" icon-"] { + margin-right: 2px; +} + +.nav-list .divider { + *width: 100%; + height: 1px; + margin: 9px 1px; + *margin: -5px 0 5px; + overflow: hidden; + background-color: #e5e5e5; + border-bottom: 1px solid #ffffff; +} + +.nav-tabs, +.nav-pills { + *zoom: 1; +} + +.nav-tabs:before, +.nav-pills:before, +.nav-tabs:after, +.nav-pills:after { + display: table; + line-height: 0; + content: ""; +} + +.nav-tabs:after, +.nav-pills:after { + clear: both; +} + +.nav-tabs > li, +.nav-pills > li { + float: left; +} + +.nav-tabs > li > a, +.nav-pills > li > a { + padding-right: 12px; + padding-left: 12px; + margin-right: 2px; + line-height: 14px; +} + +.nav-tabs { + border-bottom: 1px solid #ddd; +} + +.nav-tabs > li { + margin-bottom: -1px; +} + +.nav-tabs > li > a { + padding-top: 8px; + padding-bottom: 8px; + line-height: 20px; + border: 1px solid transparent; + -webkit-border-radius: 4px 4px 0 0; + -moz-border-radius: 4px 4px 0 0; + border-radius: 4px 4px 0 0; +} + +.nav-tabs > li > a:hover { + border-color: #eeeeee #eeeeee #dddddd; +} + +.nav-tabs > .active > a, +.nav-tabs > .active > a:hover { + color: #555555; + cursor: default; + background-color: #ffffff; + border: 1px solid #ddd; + border-bottom-color: transparent; +} + +.nav-pills > li > a { + padding-top: 8px; + padding-bottom: 8px; + margin-top: 2px; + margin-bottom: 2px; + -webkit-border-radius: 5px; + -moz-border-radius: 5px; + border-radius: 5px; +} + +.nav-pills > .active > a, +.nav-pills > .active > a:hover { + color: #ffffff; + background-color: #0088cc; +} + +.nav-stacked > li { + float: none; +} + +.nav-stacked > li > a { + margin-right: 0; +} + +.nav-tabs.nav-stacked { + border-bottom: 0; +} + +.nav-tabs.nav-stacked > li > a { + border: 1px solid #ddd; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.nav-tabs.nav-stacked > li:first-child > a { + -webkit-border-top-right-radius: 4px; + border-top-right-radius: 4px; + -webkit-border-top-left-radius: 4px; + border-top-left-radius: 4px; + -moz-border-radius-topright: 4px; + -moz-border-radius-topleft: 4px; +} + +.nav-tabs.nav-stacked > li:last-child > a { + -webkit-border-bottom-right-radius: 4px; + border-bottom-right-radius: 4px; + -webkit-border-bottom-left-radius: 4px; + border-bottom-left-radius: 4px; + -moz-border-radius-bottomright: 4px; + -moz-border-radius-bottomleft: 4px; +} + +.nav-tabs.nav-stacked > li > a:hover { + z-index: 2; + border-color: #ddd; +} + +.nav-pills.nav-stacked > li > a { + margin-bottom: 3px; +} + +.nav-pills.nav-stacked > li:last-child > a { + margin-bottom: 1px; +} + +.nav-tabs .dropdown-menu { + -webkit-border-radius: 0 0 6px 6px; + -moz-border-radius: 0 0 6px 6px; + border-radius: 0 0 6px 6px; +} + +.nav-pills .dropdown-menu { + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; +} + +.nav .dropdown-toggle .caret { + margin-top: 6px; + border-top-color: #0088cc; + border-bottom-color: #0088cc; +} + +.nav .dropdown-toggle:hover .caret { + border-top-color: #005580; + border-bottom-color: #005580; +} + +/* move down carets for tabs */ + +.nav-tabs .dropdown-toggle .caret { + margin-top: 8px; +} + +.nav .active .dropdown-toggle .caret { + border-top-color: #fff; + border-bottom-color: #fff; +} + +.nav-tabs .active .dropdown-toggle .caret { + border-top-color: #555555; + border-bottom-color: #555555; +} + +.nav > .dropdown.active > a:hover { + cursor: pointer; +} + +.nav-tabs .open .dropdown-toggle, +.nav-pills .open .dropdown-toggle, +.nav > li.dropdown.open.active > a:hover { + color: #ffffff; + background-color: #999999; + border-color: #999999; +} + +.nav li.dropdown.open .caret, +.nav li.dropdown.open.active .caret, +.nav li.dropdown.open a:hover .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; + opacity: 1; + filter: alpha(opacity=100); +} + +.tabs-stacked .open > a:hover { + border-color: #999999; +} + +.tabbable { + *zoom: 1; +} + +.tabbable:before, +.tabbable:after { + display: table; + line-height: 0; + content: ""; +} + +.tabbable:after { + clear: both; +} + +.tab-content { + overflow: auto; +} + +.tabs-below > .nav-tabs, +.tabs-right > .nav-tabs, +.tabs-left > .nav-tabs { + border-bottom: 0; +} + +.tab-content > .tab-pane, +.pill-content > .pill-pane { + display: none; +} + +.tab-content > .active, +.pill-content > .active { + display: block; +} + +.tabs-below > .nav-tabs { + border-top: 1px solid #ddd; +} + +.tabs-below > .nav-tabs > li { + margin-top: -1px; + margin-bottom: 0; +} + +.tabs-below > .nav-tabs > li > a { + -webkit-border-radius: 0 0 4px 4px; + -moz-border-radius: 0 0 4px 4px; + border-radius: 0 0 4px 4px; +} + +.tabs-below > .nav-tabs > li > a:hover { + border-top-color: #ddd; + border-bottom-color: transparent; +} + +.tabs-below > .nav-tabs > .active > a, +.tabs-below > .nav-tabs > .active > a:hover { + border-color: transparent #ddd #ddd #ddd; +} + +.tabs-left > .nav-tabs > li, +.tabs-right > .nav-tabs > li { + float: none; +} + +.tabs-left > .nav-tabs > li > a, +.tabs-right > .nav-tabs > li > a { + min-width: 74px; + margin-right: 0; + margin-bottom: 3px; +} + +.tabs-left > .nav-tabs { + float: left; + margin-right: 19px; + border-right: 1px solid #ddd; +} + +.tabs-left > .nav-tabs > li > a { + margin-right: -1px; + -webkit-border-radius: 4px 0 0 4px; + -moz-border-radius: 4px 0 0 4px; + border-radius: 4px 0 0 4px; +} + +.tabs-left > .nav-tabs > li > a:hover { + border-color: #eeeeee #dddddd #eeeeee #eeeeee; +} + +.tabs-left > .nav-tabs .active > a, +.tabs-left > .nav-tabs .active > a:hover { + border-color: #ddd transparent #ddd #ddd; + *border-right-color: #ffffff; +} + +.tabs-right > .nav-tabs { + float: right; + margin-left: 19px; + border-left: 1px solid #ddd; +} + +.tabs-right > .nav-tabs > li > a { + margin-left: -1px; + -webkit-border-radius: 0 4px 4px 0; + -moz-border-radius: 0 4px 4px 0; + border-radius: 0 4px 4px 0; +} + +.tabs-right > .nav-tabs > li > a:hover { + border-color: #eeeeee #eeeeee #eeeeee #dddddd; +} + +.tabs-right > .nav-tabs .active > a, +.tabs-right > .nav-tabs .active > a:hover { + border-color: #ddd #ddd #ddd transparent; + *border-left-color: #ffffff; +} + +.nav > .disabled > a { + color: #999999; +} + +.nav > .disabled > a:hover { + text-decoration: none; + cursor: default; + background-color: transparent; +} + +.navbar { + *position: relative; + *z-index: 2; + margin-bottom: 20px; + overflow: visible; +} + +.navbar-inner { + min-height: 40px; + padding-right: 20px; + padding-left: 20px; + background-color: #fafafa; + background-image: -moz-linear-gradient(top, #ffffff, #f2f2f2); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#f2f2f2)); + background-image: -webkit-linear-gradient(top, #ffffff, #f2f2f2); + background-image: -o-linear-gradient(top, #ffffff, #f2f2f2); + background-image: linear-gradient(to bottom, #ffffff, #f2f2f2); + background-repeat: repeat-x; + border: 1px solid #d4d4d4; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff2f2f2', GradientType=0); + *zoom: 1; + -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); + -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); + box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); +} + +.navbar-inner:before, +.navbar-inner:after { + display: table; + line-height: 0; + content: ""; +} + +.navbar-inner:after { + clear: both; +} + +.navbar .container { + width: auto; +} + +.nav-collapse.collapse { + height: auto; + overflow: visible; +} + +.navbar .brand { + display: block; + float: left; + padding: 10px 20px 10px; + margin-left: -20px; + font-size: 20px; + font-weight: 200; + color: #777777; + text-shadow: 0 1px 0 #ffffff; +} + +.navbar .brand:hover { + text-decoration: none; +} + +.navbar-text { + margin-bottom: 0; + line-height: 40px; + color: #777777; +} + +.navbar-link { + color: #777777; +} + +.navbar-link:hover { + color: #333333; +} + +.navbar .divider-vertical { + height: 40px; + margin: 0 9px; + border-right: 1px solid #ffffff; + border-left: 1px solid #f2f2f2; +} + +.navbar .btn, +.navbar .btn-group { + margin-top: 5px; +} + +.navbar .btn-group .btn, +.navbar .input-prepend .btn, +.navbar .input-append .btn { + margin-top: 0; +} + +.navbar-form { + margin-bottom: 0; + *zoom: 1; +} + +.navbar-form:before, +.navbar-form:after { + display: table; + line-height: 0; + content: ""; +} + +.navbar-form:after { + clear: both; +} + +.navbar-form input, +.navbar-form select, +.navbar-form .radio, +.navbar-form .checkbox { + margin-top: 5px; +} + +.navbar-form input, +.navbar-form select, +.navbar-form .btn { + display: inline-block; + margin-bottom: 0; +} + +.navbar-form input[type="image"], +.navbar-form input[type="checkbox"], +.navbar-form input[type="radio"] { + margin-top: 3px; +} + +.navbar-form .input-append, +.navbar-form .input-prepend { + margin-top: 5px; + white-space: nowrap; +} + +.navbar-form .input-append input, +.navbar-form .input-prepend input { + margin-top: 0; +} + +.navbar-search { + position: relative; + float: left; + margin-top: 5px; + margin-bottom: 0; +} + +.navbar-search .search-query { + padding: 4px 14px; + margin-bottom: 0; + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 13px; + font-weight: normal; + line-height: 1; + -webkit-border-radius: 15px; + -moz-border-radius: 15px; + border-radius: 15px; +} + +.navbar-static-top { + position: static; + margin-bottom: 0; +} + +.navbar-static-top .navbar-inner { + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.navbar-fixed-top, +.navbar-fixed-bottom { + position: fixed; + right: 0; + left: 0; + z-index: 1030; + margin-bottom: 0; +} + +.navbar-fixed-top .navbar-inner, +.navbar-static-top .navbar-inner { + border-width: 0 0 1px; +} + +.navbar-fixed-bottom .navbar-inner { + border-width: 1px 0 0; +} + +.navbar-fixed-top .navbar-inner, +.navbar-fixed-bottom .navbar-inner { + padding-right: 0; + padding-left: 0; + -webkit-border-radius: 0; + -moz-border-radius: 0; + border-radius: 0; +} + +.navbar-static-top .container, +.navbar-fixed-top .container, +.navbar-fixed-bottom .container { + width: 940px; +} + +.navbar-fixed-top { + top: 0; +} + +.navbar-fixed-top .navbar-inner, +.navbar-static-top .navbar-inner { + -webkit-box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); + -moz-box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); + box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); +} + +.navbar-fixed-bottom { + bottom: 0; +} + +.navbar-fixed-bottom .navbar-inner { + -webkit-box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); + -moz-box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); + box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); +} + +.navbar .nav { + position: relative; + left: 0; + display: block; + float: left; + margin: 0 10px 0 0; +} + +.navbar .nav.pull-right { + float: right; + margin-right: 0; +} + +.navbar .nav > li { + float: left; +} + +.navbar .nav > li > a { + float: none; + padding: 10px 15px 10px; + color: #777777; + text-decoration: none; + text-shadow: 0 1px 0 #ffffff; +} + +.navbar .nav .dropdown-toggle .caret { + margin-top: 8px; +} + +.navbar .nav > li > a:focus, +.navbar .nav > li > a:hover { + color: #333333; + text-decoration: none; + background-color: transparent; +} + +.navbar .nav > .active > a, +.navbar .nav > .active > a:hover, +.navbar .nav > .active > a:focus { + color: #555555; + text-decoration: none; + background-color: #e5e5e5; + -webkit-box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); + -moz-box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); +} + +.navbar .btn-navbar { + display: none; + float: right; + padding: 7px 10px; + margin-right: 5px; + margin-left: 5px; + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #ededed; + *background-color: #e5e5e5; + background-image: -moz-linear-gradient(top, #f2f2f2, #e5e5e5); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f2f2f2), to(#e5e5e5)); + background-image: -webkit-linear-gradient(top, #f2f2f2, #e5e5e5); + background-image: -o-linear-gradient(top, #f2f2f2, #e5e5e5); + background-image: linear-gradient(to bottom, #f2f2f2, #e5e5e5); + background-repeat: repeat-x; + border-color: #e5e5e5 #e5e5e5 #bfbfbf; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2f2f2', endColorstr='#ffe5e5e5', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); + -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); +} + +.navbar .btn-navbar:hover, +.navbar .btn-navbar:active, +.navbar .btn-navbar.active, +.navbar .btn-navbar.disabled, +.navbar .btn-navbar[disabled] { + color: #ffffff; + background-color: #e5e5e5; + *background-color: #d9d9d9; +} + +.navbar .btn-navbar:active, +.navbar .btn-navbar.active { + background-color: #cccccc \9; +} + +.navbar .btn-navbar .icon-bar { + display: block; + width: 18px; + height: 2px; + background-color: #f5f5f5; + -webkit-border-radius: 1px; + -moz-border-radius: 1px; + border-radius: 1px; + -webkit-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); + -moz-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); + box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); +} + +.btn-navbar .icon-bar + .icon-bar { + margin-top: 3px; +} + +.navbar .nav > li > .dropdown-menu:before { + position: absolute; + top: -7px; + left: 9px; + display: inline-block; + border-right: 7px solid transparent; + border-bottom: 7px solid #ccc; + border-left: 7px solid transparent; + border-bottom-color: rgba(0, 0, 0, 0.2); + content: ''; +} + +.navbar .nav > li > .dropdown-menu:after { + position: absolute; + top: -6px; + left: 10px; + display: inline-block; + border-right: 6px solid transparent; + border-bottom: 6px solid #ffffff; + border-left: 6px solid transparent; + content: ''; +} + +.navbar-fixed-bottom .nav > li > .dropdown-menu:before { + top: auto; + bottom: -7px; + border-top: 7px solid #ccc; + border-bottom: 0; + border-top-color: rgba(0, 0, 0, 0.2); +} + +.navbar-fixed-bottom .nav > li > .dropdown-menu:after { + top: auto; + bottom: -6px; + border-top: 6px solid #ffffff; + border-bottom: 0; +} + +.navbar .nav li.dropdown > a:hover .caret { + border-top-color: #555555; + border-bottom-color: #555555; +} + +.navbar .nav li.dropdown.open > .dropdown-toggle, +.navbar .nav li.dropdown.active > .dropdown-toggle, +.navbar .nav li.dropdown.open.active > .dropdown-toggle { + color: #555555; + background-color: #e5e5e5; +} + +.navbar .nav li.dropdown > .dropdown-toggle .caret { + border-top-color: #777777; + border-bottom-color: #777777; +} + +.navbar .nav li.dropdown.open > .dropdown-toggle .caret, +.navbar .nav li.dropdown.active > .dropdown-toggle .caret, +.navbar .nav li.dropdown.open.active > .dropdown-toggle .caret { + border-top-color: #555555; + border-bottom-color: #555555; +} + +.navbar .pull-right > li > .dropdown-menu, +.navbar .nav > li > .dropdown-menu.pull-right { + right: 0; + left: auto; +} + +.navbar .pull-right > li > .dropdown-menu:before, +.navbar .nav > li > .dropdown-menu.pull-right:before { + right: 12px; + left: auto; +} + +.navbar .pull-right > li > .dropdown-menu:after, +.navbar .nav > li > .dropdown-menu.pull-right:after { + right: 13px; + left: auto; +} + +.navbar .pull-right > li > .dropdown-menu .dropdown-menu, +.navbar .nav > li > .dropdown-menu.pull-right .dropdown-menu { + right: 100%; + left: auto; + margin-right: -1px; + margin-left: 0; + -webkit-border-radius: 6px 0 6px 6px; + -moz-border-radius: 6px 0 6px 6px; + border-radius: 6px 0 6px 6px; +} + +.navbar-inverse .navbar-inner { + background-color: #1b1b1b; + background-image: -moz-linear-gradient(top, #222222, #111111); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#222222), to(#111111)); + background-image: -webkit-linear-gradient(top, #222222, #111111); + background-image: -o-linear-gradient(top, #222222, #111111); + background-image: linear-gradient(to bottom, #222222, #111111); + background-repeat: repeat-x; + border-color: #252525; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222', endColorstr='#ff111111', GradientType=0); +} + +.navbar-inverse .brand, +.navbar-inverse .nav > li > a { + color: #999999; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); +} + +.navbar-inverse .brand:hover, +.navbar-inverse .nav > li > a:hover { + color: #ffffff; +} + +.navbar-inverse .brand { + color: #999999; +} + +.navbar-inverse .navbar-text { + color: #999999; +} + +.navbar-inverse .nav > li > a:focus, +.navbar-inverse .nav > li > a:hover { + color: #ffffff; + background-color: transparent; +} + +.navbar-inverse .nav .active > a, +.navbar-inverse .nav .active > a:hover, +.navbar-inverse .nav .active > a:focus { + color: #ffffff; + background-color: #111111; +} + +.navbar-inverse .navbar-link { + color: #999999; +} + +.navbar-inverse .navbar-link:hover { + color: #ffffff; +} + +.navbar-inverse .divider-vertical { + border-right-color: #222222; + border-left-color: #111111; +} + +.navbar-inverse .nav li.dropdown.open > .dropdown-toggle, +.navbar-inverse .nav li.dropdown.active > .dropdown-toggle, +.navbar-inverse .nav li.dropdown.open.active > .dropdown-toggle { + color: #ffffff; + background-color: #111111; +} + +.navbar-inverse .nav li.dropdown > a:hover .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.navbar-inverse .nav li.dropdown > .dropdown-toggle .caret { + border-top-color: #999999; + border-bottom-color: #999999; +} + +.navbar-inverse .nav li.dropdown.open > .dropdown-toggle .caret, +.navbar-inverse .nav li.dropdown.active > .dropdown-toggle .caret, +.navbar-inverse .nav li.dropdown.open.active > .dropdown-toggle .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.navbar-inverse .navbar-search .search-query { + color: #ffffff; + background-color: #515151; + border-color: #111111; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); + -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); + -webkit-transition: none; + -moz-transition: none; + -o-transition: none; + transition: none; +} + +.navbar-inverse .navbar-search .search-query:-moz-placeholder { + color: #cccccc; +} + +.navbar-inverse .navbar-search .search-query:-ms-input-placeholder { + color: #cccccc; +} + +.navbar-inverse .navbar-search .search-query::-webkit-input-placeholder { + color: #cccccc; +} + +.navbar-inverse .navbar-search .search-query:focus, +.navbar-inverse .navbar-search .search-query.focused { + padding: 5px 15px; + color: #333333; + text-shadow: 0 1px 0 #ffffff; + background-color: #ffffff; + border: 0; + outline: 0; + -webkit-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); + -moz-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); + box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); +} + +.navbar-inverse .btn-navbar { + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #0e0e0e; + *background-color: #040404; + background-image: -moz-linear-gradient(top, #151515, #040404); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#151515), to(#040404)); + background-image: -webkit-linear-gradient(top, #151515, #040404); + background-image: -o-linear-gradient(top, #151515, #040404); + background-image: linear-gradient(to bottom, #151515, #040404); + background-repeat: repeat-x; + border-color: #040404 #040404 #000000; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff151515', endColorstr='#ff040404', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.navbar-inverse .btn-navbar:hover, +.navbar-inverse .btn-navbar:active, +.navbar-inverse .btn-navbar.active, +.navbar-inverse .btn-navbar.disabled, +.navbar-inverse .btn-navbar[disabled] { + color: #ffffff; + background-color: #040404; + *background-color: #000000; +} + +.navbar-inverse .btn-navbar:active, +.navbar-inverse .btn-navbar.active { + background-color: #000000 \9; +} + +.breadcrumb { + padding: 8px 15px; + margin: 0 0 20px; + list-style: none; + background-color: #f5f5f5; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.breadcrumb > li { + display: inline-block; + *display: inline; + text-shadow: 0 1px 0 #ffffff; + *zoom: 1; +} + +.breadcrumb > li > .divider { + padding: 0 5px; + color: #ccc; +} + +.breadcrumb > .active { + color: #999999; +} + +.pagination { + margin: 20px 0; +} + +.pagination ul { + display: inline-block; + *display: inline; + margin-bottom: 0; + margin-left: 0; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + *zoom: 1; + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); + -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.pagination ul > li { + display: inline; +} + +.pagination ul > li > a, +.pagination ul > li > span { + float: left; + padding: 4px 12px; + line-height: 20px; + text-decoration: none; + background-color: #ffffff; + border: 1px solid #dddddd; + border-left-width: 0; +} + +.pagination ul > li > a:hover, +.pagination ul > .active > a, +.pagination ul > .active > span { + background-color: #f5f5f5; +} + +.pagination ul > .active > a, +.pagination ul > .active > span { + color: #999999; + cursor: default; +} + +.pagination ul > .disabled > span, +.pagination ul > .disabled > a, +.pagination ul > .disabled > a:hover { + color: #999999; + cursor: default; + background-color: transparent; +} + +.pagination ul > li:first-child > a, +.pagination ul > li:first-child > span { + border-left-width: 1px; + -webkit-border-bottom-left-radius: 4px; + border-bottom-left-radius: 4px; + -webkit-border-top-left-radius: 4px; + border-top-left-radius: 4px; + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-topleft: 4px; +} + +.pagination ul > li:last-child > a, +.pagination ul > li:last-child > span { + -webkit-border-top-right-radius: 4px; + border-top-right-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + border-bottom-right-radius: 4px; + -moz-border-radius-topright: 4px; + -moz-border-radius-bottomright: 4px; +} + +.pagination-centered { + text-align: center; +} + +.pagination-right { + text-align: right; +} + +.pagination-large ul > li > a, +.pagination-large ul > li > span { + padding: 11px 19px; + font-size: 17.5px; +} + +.pagination-large ul > li:first-child > a, +.pagination-large ul > li:first-child > span { + -webkit-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -webkit-border-top-left-radius: 6px; + border-top-left-radius: 6px; + -moz-border-radius-bottomleft: 6px; + -moz-border-radius-topleft: 6px; +} + +.pagination-large ul > li:last-child > a, +.pagination-large ul > li:last-child > span { + -webkit-border-top-right-radius: 6px; + border-top-right-radius: 6px; + -webkit-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + -moz-border-radius-topright: 6px; + -moz-border-radius-bottomright: 6px; +} + +.pagination-mini ul > li:first-child > a, +.pagination-small ul > li:first-child > a, +.pagination-mini ul > li:first-child > span, +.pagination-small ul > li:first-child > span { + -webkit-border-bottom-left-radius: 3px; + border-bottom-left-radius: 3px; + -webkit-border-top-left-radius: 3px; + border-top-left-radius: 3px; + -moz-border-radius-bottomleft: 3px; + -moz-border-radius-topleft: 3px; +} + +.pagination-mini ul > li:last-child > a, +.pagination-small ul > li:last-child > a, +.pagination-mini ul > li:last-child > span, +.pagination-small ul > li:last-child > span { + -webkit-border-top-right-radius: 3px; + border-top-right-radius: 3px; + -webkit-border-bottom-right-radius: 3px; + border-bottom-right-radius: 3px; + -moz-border-radius-topright: 3px; + -moz-border-radius-bottomright: 3px; +} + +.pagination-small ul > li > a, +.pagination-small ul > li > span { + padding: 2px 10px; + font-size: 11.9px; +} + +.pagination-mini ul > li > a, +.pagination-mini ul > li > span { + padding: 0 6px; + font-size: 10.5px; +} + +.pager { + margin: 20px 0; + text-align: center; + list-style: none; + *zoom: 1; +} + +.pager:before, +.pager:after { + display: table; + line-height: 0; + content: ""; +} + +.pager:after { + clear: both; +} + +.pager li { + display: inline; +} + +.pager li > a, +.pager li > span { + display: inline-block; + padding: 5px 14px; + background-color: #fff; + border: 1px solid #ddd; + -webkit-border-radius: 15px; + -moz-border-radius: 15px; + border-radius: 15px; +} + +.pager li > a:hover { + text-decoration: none; + background-color: #f5f5f5; +} + +.pager .next > a, +.pager .next > span { + float: right; +} + +.pager .previous > a, +.pager .previous > span { + float: left; +} + +.pager .disabled > a, +.pager .disabled > a:hover, +.pager .disabled > span { + color: #999999; + cursor: default; + background-color: #fff; +} + +.modal-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1040; + background-color: #000000; +} + +.modal-backdrop.fade { + opacity: 0; +} + +.modal-backdrop, +.modal-backdrop.fade.in { + opacity: 0.8; + filter: alpha(opacity=80); +} + +.modal { + position: fixed; + top: 10%; + left: 50%; + z-index: 1050; + width: 560px; + margin-left: -280px; + background-color: #ffffff; + border: 1px solid #999; + border: 1px solid rgba(0, 0, 0, 0.3); + *border: 1px solid #999; + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; + outline: none; + -webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); + -moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); + box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); + -webkit-background-clip: padding-box; + -moz-background-clip: padding-box; + background-clip: padding-box; +} + +.modal.fade { + top: -25%; + -webkit-transition: opacity 0.3s linear, top 0.3s ease-out; + -moz-transition: opacity 0.3s linear, top 0.3s ease-out; + -o-transition: opacity 0.3s linear, top 0.3s ease-out; + transition: opacity 0.3s linear, top 0.3s ease-out; +} + +.modal.fade.in { + top: 10%; +} + +.modal-header { + padding: 9px 15px; + border-bottom: 1px solid #eee; +} + +.modal-header .close { + margin-top: 2px; +} + +.modal-header h3 { + margin: 0; + line-height: 30px; +} + +.modal-body { + position: relative; + max-height: 400px; + padding: 15px; + overflow-y: auto; +} + +.modal-form { + margin-bottom: 0; +} + +.modal-footer { + padding: 14px 15px 15px; + margin-bottom: 0; + text-align: right; + background-color: #f5f5f5; + border-top: 1px solid #ddd; + -webkit-border-radius: 0 0 6px 6px; + -moz-border-radius: 0 0 6px 6px; + border-radius: 0 0 6px 6px; + *zoom: 1; + -webkit-box-shadow: inset 0 1px 0 #ffffff; + -moz-box-shadow: inset 0 1px 0 #ffffff; + box-shadow: inset 0 1px 0 #ffffff; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + line-height: 0; + content: ""; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer .btn + .btn { + margin-bottom: 0; + margin-left: 5px; +} + +.modal-footer .btn-group .btn + .btn { + margin-left: -1px; +} + +.modal-footer .btn-block + .btn-block { + margin-left: 0; +} + +.tooltip { + position: absolute; + z-index: 1030; + display: block; + padding: 5px; + font-size: 11px; + opacity: 0; + filter: alpha(opacity=0); + visibility: visible; +} + +.tooltip.in { + opacity: 0.8; + filter: alpha(opacity=80); +} + +.tooltip.top { + margin-top: -3px; +} + +.tooltip.right { + margin-left: 3px; +} + +.tooltip.bottom { + margin-top: 3px; +} + +.tooltip.left { + margin-left: -3px; +} + +.tooltip-inner { + max-width: 200px; + padding: 3px 8px; + color: #ffffff; + text-align: center; + text-decoration: none; + background-color: #000000; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.tooltip-arrow { + position: absolute; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; +} + +.tooltip.top .tooltip-arrow { + bottom: 0; + left: 50%; + margin-left: -5px; + border-top-color: #000000; + border-width: 5px 5px 0; +} + +.tooltip.right .tooltip-arrow { + top: 50%; + left: 0; + margin-top: -5px; + border-right-color: #000000; + border-width: 5px 5px 5px 0; +} + +.tooltip.left .tooltip-arrow { + top: 50%; + right: 0; + margin-top: -5px; + border-left-color: #000000; + border-width: 5px 0 5px 5px; +} + +.tooltip.bottom .tooltip-arrow { + top: 0; + left: 50%; + margin-left: -5px; + border-bottom-color: #000000; + border-width: 0 5px 5px; +} + +.popover { + position: absolute; + top: 0; + left: 0; + z-index: 1010; + display: none; + width: 236px; + padding: 1px; + text-align: left; + white-space: normal; + background-color: #ffffff; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.2); + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; + -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + -webkit-background-clip: padding-box; + -moz-background-clip: padding; + background-clip: padding-box; +} + +.popover.top { + margin-top: -10px; +} + +.popover.right { + margin-left: 10px; +} + +.popover.bottom { + margin-top: 10px; +} + +.popover.left { + margin-left: -10px; +} + +.popover-title { + padding: 8px 14px; + margin: 0; + font-size: 14px; + font-weight: normal; + line-height: 18px; + background-color: #f7f7f7; + border-bottom: 1px solid #ebebeb; + -webkit-border-radius: 5px 5px 0 0; + -moz-border-radius: 5px 5px 0 0; + border-radius: 5px 5px 0 0; +} + +.popover-content { + padding: 9px 14px; +} + +.popover .arrow, +.popover .arrow:after { + position: absolute; + display: block; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; +} + +.popover .arrow { + border-width: 11px; +} + +.popover .arrow:after { + border-width: 10px; + content: ""; +} + +.popover.top .arrow { + bottom: -11px; + left: 50%; + margin-left: -11px; + border-top-color: #999; + border-top-color: rgba(0, 0, 0, 0.25); + border-bottom-width: 0; +} + +.popover.top .arrow:after { + bottom: 1px; + margin-left: -10px; + border-top-color: #ffffff; + border-bottom-width: 0; +} + +.popover.right .arrow { + top: 50%; + left: -11px; + margin-top: -11px; + border-right-color: #999; + border-right-color: rgba(0, 0, 0, 0.25); + border-left-width: 0; +} + +.popover.right .arrow:after { + bottom: -10px; + left: 1px; + border-right-color: #ffffff; + border-left-width: 0; +} + +.popover.bottom .arrow { + top: -11px; + left: 50%; + margin-left: -11px; + border-bottom-color: #999; + border-bottom-color: rgba(0, 0, 0, 0.25); + border-top-width: 0; +} + +.popover.bottom .arrow:after { + top: 1px; + margin-left: -10px; + border-bottom-color: #ffffff; + border-top-width: 0; +} + +.popover.left .arrow { + top: 50%; + right: -11px; + margin-top: -11px; + border-left-color: #999; + border-left-color: rgba(0, 0, 0, 0.25); + border-right-width: 0; +} + +.popover.left .arrow:after { + right: 1px; + bottom: -10px; + border-left-color: #ffffff; + border-right-width: 0; +} + +.thumbnails { + margin-left: -20px; + list-style: none; + *zoom: 1; +} + +.thumbnails:before, +.thumbnails:after { + display: table; + line-height: 0; + content: ""; +} + +.thumbnails:after { + clear: both; +} + +.row-fluid .thumbnails { + margin-left: 0; +} + +.thumbnails > li { + float: left; + margin-bottom: 20px; + margin-left: 20px; +} + +.thumbnail { + display: block; + padding: 4px; + line-height: 20px; + border: 1px solid #ddd; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); + -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); + -webkit-transition: all 0.2s ease-in-out; + -moz-transition: all 0.2s ease-in-out; + -o-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; +} + +a.thumbnail:hover { + border-color: #0088cc; + -webkit-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); + -moz-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); + box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); +} + +.thumbnail > img { + display: block; + max-width: 100%; + margin-right: auto; + margin-left: auto; +} + +.thumbnail .caption { + padding: 9px; + color: #555555; +} + +.media, +.media-body { + overflow: hidden; + *overflow: visible; + zoom: 1; +} + +.media, +.media .media { + margin-top: 15px; +} + +.media:first-child { + margin-top: 0; +} + +.media-object { + display: block; +} + +.media-heading { + margin: 0 0 5px; +} + +.media .pull-left { + margin-right: 10px; +} + +.media .pull-right { + margin-left: 10px; +} + +.media-list { + margin-left: 0; + list-style: none; +} + +.label, +.badge { + display: inline-block; + padding: 2px 4px; + font-size: 11.844px; + font-weight: bold; + line-height: 14px; + color: #ffffff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + white-space: nowrap; + vertical-align: baseline; + background-color: #999999; +} + +.label { + -webkit-border-radius: 3px; + -moz-border-radius: 3px; + border-radius: 3px; +} + +.badge { + padding-right: 9px; + padding-left: 9px; + -webkit-border-radius: 9px; + -moz-border-radius: 9px; + border-radius: 9px; +} + +.label:empty, +.badge:empty { + display: none; +} + +a.label:hover, +a.badge:hover { + color: #ffffff; + text-decoration: none; + cursor: pointer; +} + +.label-important, +.badge-important { + background-color: #b94a48; +} + +.label-important[href], +.badge-important[href] { + background-color: #953b39; +} + +.label-warning, +.badge-warning { + background-color: #f89406; +} + +.label-warning[href], +.badge-warning[href] { + background-color: #c67605; +} + +.label-success, +.badge-success { + background-color: #468847; +} + +.label-success[href], +.badge-success[href] { + background-color: #356635; +} + +.label-info, +.badge-info { + background-color: #3a87ad; +} + +.label-info[href], +.badge-info[href] { + background-color: #2d6987; +} + +.label-inverse, +.badge-inverse { + background-color: #333333; +} + +.label-inverse[href], +.badge-inverse[href] { + background-color: #1a1a1a; +} + +.btn .label, +.btn .badge { + position: relative; + top: -1px; +} + +.btn-mini .label, +.btn-mini .badge { + top: 0; +} + +@-webkit-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +@-moz-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +@-ms-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +@-o-keyframes progress-bar-stripes { + from { + background-position: 0 0; + } + to { + background-position: 40px 0; + } +} + +@keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +.progress { + height: 20px; + margin-bottom: 20px; + overflow: hidden; + background-color: #f7f7f7; + background-image: -moz-linear-gradient(top, #f5f5f5, #f9f9f9); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f5f5f5), to(#f9f9f9)); + background-image: -webkit-linear-gradient(top, #f5f5f5, #f9f9f9); + background-image: -o-linear-gradient(top, #f5f5f5, #f9f9f9); + background-image: linear-gradient(to bottom, #f5f5f5, #f9f9f9); + background-repeat: repeat-x; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#fff9f9f9', GradientType=0); + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); +} + +.progress .bar { + float: left; + width: 0; + height: 100%; + font-size: 12px; + color: #ffffff; + text-align: center; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #0e90d2; + background-image: -moz-linear-gradient(top, #149bdf, #0480be); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#149bdf), to(#0480be)); + background-image: -webkit-linear-gradient(top, #149bdf, #0480be); + background-image: -o-linear-gradient(top, #149bdf, #0480be); + background-image: linear-gradient(to bottom, #149bdf, #0480be); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff149bdf', endColorstr='#ff0480be', GradientType=0); + -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -moz-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + -webkit-transition: width 0.6s ease; + -moz-transition: width 0.6s ease; + -o-transition: width 0.6s ease; + transition: width 0.6s ease; +} + +.progress .bar + .bar { + -webkit-box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -moz-box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); + box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); +} + +.progress-striped .bar { + background-color: #149bdf; + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + -webkit-background-size: 40px 40px; + -moz-background-size: 40px 40px; + -o-background-size: 40px 40px; + background-size: 40px 40px; +} + +.progress.active .bar { + -webkit-animation: progress-bar-stripes 2s linear infinite; + -moz-animation: progress-bar-stripes 2s linear infinite; + -ms-animation: progress-bar-stripes 2s linear infinite; + -o-animation: progress-bar-stripes 2s linear infinite; + animation: progress-bar-stripes 2s linear infinite; +} + +.progress-danger .bar, +.progress .bar-danger { + background-color: #dd514c; + background-image: -moz-linear-gradient(top, #ee5f5b, #c43c35); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#c43c35)); + background-image: -webkit-linear-gradient(top, #ee5f5b, #c43c35); + background-image: -o-linear-gradient(top, #ee5f5b, #c43c35); + background-image: linear-gradient(to bottom, #ee5f5b, #c43c35); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffc43c35', GradientType=0); +} + +.progress-danger.progress-striped .bar, +.progress-striped .bar-danger { + background-color: #ee5f5b; + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-success .bar, +.progress .bar-success { + background-color: #5eb95e; + background-image: -moz-linear-gradient(top, #62c462, #57a957); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#57a957)); + background-image: -webkit-linear-gradient(top, #62c462, #57a957); + background-image: -o-linear-gradient(top, #62c462, #57a957); + background-image: linear-gradient(to bottom, #62c462, #57a957); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff57a957', GradientType=0); +} + +.progress-success.progress-striped .bar, +.progress-striped .bar-success { + background-color: #62c462; + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-info .bar, +.progress .bar-info { + background-color: #4bb1cf; + background-image: -moz-linear-gradient(top, #5bc0de, #339bb9); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#339bb9)); + background-image: -webkit-linear-gradient(top, #5bc0de, #339bb9); + background-image: -o-linear-gradient(top, #5bc0de, #339bb9); + background-image: linear-gradient(to bottom, #5bc0de, #339bb9); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff339bb9', GradientType=0); +} + +.progress-info.progress-striped .bar, +.progress-striped .bar-info { + background-color: #5bc0de; + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-warning .bar, +.progress .bar-warning { + background-color: #faa732; + background-image: -moz-linear-gradient(top, #fbb450, #f89406); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406)); + background-image: -webkit-linear-gradient(top, #fbb450, #f89406); + background-image: -o-linear-gradient(top, #fbb450, #f89406); + background-image: linear-gradient(to bottom, #fbb450, #f89406); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0); +} + +.progress-warning.progress-striped .bar, +.progress-striped .bar-warning { + background-color: #fbb450; + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.accordion { + margin-bottom: 20px; +} + +.accordion-group { + margin-bottom: 2px; + border: 1px solid #e5e5e5; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; + border-radius: 4px; +} + +.accordion-heading { + border-bottom: 0; +} + +.accordion-heading .accordion-toggle { + display: block; + padding: 8px 15px; +} + +.accordion-toggle { + cursor: pointer; +} + +.accordion-inner { + padding: 9px 15px; + border-top: 1px solid #e5e5e5; +} + +.carousel { + position: relative; + margin-bottom: 20px; + line-height: 1; +} + +.carousel-inner { + position: relative; + width: 100%; + overflow: hidden; +} + +.carousel-inner > .item { + position: relative; + display: none; + -webkit-transition: 0.6s ease-in-out left; + -moz-transition: 0.6s ease-in-out left; + -o-transition: 0.6s ease-in-out left; + transition: 0.6s ease-in-out left; +} + +.carousel-inner > .item > img { + display: block; + line-height: 1; +} + +.carousel-inner > .active, +.carousel-inner > .next, +.carousel-inner > .prev { + display: block; +} + +.carousel-inner > .active { + left: 0; +} + +.carousel-inner > .next, +.carousel-inner > .prev { + position: absolute; + top: 0; + width: 100%; +} + +.carousel-inner > .next { + left: 100%; +} + +.carousel-inner > .prev { + left: -100%; +} + +.carousel-inner > .next.left, +.carousel-inner > .prev.right { + left: 0; +} + +.carousel-inner > .active.left { + left: -100%; +} + +.carousel-inner > .active.right { + left: 100%; +} + +.carousel-control { + position: absolute; + top: 40%; + left: 15px; + width: 40px; + height: 40px; + margin-top: -20px; + font-size: 60px; + font-weight: 100; + line-height: 30px; + color: #ffffff; + text-align: center; + background: #222222; + border: 3px solid #ffffff; + -webkit-border-radius: 23px; + -moz-border-radius: 23px; + border-radius: 23px; + opacity: 0.5; + filter: alpha(opacity=50); +} + +.carousel-control.right { + right: 15px; + left: auto; +} + +.carousel-control:hover { + color: #ffffff; + text-decoration: none; + opacity: 0.9; + filter: alpha(opacity=90); +} + +.carousel-caption { + position: absolute; + right: 0; + bottom: 0; + left: 0; + padding: 15px; + background: #333333; + background: rgba(0, 0, 0, 0.75); +} + +.carousel-caption h4, +.carousel-caption p { + line-height: 20px; + color: #ffffff; +} + +.carousel-caption h4 { + margin: 0 0 5px; +} + +.carousel-caption p { + margin-bottom: 0; +} + +.hero-unit { + padding: 60px; + margin-bottom: 30px; + font-size: 18px; + font-weight: 200; + line-height: 30px; + color: inherit; + background-color: #eeeeee; + -webkit-border-radius: 6px; + -moz-border-radius: 6px; + border-radius: 6px; +} + +.hero-unit h1 { + margin-bottom: 0; + font-size: 60px; + line-height: 1; + letter-spacing: -1px; + color: inherit; +} + +.hero-unit li { + line-height: 30px; +} + +.pull-right { + float: right; +} + +.pull-left { + float: left; +} + +.hide { + display: none; +} + +.show { + display: block; +} + +.invisible { + visibility: hidden; +} + +.affix { + position: fixed; +} diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.min.css b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.min.css new file mode 100644 index 0000000..140f731 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/bootstrap/css/bootstrap.min.css @@ -0,0 +1,9 @@ +/*! + * Bootstrap v2.2.2 + * + * Copyright 2012 Twitter, Inc + * Licensed under the Apache License v2.0 + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Designed and built with all the love in the world @twitter by @mdo and @fat. + */article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio,canvas,video{display:inline-block;*display:inline;*zoom:1}audio:not([controls]){display:none}html{font-size:100%;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}a:focus{outline:thin dotted #333;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}a:hover,a:active{outline:0}sub,sup{position:relative;font-size:75%;line-height:0;vertical-align:baseline}sup{top:-0.5em}sub{bottom:-0.25em}img{width:auto\9;height:auto;max-width:100%;vertical-align:middle;border:0;-ms-interpolation-mode:bicubic}#map_canvas img,.google-maps img{max-width:none}button,input,select,textarea{margin:0;font-size:100%;vertical-align:middle}button,input{*overflow:visible;line-height:normal}button::-moz-focus-inner,input::-moz-focus-inner{padding:0;border:0}button,html input[type="button"],input[type="reset"],input[type="submit"]{cursor:pointer;-webkit-appearance:button}label,select,button,input[type="button"],input[type="reset"],input[type="submit"],input[type="radio"],input[type="checkbox"]{cursor:pointer}input[type="search"]{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;-webkit-appearance:textfield}input[type="search"]::-webkit-search-decoration,input[type="search"]::-webkit-search-cancel-button{-webkit-appearance:none}textarea{overflow:auto;vertical-align:top}@media print{*{color:#000!important;text-shadow:none!important;background:transparent!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}.ir a:after,a[href^="javascript:"]:after,a[href^="#"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100%!important}@page{margin:.5cm}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}}.clearfix{*zoom:1}.clearfix:before,.clearfix:after{display:table;line-height:0;content:""}.clearfix:after{clear:both}.hide-text{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.input-block-level{display:block;width:100%;min-height:30px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}body{margin:0;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:20px;color:#333;background-color:#fff}a{color:#08c;text-decoration:none}a:hover{color:#005580;text-decoration:underline}.img-rounded{-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px}.img-polaroid{padding:4px;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.2);-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.1);-moz-box-shadow:0 1px 3px rgba(0,0,0,0.1);box-shadow:0 1px 3px rgba(0,0,0,0.1)}.img-circle{-webkit-border-radius:500px;-moz-border-radius:500px;border-radius:500px}.row{margin-left:-20px;*zoom:1}.row:before,.row:after{display:table;line-height:0;content:""}.row:after{clear:both}[class*="span"]{float:left;min-height:1px;margin-left:20px}.container,.navbar-static-top .container,.navbar-fixed-top .container,.navbar-fixed-bottom .container{width:940px}.span12{width:940px}.span11{width:860px}.span10{width:780px}.span9{width:700px}.span8{width:620px}.span7{width:540px}.span6{width:460px}.span5{width:380px}.span4{width:300px}.span3{width:220px}.span2{width:140px}.span1{width:60px}.offset12{margin-left:980px}.offset11{margin-left:900px}.offset10{margin-left:820px}.offset9{margin-left:740px}.offset8{margin-left:660px}.offset7{margin-left:580px}.offset6{margin-left:500px}.offset5{margin-left:420px}.offset4{margin-left:340px}.offset3{margin-left:260px}.offset2{margin-left:180px}.offset1{margin-left:100px}.row-fluid{width:100%;*zoom:1}.row-fluid:before,.row-fluid:after{display:table;line-height:0;content:""}.row-fluid:after{clear:both}.row-fluid [class*="span"]{display:block;float:left;width:100%;min-height:30px;margin-left:2.127659574468085%;*margin-left:2.074468085106383%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.row-fluid [class*="span"]:first-child{margin-left:0}.row-fluid .controls-row [class*="span"]+[class*="span"]{margin-left:2.127659574468085%}.row-fluid .span12{width:100%;*width:99.94680851063829%}.row-fluid .span11{width:91.48936170212765%;*width:91.43617021276594%}.row-fluid .span10{width:82.97872340425532%;*width:82.92553191489361%}.row-fluid .span9{width:74.46808510638297%;*width:74.41489361702126%}.row-fluid .span8{width:65.95744680851064%;*width:65.90425531914893%}.row-fluid .span7{width:57.44680851063829%;*width:57.39361702127659%}.row-fluid .span6{width:48.93617021276595%;*width:48.88297872340425%}.row-fluid .span5{width:40.42553191489362%;*width:40.37234042553192%}.row-fluid .span4{width:31.914893617021278%;*width:31.861702127659576%}.row-fluid .span3{width:23.404255319148934%;*width:23.351063829787233%}.row-fluid .span2{width:14.893617021276595%;*width:14.840425531914894%}.row-fluid .span1{width:6.382978723404255%;*width:6.329787234042553%}.row-fluid .offset12{margin-left:104.25531914893617%;*margin-left:104.14893617021275%}.row-fluid .offset12:first-child{margin-left:102.12765957446808%;*margin-left:102.02127659574467%}.row-fluid .offset11{margin-left:95.74468085106382%;*margin-left:95.6382978723404%}.row-fluid .offset11:first-child{margin-left:93.61702127659574%;*margin-left:93.51063829787232%}.row-fluid .offset10{margin-left:87.23404255319149%;*margin-left:87.12765957446807%}.row-fluid .offset10:first-child{margin-left:85.1063829787234%;*margin-left:84.99999999999999%}.row-fluid .offset9{margin-left:78.72340425531914%;*margin-left:78.61702127659572%}.row-fluid .offset9:first-child{margin-left:76.59574468085106%;*margin-left:76.48936170212764%}.row-fluid .offset8{margin-left:70.2127659574468%;*margin-left:70.10638297872339%}.row-fluid .offset8:first-child{margin-left:68.08510638297872%;*margin-left:67.9787234042553%}.row-fluid .offset7{margin-left:61.70212765957446%;*margin-left:61.59574468085106%}.row-fluid .offset7:first-child{margin-left:59.574468085106375%;*margin-left:59.46808510638297%}.row-fluid .offset6{margin-left:53.191489361702125%;*margin-left:53.085106382978715%}.row-fluid .offset6:first-child{margin-left:51.063829787234035%;*margin-left:50.95744680851063%}.row-fluid .offset5{margin-left:44.68085106382979%;*margin-left:44.57446808510638%}.row-fluid .offset5:first-child{margin-left:42.5531914893617%;*margin-left:42.4468085106383%}.row-fluid .offset4{margin-left:36.170212765957444%;*margin-left:36.06382978723405%}.row-fluid .offset4:first-child{margin-left:34.04255319148936%;*margin-left:33.93617021276596%}.row-fluid .offset3{margin-left:27.659574468085104%;*margin-left:27.5531914893617%}.row-fluid .offset3:first-child{margin-left:25.53191489361702%;*margin-left:25.425531914893618%}.row-fluid .offset2{margin-left:19.148936170212764%;*margin-left:19.04255319148936%}.row-fluid .offset2:first-child{margin-left:17.02127659574468%;*margin-left:16.914893617021278%}.row-fluid .offset1{margin-left:10.638297872340425%;*margin-left:10.53191489361702%}.row-fluid .offset1:first-child{margin-left:8.51063829787234%;*margin-left:8.404255319148938%}[class*="span"].hide,.row-fluid [class*="span"].hide{display:none}[class*="span"].pull-right,.row-fluid [class*="span"].pull-right{float:right}.container{margin-right:auto;margin-left:auto;*zoom:1}.container:before,.container:after{display:table;line-height:0;content:""}.container:after{clear:both}.container-fluid{padding-right:20px;padding-left:20px;*zoom:1}.container-fluid:before,.container-fluid:after{display:table;line-height:0;content:""}.container-fluid:after{clear:both}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:21px;font-weight:200;line-height:30px}small{font-size:85%}strong{font-weight:bold}em{font-style:italic}cite{font-style:normal}.muted{color:#999}a.muted:hover{color:#808080}.text-warning{color:#c09853}a.text-warning:hover{color:#a47e3c}.text-error{color:#b94a48}a.text-error:hover{color:#953b39}.text-info{color:#3a87ad}a.text-info:hover{color:#2d6987}.text-success{color:#468847}a.text-success:hover{color:#356635}h1,h2,h3,h4,h5,h6{margin:10px 0;font-family:inherit;font-weight:bold;line-height:20px;color:inherit;text-rendering:optimizelegibility}h1 small,h2 small,h3 small,h4 small,h5 small,h6 small{font-weight:normal;line-height:1;color:#999}h1,h2,h3{line-height:40px}h1{font-size:38.5px}h2{font-size:31.5px}h3{font-size:24.5px}h4{font-size:17.5px}h5{font-size:14px}h6{font-size:11.9px}h1 small{font-size:24.5px}h2 small{font-size:17.5px}h3 small{font-size:14px}h4 small{font-size:14px}.page-header{padding-bottom:9px;margin:20px 0 30px;border-bottom:1px solid #eee}ul,ol{padding:0;margin:0 0 10px 25px}ul ul,ul ol,ol ol,ol ul{margin-bottom:0}li{line-height:20px}ul.unstyled,ol.unstyled{margin-left:0;list-style:none}ul.inline,ol.inline{margin-left:0;list-style:none}ul.inline>li,ol.inline>li{display:inline-block;padding-right:5px;padding-left:5px}dl{margin-bottom:20px}dt,dd{line-height:20px}dt{font-weight:bold}dd{margin-left:10px}.dl-horizontal{*zoom:1}.dl-horizontal:before,.dl-horizontal:after{display:table;line-height:0;content:""}.dl-horizontal:after{clear:both}.dl-horizontal dt{float:left;width:160px;overflow:hidden;clear:left;text-align:right;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}hr{margin:20px 0;border:0;border-top:1px solid #eee;border-bottom:1px solid #fff}abbr[title],abbr[data-original-title]{cursor:help;border-bottom:1px dotted #999}abbr.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:0 0 0 15px;margin:0 0 20px;border-left:5px solid #eee}blockquote p{margin-bottom:0;font-size:16px;font-weight:300;line-height:25px}blockquote small{display:block;line-height:20px;color:#999}blockquote small:before{content:'\2014 \00A0'}blockquote.pull-right{float:right;padding-right:15px;padding-left:0;border-right:5px solid #eee;border-left:0}blockquote.pull-right p,blockquote.pull-right small{text-align:right}blockquote.pull-right small:before{content:''}blockquote.pull-right small:after{content:'\00A0 \2014'}q:before,q:after,blockquote:before,blockquote:after{content:""}address{display:block;margin-bottom:20px;font-style:normal;line-height:20px}code,pre{padding:0 3px 2px;font-family:Monaco,Menlo,Consolas,"Courier New",monospace;font-size:12px;color:#333;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}code{padding:2px 4px;color:#d14;white-space:nowrap;background-color:#f7f7f9;border:1px solid #e1e1e8}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:20px;word-break:break-all;word-wrap:break-word;white-space:pre;white-space:pre-wrap;background-color:#f5f5f5;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.15);-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}pre.prettyprint{margin-bottom:20px}pre code{padding:0;color:inherit;white-space:pre;white-space:pre-wrap;background-color:transparent;border:0}.pre-scrollable{max-height:340px;overflow-y:scroll}form{margin:0 0 20px}fieldset{padding:0;margin:0;border:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:40px;color:#333;border:0;border-bottom:1px solid #e5e5e5}legend small{font-size:15px;color:#999}label,input,button,select,textarea{font-size:14px;font-weight:normal;line-height:20px}input,button,select,textarea{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif}label{display:block;margin-bottom:5px}select,textarea,input[type="text"],input[type="password"],input[type="datetime"],input[type="datetime-local"],input[type="date"],input[type="month"],input[type="time"],input[type="week"],input[type="number"],input[type="email"],input[type="url"],input[type="search"],input[type="tel"],input[type="color"],.uneditable-input{display:inline-block;height:20px;padding:4px 6px;margin-bottom:10px;font-size:14px;line-height:20px;color:#555;vertical-align:middle;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}input,textarea,.uneditable-input{width:206px}textarea{height:auto}textarea,input[type="text"],input[type="password"],input[type="datetime"],input[type="datetime-local"],input[type="date"],input[type="month"],input[type="time"],input[type="week"],input[type="number"],input[type="email"],input[type="url"],input[type="search"],input[type="tel"],input[type="color"],.uneditable-input{background-color:#fff;border:1px solid #ccc;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-webkit-transition:border linear .2s,box-shadow linear .2s;-moz-transition:border linear .2s,box-shadow linear .2s;-o-transition:border linear .2s,box-shadow linear .2s;transition:border linear .2s,box-shadow linear .2s}textarea:focus,input[type="text"]:focus,input[type="password"]:focus,input[type="datetime"]:focus,input[type="datetime-local"]:focus,input[type="date"]:focus,input[type="month"]:focus,input[type="time"]:focus,input[type="week"]:focus,input[type="number"]:focus,input[type="email"]:focus,input[type="url"]:focus,input[type="search"]:focus,input[type="tel"]:focus,input[type="color"]:focus,.uneditable-input:focus{border-color:rgba(82,168,236,0.8);outline:0;outline:thin dotted \9;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 8px rgba(82,168,236,0.6);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 8px rgba(82,168,236,0.6);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 8px rgba(82,168,236,0.6)}input[type="radio"],input[type="checkbox"]{margin:4px 0 0;margin-top:1px \9;*margin-top:0;line-height:normal}input[type="file"],input[type="image"],input[type="submit"],input[type="reset"],input[type="button"],input[type="radio"],input[type="checkbox"]{width:auto}select,input[type="file"]{height:30px;*margin-top:4px;line-height:30px}select{width:220px;background-color:#fff;border:1px solid #ccc}select[multiple],select[size]{height:auto}select:focus,input[type="file"]:focus,input[type="radio"]:focus,input[type="checkbox"]:focus{outline:thin dotted #333;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.uneditable-input,.uneditable-textarea{color:#999;cursor:not-allowed;background-color:#fcfcfc;border-color:#ccc;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,0.025);-moz-box-shadow:inset 0 1px 2px rgba(0,0,0,0.025);box-shadow:inset 0 1px 2px rgba(0,0,0,0.025)}.uneditable-input{overflow:hidden;white-space:nowrap}.uneditable-textarea{width:auto;height:auto}input:-moz-placeholder,textarea:-moz-placeholder{color:#999}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#999}input::-webkit-input-placeholder,textarea::-webkit-input-placeholder{color:#999}.radio,.checkbox{min-height:20px;padding-left:20px}.radio input[type="radio"],.checkbox input[type="checkbox"]{float:left;margin-left:-20px}.controls>.radio:first-child,.controls>.checkbox:first-child{padding-top:5px}.radio.inline,.checkbox.inline{display:inline-block;padding-top:5px;margin-bottom:0;vertical-align:middle}.radio.inline+.radio.inline,.checkbox.inline+.checkbox.inline{margin-left:10px}.input-mini{width:60px}.input-small{width:90px}.input-medium{width:150px}.input-large{width:210px}.input-xlarge{width:270px}.input-xxlarge{width:530px}input[class*="span"],select[class*="span"],textarea[class*="span"],.uneditable-input[class*="span"],.row-fluid input[class*="span"],.row-fluid select[class*="span"],.row-fluid textarea[class*="span"],.row-fluid .uneditable-input[class*="span"]{float:none;margin-left:0}.input-append input[class*="span"],.input-append .uneditable-input[class*="span"],.input-prepend input[class*="span"],.input-prepend .uneditable-input[class*="span"],.row-fluid input[class*="span"],.row-fluid select[class*="span"],.row-fluid textarea[class*="span"],.row-fluid .uneditable-input[class*="span"],.row-fluid .input-prepend [class*="span"],.row-fluid .input-append [class*="span"]{display:inline-block}input,textarea,.uneditable-input{margin-left:0}.controls-row [class*="span"]+[class*="span"]{margin-left:20px}input.span12,textarea.span12,.uneditable-input.span12{width:926px}input.span11,textarea.span11,.uneditable-input.span11{width:846px}input.span10,textarea.span10,.uneditable-input.span10{width:766px}input.span9,textarea.span9,.uneditable-input.span9{width:686px}input.span8,textarea.span8,.uneditable-input.span8{width:606px}input.span7,textarea.span7,.uneditable-input.span7{width:526px}input.span6,textarea.span6,.uneditable-input.span6{width:446px}input.span5,textarea.span5,.uneditable-input.span5{width:366px}input.span4,textarea.span4,.uneditable-input.span4{width:286px}input.span3,textarea.span3,.uneditable-input.span3{width:206px}input.span2,textarea.span2,.uneditable-input.span2{width:126px}input.span1,textarea.span1,.uneditable-input.span1{width:46px}.controls-row{*zoom:1}.controls-row:before,.controls-row:after{display:table;line-height:0;content:""}.controls-row:after{clear:both}.controls-row [class*="span"],.row-fluid .controls-row [class*="span"]{float:left}.controls-row .checkbox[class*="span"],.controls-row .radio[class*="span"]{padding-top:5px}input[disabled],select[disabled],textarea[disabled],input[readonly],select[readonly],textarea[readonly]{cursor:not-allowed;background-color:#eee}input[type="radio"][disabled],input[type="checkbox"][disabled],input[type="radio"][readonly],input[type="checkbox"][readonly]{background-color:transparent}.control-group.warning .control-label,.control-group.warning .help-block,.control-group.warning .help-inline{color:#c09853}.control-group.warning .checkbox,.control-group.warning .radio,.control-group.warning input,.control-group.warning select,.control-group.warning textarea{color:#c09853}.control-group.warning input,.control-group.warning select,.control-group.warning textarea{border-color:#c09853;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075)}.control-group.warning input:focus,.control-group.warning select:focus,.control-group.warning textarea:focus{border-color:#a47e3c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #dbc59e;-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #dbc59e;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #dbc59e}.control-group.warning .input-prepend .add-on,.control-group.warning .input-append .add-on{color:#c09853;background-color:#fcf8e3;border-color:#c09853}.control-group.error .control-label,.control-group.error .help-block,.control-group.error .help-inline{color:#b94a48}.control-group.error .checkbox,.control-group.error .radio,.control-group.error input,.control-group.error select,.control-group.error textarea{color:#b94a48}.control-group.error input,.control-group.error select,.control-group.error textarea{border-color:#b94a48;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075)}.control-group.error input:focus,.control-group.error select:focus,.control-group.error textarea:focus{border-color:#953b39;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #d59392;-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #d59392;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #d59392}.control-group.error .input-prepend .add-on,.control-group.error .input-append .add-on{color:#b94a48;background-color:#f2dede;border-color:#b94a48}.control-group.success .control-label,.control-group.success .help-block,.control-group.success .help-inline{color:#468847}.control-group.success .checkbox,.control-group.success .radio,.control-group.success input,.control-group.success select,.control-group.success textarea{color:#468847}.control-group.success input,.control-group.success select,.control-group.success textarea{border-color:#468847;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075)}.control-group.success input:focus,.control-group.success select:focus,.control-group.success textarea:focus{border-color:#356635;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7aba7b;-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7aba7b;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7aba7b}.control-group.success .input-prepend .add-on,.control-group.success .input-append .add-on{color:#468847;background-color:#dff0d8;border-color:#468847}.control-group.info .control-label,.control-group.info .help-block,.control-group.info .help-inline{color:#3a87ad}.control-group.info .checkbox,.control-group.info .radio,.control-group.info input,.control-group.info select,.control-group.info textarea{color:#3a87ad}.control-group.info input,.control-group.info select,.control-group.info textarea{border-color:#3a87ad;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 1px rgba(0,0,0,0.075)}.control-group.info input:focus,.control-group.info select:focus,.control-group.info textarea:focus{border-color:#2d6987;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7ab5d3;-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7ab5d3;box-shadow:inset 0 1px 1px rgba(0,0,0,0.075),0 0 6px #7ab5d3}.control-group.info .input-prepend .add-on,.control-group.info .input-append .add-on{color:#3a87ad;background-color:#d9edf7;border-color:#3a87ad}input:focus:invalid,textarea:focus:invalid,select:focus:invalid{color:#b94a48;border-color:#ee5f5b}input:focus:invalid:focus,textarea:focus:invalid:focus,select:focus:invalid:focus{border-color:#e9322d;-webkit-box-shadow:0 0 6px #f8b9b7;-moz-box-shadow:0 0 6px #f8b9b7;box-shadow:0 0 6px #f8b9b7}.form-actions{padding:19px 20px 20px;margin-top:20px;margin-bottom:20px;background-color:#f5f5f5;border-top:1px solid #e5e5e5;*zoom:1}.form-actions:before,.form-actions:after{display:table;line-height:0;content:""}.form-actions:after{clear:both}.help-block,.help-inline{color:#595959}.help-block{display:block;margin-bottom:10px}.help-inline{display:inline-block;*display:inline;padding-left:5px;vertical-align:middle;*zoom:1}.input-append,.input-prepend{margin-bottom:5px;font-size:0;white-space:nowrap}.input-append input,.input-prepend input,.input-append select,.input-prepend select,.input-append .uneditable-input,.input-prepend .uneditable-input,.input-append .dropdown-menu,.input-prepend .dropdown-menu{font-size:14px}.input-append input,.input-prepend input,.input-append select,.input-prepend select,.input-append .uneditable-input,.input-prepend .uneditable-input{position:relative;margin-bottom:0;*margin-left:0;vertical-align:top;-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.input-append input:focus,.input-prepend input:focus,.input-append select:focus,.input-prepend select:focus,.input-append .uneditable-input:focus,.input-prepend .uneditable-input:focus{z-index:2}.input-append .add-on,.input-prepend .add-on{display:inline-block;width:auto;height:20px;min-width:16px;padding:4px 5px;font-size:14px;font-weight:normal;line-height:20px;text-align:center;text-shadow:0 1px 0 #fff;background-color:#eee;border:1px solid #ccc}.input-append .add-on,.input-prepend .add-on,.input-append .btn,.input-prepend .btn,.input-append .btn-group>.dropdown-toggle,.input-prepend .btn-group>.dropdown-toggle{vertical-align:top;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.input-append .active,.input-prepend .active{background-color:#a9dba9;border-color:#46a546}.input-prepend .add-on,.input-prepend .btn{margin-right:-1px}.input-prepend .add-on:first-child,.input-prepend .btn:first-child{-webkit-border-radius:4px 0 0 4px;-moz-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.input-append input,.input-append select,.input-append .uneditable-input{-webkit-border-radius:4px 0 0 4px;-moz-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.input-append input+.btn-group .btn:last-child,.input-append select+.btn-group .btn:last-child,.input-append .uneditable-input+.btn-group .btn:last-child{-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.input-append .add-on,.input-append .btn,.input-append .btn-group{margin-left:-1px}.input-append .add-on:last-child,.input-append .btn:last-child,.input-append .btn-group:last-child>.dropdown-toggle{-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.input-prepend.input-append input,.input-prepend.input-append select,.input-prepend.input-append .uneditable-input{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.input-prepend.input-append input+.btn-group .btn,.input-prepend.input-append select+.btn-group .btn,.input-prepend.input-append .uneditable-input+.btn-group .btn{-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.input-prepend.input-append .add-on:first-child,.input-prepend.input-append .btn:first-child{margin-right:-1px;-webkit-border-radius:4px 0 0 4px;-moz-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.input-prepend.input-append .add-on:last-child,.input-prepend.input-append .btn:last-child{margin-left:-1px;-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.input-prepend.input-append .btn-group:first-child{margin-left:0}input.search-query{padding-right:14px;padding-right:4px \9;padding-left:14px;padding-left:4px \9;margin-bottom:0;-webkit-border-radius:15px;-moz-border-radius:15px;border-radius:15px}.form-search .input-append .search-query,.form-search .input-prepend .search-query{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.form-search .input-append .search-query{-webkit-border-radius:14px 0 0 14px;-moz-border-radius:14px 0 0 14px;border-radius:14px 0 0 14px}.form-search .input-append .btn{-webkit-border-radius:0 14px 14px 0;-moz-border-radius:0 14px 14px 0;border-radius:0 14px 14px 0}.form-search .input-prepend .search-query{-webkit-border-radius:0 14px 14px 0;-moz-border-radius:0 14px 14px 0;border-radius:0 14px 14px 0}.form-search .input-prepend .btn{-webkit-border-radius:14px 0 0 14px;-moz-border-radius:14px 0 0 14px;border-radius:14px 0 0 14px}.form-search input,.form-inline input,.form-horizontal input,.form-search textarea,.form-inline textarea,.form-horizontal textarea,.form-search select,.form-inline select,.form-horizontal select,.form-search .help-inline,.form-inline .help-inline,.form-horizontal .help-inline,.form-search .uneditable-input,.form-inline .uneditable-input,.form-horizontal .uneditable-input,.form-search .input-prepend,.form-inline .input-prepend,.form-horizontal .input-prepend,.form-search .input-append,.form-inline .input-append,.form-horizontal .input-append{display:inline-block;*display:inline;margin-bottom:0;vertical-align:middle;*zoom:1}.form-search .hide,.form-inline .hide,.form-horizontal .hide{display:none}.form-search label,.form-inline label,.form-search .btn-group,.form-inline .btn-group{display:inline-block}.form-search .input-append,.form-inline .input-append,.form-search .input-prepend,.form-inline .input-prepend{margin-bottom:0}.form-search .radio,.form-search .checkbox,.form-inline .radio,.form-inline .checkbox{padding-left:0;margin-bottom:0;vertical-align:middle}.form-search .radio input[type="radio"],.form-search .checkbox input[type="checkbox"],.form-inline .radio input[type="radio"],.form-inline .checkbox input[type="checkbox"]{float:left;margin-right:3px;margin-left:0}.control-group{margin-bottom:10px}legend+.control-group{margin-top:20px;-webkit-margin-top-collapse:separate}.form-horizontal .control-group{margin-bottom:20px;*zoom:1}.form-horizontal .control-group:before,.form-horizontal .control-group:after{display:table;line-height:0;content:""}.form-horizontal .control-group:after{clear:both}.form-horizontal .control-label{float:left;width:160px;padding-top:5px;text-align:right}.form-horizontal .controls{*display:inline-block;*padding-left:20px;margin-left:180px;*margin-left:0}.form-horizontal .controls:first-child{*padding-left:180px}.form-horizontal .help-block{margin-bottom:0}.form-horizontal input+.help-block,.form-horizontal select+.help-block,.form-horizontal textarea+.help-block,.form-horizontal .uneditable-input+.help-block,.form-horizontal .input-prepend+.help-block,.form-horizontal .input-append+.help-block{margin-top:10px}.form-horizontal .form-actions{padding-left:180px}table{max-width:100%;background-color:transparent;border-collapse:collapse;border-spacing:0}.table{width:100%;margin-bottom:20px}.table th,.table td{padding:8px;line-height:20px;text-align:left;vertical-align:top;border-top:1px solid #ddd}.table th{font-weight:bold}.table thead th{vertical-align:bottom}.table caption+thead tr:first-child th,.table caption+thead tr:first-child td,.table colgroup+thead tr:first-child th,.table colgroup+thead tr:first-child td,.table thead:first-child tr:first-child th,.table thead:first-child tr:first-child td{border-top:0}.table tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed th,.table-condensed td{padding:4px 5px}.table-bordered{border:1px solid #ddd;border-collapse:separate;*border-collapse:collapse;border-left:0;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.table-bordered th,.table-bordered td{border-left:1px solid #ddd}.table-bordered caption+thead tr:first-child th,.table-bordered caption+tbody tr:first-child th,.table-bordered caption+tbody tr:first-child td,.table-bordered colgroup+thead tr:first-child th,.table-bordered colgroup+tbody tr:first-child th,.table-bordered colgroup+tbody tr:first-child td,.table-bordered thead:first-child tr:first-child th,.table-bordered tbody:first-child tr:first-child th,.table-bordered tbody:first-child tr:first-child td{border-top:0}.table-bordered thead:first-child tr:first-child>th:first-child,.table-bordered tbody:first-child tr:first-child>td:first-child{-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-topleft:4px}.table-bordered thead:first-child tr:first-child>th:last-child,.table-bordered tbody:first-child tr:first-child>td:last-child{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-moz-border-radius-topright:4px}.table-bordered thead:last-child tr:last-child>th:first-child,.table-bordered tbody:last-child tr:last-child>td:first-child,.table-bordered tfoot:last-child tr:last-child>td:first-child{-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-moz-border-radius-bottomleft:4px}.table-bordered thead:last-child tr:last-child>th:last-child,.table-bordered tbody:last-child tr:last-child>td:last-child,.table-bordered tfoot:last-child tr:last-child>td:last-child{-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;-moz-border-radius-bottomright:4px}.table-bordered tfoot+tbody:last-child tr:last-child td:first-child{-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0;-moz-border-radius-bottomleft:0}.table-bordered tfoot+tbody:last-child tr:last-child td:last-child{-webkit-border-bottom-right-radius:0;border-bottom-right-radius:0;-moz-border-radius-bottomright:0}.table-bordered caption+thead tr:first-child th:first-child,.table-bordered caption+tbody tr:first-child td:first-child,.table-bordered colgroup+thead tr:first-child th:first-child,.table-bordered colgroup+tbody tr:first-child td:first-child{-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-topleft:4px}.table-bordered caption+thead tr:first-child th:last-child,.table-bordered caption+tbody tr:first-child td:last-child,.table-bordered colgroup+thead tr:first-child th:last-child,.table-bordered colgroup+tbody tr:first-child td:last-child{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-moz-border-radius-topright:4px}.table-striped tbody>tr:nth-child(odd)>td,.table-striped tbody>tr:nth-child(odd)>th{background-color:#f9f9f9}.table-hover tbody tr:hover td,.table-hover tbody tr:hover th{background-color:#f5f5f5}table td[class*="span"],table th[class*="span"],.row-fluid table td[class*="span"],.row-fluid table th[class*="span"]{display:table-cell;float:none;margin-left:0}.table td.span1,.table th.span1{float:none;width:44px;margin-left:0}.table td.span2,.table th.span2{float:none;width:124px;margin-left:0}.table td.span3,.table th.span3{float:none;width:204px;margin-left:0}.table td.span4,.table th.span4{float:none;width:284px;margin-left:0}.table td.span5,.table th.span5{float:none;width:364px;margin-left:0}.table td.span6,.table th.span6{float:none;width:444px;margin-left:0}.table td.span7,.table th.span7{float:none;width:524px;margin-left:0}.table td.span8,.table th.span8{float:none;width:604px;margin-left:0}.table td.span9,.table th.span9{float:none;width:684px;margin-left:0}.table td.span10,.table th.span10{float:none;width:764px;margin-left:0}.table td.span11,.table th.span11{float:none;width:844px;margin-left:0}.table td.span12,.table th.span12{float:none;width:924px;margin-left:0}.table tbody tr.success td{background-color:#dff0d8}.table tbody tr.error td{background-color:#f2dede}.table tbody tr.warning td{background-color:#fcf8e3}.table tbody tr.info td{background-color:#d9edf7}.table-hover tbody tr.success:hover td{background-color:#d0e9c6}.table-hover tbody tr.error:hover td{background-color:#ebcccc}.table-hover tbody tr.warning:hover td{background-color:#faf2cc}.table-hover tbody tr.info:hover td{background-color:#c4e3f3}[class^="icon-"],[class*=" icon-"]{display:inline-block;width:14px;height:14px;margin-top:1px;*margin-right:.3em;line-height:14px;vertical-align:text-top;background-image:url("../img/glyphicons-halflings.png");background-position:14px 14px;background-repeat:no-repeat}.icon-white,.nav-pills>.active>a>[class^="icon-"],.nav-pills>.active>a>[class*=" icon-"],.nav-list>.active>a>[class^="icon-"],.nav-list>.active>a>[class*=" icon-"],.navbar-inverse .nav>.active>a>[class^="icon-"],.navbar-inverse .nav>.active>a>[class*=" icon-"],.dropdown-menu>li>a:hover>[class^="icon-"],.dropdown-menu>li>a:hover>[class*=" icon-"],.dropdown-menu>.active>a>[class^="icon-"],.dropdown-menu>.active>a>[class*=" icon-"],.dropdown-submenu:hover>a>[class^="icon-"],.dropdown-submenu:hover>a>[class*=" icon-"]{background-image:url("../img/glyphicons-halflings-white.png")}.icon-glass{background-position:0 0}.icon-music{background-position:-24px 0}.icon-search{background-position:-48px 0}.icon-envelope{background-position:-72px 0}.icon-heart{background-position:-96px 0}.icon-star{background-position:-120px 0}.icon-star-empty{background-position:-144px 0}.icon-user{background-position:-168px 0}.icon-film{background-position:-192px 0}.icon-th-large{background-position:-216px 0}.icon-th{background-position:-240px 0}.icon-th-list{background-position:-264px 0}.icon-ok{background-position:-288px 0}.icon-remove{background-position:-312px 0}.icon-zoom-in{background-position:-336px 0}.icon-zoom-out{background-position:-360px 0}.icon-off{background-position:-384px 0}.icon-signal{background-position:-408px 0}.icon-cog{background-position:-432px 0}.icon-trash{background-position:-456px 0}.icon-home{background-position:0 -24px}.icon-file{background-position:-24px -24px}.icon-time{background-position:-48px -24px}.icon-road{background-position:-72px -24px}.icon-download-alt{background-position:-96px -24px}.icon-download{background-position:-120px -24px}.icon-upload{background-position:-144px -24px}.icon-inbox{background-position:-168px -24px}.icon-play-circle{background-position:-192px -24px}.icon-repeat{background-position:-216px -24px}.icon-refresh{background-position:-240px -24px}.icon-list-alt{background-position:-264px -24px}.icon-lock{background-position:-287px -24px}.icon-flag{background-position:-312px -24px}.icon-headphones{background-position:-336px -24px}.icon-volume-off{background-position:-360px -24px}.icon-volume-down{background-position:-384px -24px}.icon-volume-up{background-position:-408px -24px}.icon-qrcode{background-position:-432px -24px}.icon-barcode{background-position:-456px -24px}.icon-tag{background-position:0 -48px}.icon-tags{background-position:-25px -48px}.icon-book{background-position:-48px -48px}.icon-bookmark{background-position:-72px -48px}.icon-print{background-position:-96px -48px}.icon-camera{background-position:-120px -48px}.icon-font{background-position:-144px -48px}.icon-bold{background-position:-167px -48px}.icon-italic{background-position:-192px -48px}.icon-text-height{background-position:-216px -48px}.icon-text-width{background-position:-240px -48px}.icon-align-left{background-position:-264px -48px}.icon-align-center{background-position:-288px -48px}.icon-align-right{background-position:-312px -48px}.icon-align-justify{background-position:-336px -48px}.icon-list{background-position:-360px -48px}.icon-indent-left{background-position:-384px -48px}.icon-indent-right{background-position:-408px -48px}.icon-facetime-video{background-position:-432px -48px}.icon-picture{background-position:-456px -48px}.icon-pencil{background-position:0 -72px}.icon-map-marker{background-position:-24px -72px}.icon-adjust{background-position:-48px -72px}.icon-tint{background-position:-72px -72px}.icon-edit{background-position:-96px -72px}.icon-share{background-position:-120px -72px}.icon-check{background-position:-144px -72px}.icon-move{background-position:-168px -72px}.icon-step-backward{background-position:-192px -72px}.icon-fast-backward{background-position:-216px -72px}.icon-backward{background-position:-240px -72px}.icon-play{background-position:-264px -72px}.icon-pause{background-position:-288px -72px}.icon-stop{background-position:-312px -72px}.icon-forward{background-position:-336px -72px}.icon-fast-forward{background-position:-360px -72px}.icon-step-forward{background-position:-384px -72px}.icon-eject{background-position:-408px -72px}.icon-chevron-left{background-position:-432px -72px}.icon-chevron-right{background-position:-456px -72px}.icon-plus-sign{background-position:0 -96px}.icon-minus-sign{background-position:-24px -96px}.icon-remove-sign{background-position:-48px -96px}.icon-ok-sign{background-position:-72px -96px}.icon-question-sign{background-position:-96px -96px}.icon-info-sign{background-position:-120px -96px}.icon-screenshot{background-position:-144px -96px}.icon-remove-circle{background-position:-168px -96px}.icon-ok-circle{background-position:-192px -96px}.icon-ban-circle{background-position:-216px -96px}.icon-arrow-left{background-position:-240px -96px}.icon-arrow-right{background-position:-264px -96px}.icon-arrow-up{background-position:-289px -96px}.icon-arrow-down{background-position:-312px -96px}.icon-share-alt{background-position:-336px -96px}.icon-resize-full{background-position:-360px -96px}.icon-resize-small{background-position:-384px -96px}.icon-plus{background-position:-408px -96px}.icon-minus{background-position:-433px -96px}.icon-asterisk{background-position:-456px -96px}.icon-exclamation-sign{background-position:0 -120px}.icon-gift{background-position:-24px -120px}.icon-leaf{background-position:-48px -120px}.icon-fire{background-position:-72px -120px}.icon-eye-open{background-position:-96px -120px}.icon-eye-close{background-position:-120px -120px}.icon-warning-sign{background-position:-144px -120px}.icon-plane{background-position:-168px -120px}.icon-calendar{background-position:-192px -120px}.icon-random{width:16px;background-position:-216px -120px}.icon-comment{background-position:-240px -120px}.icon-magnet{background-position:-264px -120px}.icon-chevron-up{background-position:-288px -120px}.icon-chevron-down{background-position:-313px -119px}.icon-retweet{background-position:-336px -120px}.icon-shopping-cart{background-position:-360px -120px}.icon-folder-close{background-position:-384px -120px}.icon-folder-open{width:16px;background-position:-408px -120px}.icon-resize-vertical{background-position:-432px -119px}.icon-resize-horizontal{background-position:-456px -118px}.icon-hdd{background-position:0 -144px}.icon-bullhorn{background-position:-24px -144px}.icon-bell{background-position:-48px -144px}.icon-certificate{background-position:-72px -144px}.icon-thumbs-up{background-position:-96px -144px}.icon-thumbs-down{background-position:-120px -144px}.icon-hand-right{background-position:-144px -144px}.icon-hand-left{background-position:-168px -144px}.icon-hand-up{background-position:-192px -144px}.icon-hand-down{background-position:-216px -144px}.icon-circle-arrow-right{background-position:-240px -144px}.icon-circle-arrow-left{background-position:-264px -144px}.icon-circle-arrow-up{background-position:-288px -144px}.icon-circle-arrow-down{background-position:-312px -144px}.icon-globe{background-position:-336px -144px}.icon-wrench{background-position:-360px -144px}.icon-tasks{background-position:-384px -144px}.icon-filter{background-position:-408px -144px}.icon-briefcase{background-position:-432px -144px}.icon-fullscreen{background-position:-456px -144px}.dropup,.dropdown{position:relative}.dropdown-toggle{*margin-bottom:-3px}.dropdown-toggle:active,.open .dropdown-toggle{outline:0}.caret{display:inline-block;width:0;height:0;vertical-align:top;border-top:4px solid #000;border-right:4px solid transparent;border-left:4px solid transparent;content:""}.dropdown .caret{margin-top:8px;margin-left:2px}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;list-style:none;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.2);*border-right-width:2px;*border-bottom-width:2px;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,0.2);-moz-box-shadow:0 5px 10px rgba(0,0,0,0.2);box-shadow:0 5px 10px rgba(0,0,0,0.2);-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{*width:100%;height:1px;margin:9px 1px;*margin:-5px 0 5px;overflow:hidden;background-color:#e5e5e5;border-bottom:1px solid #fff}.dropdown-menu li>a{display:block;padding:3px 20px;clear:both;font-weight:normal;line-height:20px;color:#333;white-space:nowrap}.dropdown-menu li>a:hover,.dropdown-menu li>a:focus,.dropdown-submenu:hover>a{color:#fff;text-decoration:none;background-color:#0081c2;background-image:-moz-linear-gradient(top,#08c,#0077b3);background-image:-webkit-gradient(linear,0 0,0 100%,from(#08c),to(#0077b3));background-image:-webkit-linear-gradient(top,#08c,#0077b3);background-image:-o-linear-gradient(top,#08c,#0077b3);background-image:linear-gradient(to bottom,#08c,#0077b3);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc',endColorstr='#ff0077b3',GradientType=0)}.dropdown-menu .active>a,.dropdown-menu .active>a:hover{color:#fff;text-decoration:none;background-color:#0081c2;background-image:-moz-linear-gradient(top,#08c,#0077b3);background-image:-webkit-gradient(linear,0 0,0 100%,from(#08c),to(#0077b3));background-image:-webkit-linear-gradient(top,#08c,#0077b3);background-image:-o-linear-gradient(top,#08c,#0077b3);background-image:linear-gradient(to bottom,#08c,#0077b3);background-repeat:repeat-x;outline:0;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc',endColorstr='#ff0077b3',GradientType=0)}.dropdown-menu .disabled>a,.dropdown-menu .disabled>a:hover{color:#999}.dropdown-menu .disabled>a:hover{text-decoration:none;cursor:default;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.open{*z-index:1000}.open>.dropdown-menu{display:block}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{border-top:0;border-bottom:4px solid #000;content:""}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}.dropdown-submenu{position:relative}.dropdown-submenu>.dropdown-menu{top:0;left:100%;margin-top:-6px;margin-left:-1px;-webkit-border-radius:0 6px 6px 6px;-moz-border-radius:0 6px 6px 6px;border-radius:0 6px 6px 6px}.dropdown-submenu:hover>.dropdown-menu{display:block}.dropup .dropdown-submenu>.dropdown-menu{top:auto;bottom:0;margin-top:0;margin-bottom:-2px;-webkit-border-radius:5px 5px 5px 0;-moz-border-radius:5px 5px 5px 0;border-radius:5px 5px 5px 0}.dropdown-submenu>a:after{display:block;float:right;width:0;height:0;margin-top:5px;margin-right:-10px;border-color:transparent;border-left-color:#ccc;border-style:solid;border-width:5px 0 5px 5px;content:" "}.dropdown-submenu:hover>a:after{border-left-color:#fff}.dropdown-submenu.pull-left{float:none}.dropdown-submenu.pull-left>.dropdown-menu{left:-100%;margin-left:10px;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px}.dropdown .dropdown-menu .nav-header{padding-right:20px;padding-left:20px}.typeahead{z-index:1051;margin-top:2px;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,0.05);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,0.05);box-shadow:inset 0 1px 1px rgba(0,0,0,0.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,0.15)}.well-large{padding:24px;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px}.well-small{padding:9px;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}.fade{opacity:0;-webkit-transition:opacity .15s linear;-moz-transition:opacity .15s linear;-o-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{position:relative;height:0;overflow:hidden;-webkit-transition:height .35s ease;-moz-transition:height .35s ease;-o-transition:height .35s ease;transition:height .35s ease}.collapse.in{height:auto}.close{float:right;font-size:20px;font-weight:bold;line-height:20px;color:#000;text-shadow:0 1px 0 #fff;opacity:.2;filter:alpha(opacity=20)}.close:hover{color:#000;text-decoration:none;cursor:pointer;opacity:.4;filter:alpha(opacity=40)}button.close{padding:0;cursor:pointer;background:transparent;border:0;-webkit-appearance:none}.btn{display:inline-block;*display:inline;padding:4px 12px;margin-bottom:0;*margin-left:.3em;font-size:14px;line-height:20px;color:#333;text-align:center;text-shadow:0 1px 1px rgba(255,255,255,0.75);vertical-align:middle;cursor:pointer;background-color:#f5f5f5;*background-color:#e6e6e6;background-image:-moz-linear-gradient(top,#fff,#e6e6e6);background-image:-webkit-gradient(linear,0 0,0 100%,from(#fff),to(#e6e6e6));background-image:-webkit-linear-gradient(top,#fff,#e6e6e6);background-image:-o-linear-gradient(top,#fff,#e6e6e6);background-image:linear-gradient(to bottom,#fff,#e6e6e6);background-repeat:repeat-x;border:1px solid #bbb;*border:0;border-color:#e6e6e6 #e6e6e6 #bfbfbf;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);border-bottom-color:#a2a2a2;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff',endColorstr='#ffe6e6e6',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);*zoom:1;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);-moz-box-shadow:inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);box-shadow:inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05)}.btn:hover,.btn:active,.btn.active,.btn.disabled,.btn[disabled]{color:#333;background-color:#e6e6e6;*background-color:#d9d9d9}.btn:active,.btn.active{background-color:#ccc \9}.btn:first-child{*margin-left:0}.btn:hover{color:#333;text-decoration:none;background-position:0 -15px;-webkit-transition:background-position .1s linear;-moz-transition:background-position .1s linear;-o-transition:background-position .1s linear;transition:background-position .1s linear}.btn:focus{outline:thin dotted #333;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn.active,.btn:active{background-image:none;outline:0;-webkit-box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);-moz-box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05)}.btn.disabled,.btn[disabled]{cursor:default;background-image:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.btn-large{padding:11px 19px;font-size:17.5px;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px}.btn-large [class^="icon-"],.btn-large [class*=" icon-"]{margin-top:4px}.btn-small{padding:2px 10px;font-size:11.9px;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}.btn-small [class^="icon-"],.btn-small [class*=" icon-"]{margin-top:0}.btn-mini [class^="icon-"],.btn-mini [class*=" icon-"]{margin-top:-1px}.btn-mini{padding:0 6px;font-size:10.5px;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}.btn-block{display:block;width:100%;padding-right:0;padding-left:0;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.btn-block+.btn-block{margin-top:5px}input[type="submit"].btn-block,input[type="reset"].btn-block,input[type="button"].btn-block{width:100%}.btn-primary.active,.btn-warning.active,.btn-danger.active,.btn-success.active,.btn-info.active,.btn-inverse.active{color:rgba(255,255,255,0.75)}.btn{border-color:#c5c5c5;border-color:rgba(0,0,0,0.15) rgba(0,0,0,0.15) rgba(0,0,0,0.25)}.btn-primary{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#006dcc;*background-color:#04c;background-image:-moz-linear-gradient(top,#08c,#04c);background-image:-webkit-gradient(linear,0 0,0 100%,from(#08c),to(#04c));background-image:-webkit-linear-gradient(top,#08c,#04c);background-image:-o-linear-gradient(top,#08c,#04c);background-image:linear-gradient(to bottom,#08c,#04c);background-repeat:repeat-x;border-color:#04c #04c #002a80;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc',endColorstr='#ff0044cc',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-primary:hover,.btn-primary:active,.btn-primary.active,.btn-primary.disabled,.btn-primary[disabled]{color:#fff;background-color:#04c;*background-color:#003bb3}.btn-primary:active,.btn-primary.active{background-color:#039 \9}.btn-warning{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#faa732;*background-color:#f89406;background-image:-moz-linear-gradient(top,#fbb450,#f89406);background-image:-webkit-gradient(linear,0 0,0 100%,from(#fbb450),to(#f89406));background-image:-webkit-linear-gradient(top,#fbb450,#f89406);background-image:-o-linear-gradient(top,#fbb450,#f89406);background-image:linear-gradient(to bottom,#fbb450,#f89406);background-repeat:repeat-x;border-color:#f89406 #f89406 #ad6704;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450',endColorstr='#fff89406',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-warning:hover,.btn-warning:active,.btn-warning.active,.btn-warning.disabled,.btn-warning[disabled]{color:#fff;background-color:#f89406;*background-color:#df8505}.btn-warning:active,.btn-warning.active{background-color:#c67605 \9}.btn-danger{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#da4f49;*background-color:#bd362f;background-image:-moz-linear-gradient(top,#ee5f5b,#bd362f);background-image:-webkit-gradient(linear,0 0,0 100%,from(#ee5f5b),to(#bd362f));background-image:-webkit-linear-gradient(top,#ee5f5b,#bd362f);background-image:-o-linear-gradient(top,#ee5f5b,#bd362f);background-image:linear-gradient(to bottom,#ee5f5b,#bd362f);background-repeat:repeat-x;border-color:#bd362f #bd362f #802420;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b',endColorstr='#ffbd362f',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-danger:hover,.btn-danger:active,.btn-danger.active,.btn-danger.disabled,.btn-danger[disabled]{color:#fff;background-color:#bd362f;*background-color:#a9302a}.btn-danger:active,.btn-danger.active{background-color:#942a25 \9}.btn-success{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#5bb75b;*background-color:#51a351;background-image:-moz-linear-gradient(top,#62c462,#51a351);background-image:-webkit-gradient(linear,0 0,0 100%,from(#62c462),to(#51a351));background-image:-webkit-linear-gradient(top,#62c462,#51a351);background-image:-o-linear-gradient(top,#62c462,#51a351);background-image:linear-gradient(to bottom,#62c462,#51a351);background-repeat:repeat-x;border-color:#51a351 #51a351 #387038;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462',endColorstr='#ff51a351',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-success:hover,.btn-success:active,.btn-success.active,.btn-success.disabled,.btn-success[disabled]{color:#fff;background-color:#51a351;*background-color:#499249}.btn-success:active,.btn-success.active{background-color:#408140 \9}.btn-info{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#49afcd;*background-color:#2f96b4;background-image:-moz-linear-gradient(top,#5bc0de,#2f96b4);background-image:-webkit-gradient(linear,0 0,0 100%,from(#5bc0de),to(#2f96b4));background-image:-webkit-linear-gradient(top,#5bc0de,#2f96b4);background-image:-o-linear-gradient(top,#5bc0de,#2f96b4);background-image:linear-gradient(to bottom,#5bc0de,#2f96b4);background-repeat:repeat-x;border-color:#2f96b4 #2f96b4 #1f6377;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de',endColorstr='#ff2f96b4',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-info:hover,.btn-info:active,.btn-info.active,.btn-info.disabled,.btn-info[disabled]{color:#fff;background-color:#2f96b4;*background-color:#2a85a0}.btn-info:active,.btn-info.active{background-color:#24748c \9}.btn-inverse{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#363636;*background-color:#222;background-image:-moz-linear-gradient(top,#444,#222);background-image:-webkit-gradient(linear,0 0,0 100%,from(#444),to(#222));background-image:-webkit-linear-gradient(top,#444,#222);background-image:-o-linear-gradient(top,#444,#222);background-image:linear-gradient(to bottom,#444,#222);background-repeat:repeat-x;border-color:#222 #222 #000;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff444444',endColorstr='#ff222222',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-inverse:hover,.btn-inverse:active,.btn-inverse.active,.btn-inverse.disabled,.btn-inverse[disabled]{color:#fff;background-color:#222;*background-color:#151515}.btn-inverse:active,.btn-inverse.active{background-color:#080808 \9}button.btn,input[type="submit"].btn{*padding-top:3px;*padding-bottom:3px}button.btn::-moz-focus-inner,input[type="submit"].btn::-moz-focus-inner{padding:0;border:0}button.btn.btn-large,input[type="submit"].btn.btn-large{*padding-top:7px;*padding-bottom:7px}button.btn.btn-small,input[type="submit"].btn.btn-small{*padding-top:3px;*padding-bottom:3px}button.btn.btn-mini,input[type="submit"].btn.btn-mini{*padding-top:1px;*padding-bottom:1px}.btn-link,.btn-link:active,.btn-link[disabled]{background-color:transparent;background-image:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.btn-link{color:#08c;cursor:pointer;border-color:transparent;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.btn-link:hover{color:#005580;text-decoration:underline;background-color:transparent}.btn-link[disabled]:hover{color:#333;text-decoration:none}.btn-group{position:relative;display:inline-block;*display:inline;*margin-left:.3em;font-size:0;white-space:nowrap;vertical-align:middle;*zoom:1}.btn-group:first-child{*margin-left:0}.btn-group+.btn-group{margin-left:5px}.btn-toolbar{margin-top:10px;margin-bottom:10px;font-size:0}.btn-toolbar>.btn+.btn,.btn-toolbar>.btn-group+.btn,.btn-toolbar>.btn+.btn-group{margin-left:5px}.btn-group>.btn{position:relative;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.btn-group>.btn+.btn{margin-left:-1px}.btn-group>.btn,.btn-group>.dropdown-menu,.btn-group>.popover{font-size:14px}.btn-group>.btn-mini{font-size:10.5px}.btn-group>.btn-small{font-size:11.9px}.btn-group>.btn-large{font-size:17.5px}.btn-group>.btn:first-child{margin-left:0;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-bottomleft:4px;-moz-border-radius-topleft:4px}.btn-group>.btn:last-child,.btn-group>.dropdown-toggle{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;-moz-border-radius-topright:4px;-moz-border-radius-bottomright:4px}.btn-group>.btn.large:first-child{margin-left:0;-webkit-border-bottom-left-radius:6px;border-bottom-left-radius:6px;-webkit-border-top-left-radius:6px;border-top-left-radius:6px;-moz-border-radius-bottomleft:6px;-moz-border-radius-topleft:6px}.btn-group>.btn.large:last-child,.btn-group>.large.dropdown-toggle{-webkit-border-top-right-radius:6px;border-top-right-radius:6px;-webkit-border-bottom-right-radius:6px;border-bottom-right-radius:6px;-moz-border-radius-topright:6px;-moz-border-radius-bottomright:6px}.btn-group>.btn:hover,.btn-group>.btn:focus,.btn-group>.btn:active,.btn-group>.btn.active{z-index:2}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{*padding-top:5px;padding-right:8px;*padding-bottom:5px;padding-left:8px;-webkit-box-shadow:inset 1px 0 0 rgba(255,255,255,0.125),inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);-moz-box-shadow:inset 1px 0 0 rgba(255,255,255,0.125),inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05);box-shadow:inset 1px 0 0 rgba(255,255,255,0.125),inset 0 1px 0 rgba(255,255,255,0.2),0 1px 2px rgba(0,0,0,0.05)}.btn-group>.btn-mini+.dropdown-toggle{*padding-top:2px;padding-right:5px;*padding-bottom:2px;padding-left:5px}.btn-group>.btn-small+.dropdown-toggle{*padding-top:5px;*padding-bottom:4px}.btn-group>.btn-large+.dropdown-toggle{*padding-top:7px;padding-right:12px;*padding-bottom:7px;padding-left:12px}.btn-group.open .dropdown-toggle{background-image:none;-webkit-box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);-moz-box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05);box-shadow:inset 0 2px 4px rgba(0,0,0,0.15),0 1px 2px rgba(0,0,0,0.05)}.btn-group.open .btn.dropdown-toggle{background-color:#e6e6e6}.btn-group.open .btn-primary.dropdown-toggle{background-color:#04c}.btn-group.open .btn-warning.dropdown-toggle{background-color:#f89406}.btn-group.open .btn-danger.dropdown-toggle{background-color:#bd362f}.btn-group.open .btn-success.dropdown-toggle{background-color:#51a351}.btn-group.open .btn-info.dropdown-toggle{background-color:#2f96b4}.btn-group.open .btn-inverse.dropdown-toggle{background-color:#222}.btn .caret{margin-top:8px;margin-left:0}.btn-mini .caret,.btn-small .caret,.btn-large .caret{margin-top:6px}.btn-large .caret{border-top-width:5px;border-right-width:5px;border-left-width:5px}.dropup .btn-large .caret{border-bottom-width:5px}.btn-primary .caret,.btn-warning .caret,.btn-danger .caret,.btn-info .caret,.btn-success .caret,.btn-inverse .caret{border-top-color:#fff;border-bottom-color:#fff}.btn-group-vertical{display:inline-block;*display:inline;*zoom:1}.btn-group-vertical>.btn{display:block;float:none;max-width:100%;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.btn-group-vertical>.btn+.btn{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:first-child{-webkit-border-radius:4px 4px 0 0;-moz-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.btn-group-vertical>.btn:last-child{-webkit-border-radius:0 0 4px 4px;-moz-border-radius:0 0 4px 4px;border-radius:0 0 4px 4px}.btn-group-vertical>.btn-large:first-child{-webkit-border-radius:6px 6px 0 0;-moz-border-radius:6px 6px 0 0;border-radius:6px 6px 0 0}.btn-group-vertical>.btn-large:last-child{-webkit-border-radius:0 0 6px 6px;-moz-border-radius:0 0 6px 6px;border-radius:0 0 6px 6px}.alert{padding:8px 35px 8px 14px;margin-bottom:20px;text-shadow:0 1px 0 rgba(255,255,255,0.5);background-color:#fcf8e3;border:1px solid #fbeed5;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.alert,.alert h4{color:#c09853}.alert h4{margin:0}.alert .close{position:relative;top:-2px;right:-21px;line-height:20px}.alert-success{color:#468847;background-color:#dff0d8;border-color:#d6e9c6}.alert-success h4{color:#468847}.alert-danger,.alert-error{color:#b94a48;background-color:#f2dede;border-color:#eed3d7}.alert-danger h4,.alert-error h4{color:#b94a48}.alert-info{color:#3a87ad;background-color:#d9edf7;border-color:#bce8f1}.alert-info h4{color:#3a87ad}.alert-block{padding-top:14px;padding-bottom:14px}.alert-block>p,.alert-block>ul{margin-bottom:0}.alert-block p+p{margin-top:5px}.nav{margin-bottom:20px;margin-left:0;list-style:none}.nav>li>a{display:block}.nav>li>a:hover{text-decoration:none;background-color:#eee}.nav>li>a>img{max-width:none}.nav>.pull-right{float:right}.nav-header{display:block;padding:3px 15px;font-size:11px;font-weight:bold;line-height:20px;color:#999;text-shadow:0 1px 0 rgba(255,255,255,0.5);text-transform:uppercase}.nav li+.nav-header{margin-top:9px}.nav-list{padding-right:15px;padding-left:15px;margin-bottom:0}.nav-list>li>a,.nav-list .nav-header{margin-right:-15px;margin-left:-15px;text-shadow:0 1px 0 rgba(255,255,255,0.5)}.nav-list>li>a{padding:3px 15px}.nav-list>.active>a,.nav-list>.active>a:hover{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.2);background-color:#08c}.nav-list [class^="icon-"],.nav-list [class*=" icon-"]{margin-right:2px}.nav-list .divider{*width:100%;height:1px;margin:9px 1px;*margin:-5px 0 5px;overflow:hidden;background-color:#e5e5e5;border-bottom:1px solid #fff}.nav-tabs,.nav-pills{*zoom:1}.nav-tabs:before,.nav-pills:before,.nav-tabs:after,.nav-pills:after{display:table;line-height:0;content:""}.nav-tabs:after,.nav-pills:after{clear:both}.nav-tabs>li,.nav-pills>li{float:left}.nav-tabs>li>a,.nav-pills>li>a{padding-right:12px;padding-left:12px;margin-right:2px;line-height:14px}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{margin-bottom:-1px}.nav-tabs>li>a{padding-top:8px;padding-bottom:8px;line-height:20px;border:1px solid transparent;-webkit-border-radius:4px 4px 0 0;-moz-border-radius:4px 4px 0 0;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>.active>a,.nav-tabs>.active>a:hover{color:#555;cursor:default;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent}.nav-pills>li>a{padding-top:8px;padding-bottom:8px;margin-top:2px;margin-bottom:2px;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px}.nav-pills>.active>a,.nav-pills>.active>a:hover{color:#fff;background-color:#08c}.nav-stacked>li{float:none}.nav-stacked>li>a{margin-right:0}.nav-tabs.nav-stacked{border-bottom:0}.nav-tabs.nav-stacked>li>a{border:1px solid #ddd;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.nav-tabs.nav-stacked>li:first-child>a{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-topright:4px;-moz-border-radius-topleft:4px}.nav-tabs.nav-stacked>li:last-child>a{-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-moz-border-radius-bottomright:4px;-moz-border-radius-bottomleft:4px}.nav-tabs.nav-stacked>li>a:hover{z-index:2;border-color:#ddd}.nav-pills.nav-stacked>li>a{margin-bottom:3px}.nav-pills.nav-stacked>li:last-child>a{margin-bottom:1px}.nav-tabs .dropdown-menu{-webkit-border-radius:0 0 6px 6px;-moz-border-radius:0 0 6px 6px;border-radius:0 0 6px 6px}.nav-pills .dropdown-menu{-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px}.nav .dropdown-toggle .caret{margin-top:6px;border-top-color:#08c;border-bottom-color:#08c}.nav .dropdown-toggle:hover .caret{border-top-color:#005580;border-bottom-color:#005580}.nav-tabs .dropdown-toggle .caret{margin-top:8px}.nav .active .dropdown-toggle .caret{border-top-color:#fff;border-bottom-color:#fff}.nav-tabs .active .dropdown-toggle .caret{border-top-color:#555;border-bottom-color:#555}.nav>.dropdown.active>a:hover{cursor:pointer}.nav-tabs .open .dropdown-toggle,.nav-pills .open .dropdown-toggle,.nav>li.dropdown.open.active>a:hover{color:#fff;background-color:#999;border-color:#999}.nav li.dropdown.open .caret,.nav li.dropdown.open.active .caret,.nav li.dropdown.open a:hover .caret{border-top-color:#fff;border-bottom-color:#fff;opacity:1;filter:alpha(opacity=100)}.tabs-stacked .open>a:hover{border-color:#999}.tabbable{*zoom:1}.tabbable:before,.tabbable:after{display:table;line-height:0;content:""}.tabbable:after{clear:both}.tab-content{overflow:auto}.tabs-below>.nav-tabs,.tabs-right>.nav-tabs,.tabs-left>.nav-tabs{border-bottom:0}.tab-content>.tab-pane,.pill-content>.pill-pane{display:none}.tab-content>.active,.pill-content>.active{display:block}.tabs-below>.nav-tabs{border-top:1px solid #ddd}.tabs-below>.nav-tabs>li{margin-top:-1px;margin-bottom:0}.tabs-below>.nav-tabs>li>a{-webkit-border-radius:0 0 4px 4px;-moz-border-radius:0 0 4px 4px;border-radius:0 0 4px 4px}.tabs-below>.nav-tabs>li>a:hover{border-top-color:#ddd;border-bottom-color:transparent}.tabs-below>.nav-tabs>.active>a,.tabs-below>.nav-tabs>.active>a:hover{border-color:transparent #ddd #ddd #ddd}.tabs-left>.nav-tabs>li,.tabs-right>.nav-tabs>li{float:none}.tabs-left>.nav-tabs>li>a,.tabs-right>.nav-tabs>li>a{min-width:74px;margin-right:0;margin-bottom:3px}.tabs-left>.nav-tabs{float:left;margin-right:19px;border-right:1px solid #ddd}.tabs-left>.nav-tabs>li>a{margin-right:-1px;-webkit-border-radius:4px 0 0 4px;-moz-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.tabs-left>.nav-tabs>li>a:hover{border-color:#eee #ddd #eee #eee}.tabs-left>.nav-tabs .active>a,.tabs-left>.nav-tabs .active>a:hover{border-color:#ddd transparent #ddd #ddd;*border-right-color:#fff}.tabs-right>.nav-tabs{float:right;margin-left:19px;border-left:1px solid #ddd}.tabs-right>.nav-tabs>li>a{margin-left:-1px;-webkit-border-radius:0 4px 4px 0;-moz-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.tabs-right>.nav-tabs>li>a:hover{border-color:#eee #eee #eee #ddd}.tabs-right>.nav-tabs .active>a,.tabs-right>.nav-tabs .active>a:hover{border-color:#ddd #ddd #ddd transparent;*border-left-color:#fff}.nav>.disabled>a{color:#999}.nav>.disabled>a:hover{text-decoration:none;cursor:default;background-color:transparent}.navbar{*position:relative;*z-index:2;margin-bottom:20px;overflow:visible}.navbar-inner{min-height:40px;padding-right:20px;padding-left:20px;background-color:#fafafa;background-image:-moz-linear-gradient(top,#fff,#f2f2f2);background-image:-webkit-gradient(linear,0 0,0 100%,from(#fff),to(#f2f2f2));background-image:-webkit-linear-gradient(top,#fff,#f2f2f2);background-image:-o-linear-gradient(top,#fff,#f2f2f2);background-image:linear-gradient(to bottom,#fff,#f2f2f2);background-repeat:repeat-x;border:1px solid #d4d4d4;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff',endColorstr='#fff2f2f2',GradientType=0);*zoom:1;-webkit-box-shadow:0 1px 4px rgba(0,0,0,0.065);-moz-box-shadow:0 1px 4px rgba(0,0,0,0.065);box-shadow:0 1px 4px rgba(0,0,0,0.065)}.navbar-inner:before,.navbar-inner:after{display:table;line-height:0;content:""}.navbar-inner:after{clear:both}.navbar .container{width:auto}.nav-collapse.collapse{height:auto;overflow:visible}.navbar .brand{display:block;float:left;padding:10px 20px 10px;margin-left:-20px;font-size:20px;font-weight:200;color:#777;text-shadow:0 1px 0 #fff}.navbar .brand:hover{text-decoration:none}.navbar-text{margin-bottom:0;line-height:40px;color:#777}.navbar-link{color:#777}.navbar-link:hover{color:#333}.navbar .divider-vertical{height:40px;margin:0 9px;border-right:1px solid #fff;border-left:1px solid #f2f2f2}.navbar .btn,.navbar .btn-group{margin-top:5px}.navbar .btn-group .btn,.navbar .input-prepend .btn,.navbar .input-append .btn{margin-top:0}.navbar-form{margin-bottom:0;*zoom:1}.navbar-form:before,.navbar-form:after{display:table;line-height:0;content:""}.navbar-form:after{clear:both}.navbar-form input,.navbar-form select,.navbar-form .radio,.navbar-form .checkbox{margin-top:5px}.navbar-form input,.navbar-form select,.navbar-form .btn{display:inline-block;margin-bottom:0}.navbar-form input[type="image"],.navbar-form input[type="checkbox"],.navbar-form input[type="radio"]{margin-top:3px}.navbar-form .input-append,.navbar-form .input-prepend{margin-top:5px;white-space:nowrap}.navbar-form .input-append input,.navbar-form .input-prepend input{margin-top:0}.navbar-search{position:relative;float:left;margin-top:5px;margin-bottom:0}.navbar-search .search-query{padding:4px 14px;margin-bottom:0;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px;font-weight:normal;line-height:1;-webkit-border-radius:15px;-moz-border-radius:15px;border-radius:15px}.navbar-static-top{position:static;margin-bottom:0}.navbar-static-top .navbar-inner{-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.navbar-fixed-top,.navbar-fixed-bottom{position:fixed;right:0;left:0;z-index:1030;margin-bottom:0}.navbar-fixed-top .navbar-inner,.navbar-static-top .navbar-inner{border-width:0 0 1px}.navbar-fixed-bottom .navbar-inner{border-width:1px 0 0}.navbar-fixed-top .navbar-inner,.navbar-fixed-bottom .navbar-inner{padding-right:0;padding-left:0;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0}.navbar-static-top .container,.navbar-fixed-top .container,.navbar-fixed-bottom .container{width:940px}.navbar-fixed-top{top:0}.navbar-fixed-top .navbar-inner,.navbar-static-top .navbar-inner{-webkit-box-shadow:0 1px 10px rgba(0,0,0,0.1);-moz-box-shadow:0 1px 10px rgba(0,0,0,0.1);box-shadow:0 1px 10px rgba(0,0,0,0.1)}.navbar-fixed-bottom{bottom:0}.navbar-fixed-bottom .navbar-inner{-webkit-box-shadow:0 -1px 10px rgba(0,0,0,0.1);-moz-box-shadow:0 -1px 10px rgba(0,0,0,0.1);box-shadow:0 -1px 10px rgba(0,0,0,0.1)}.navbar .nav{position:relative;left:0;display:block;float:left;margin:0 10px 0 0}.navbar .nav.pull-right{float:right;margin-right:0}.navbar .nav>li{float:left}.navbar .nav>li>a{float:none;padding:10px 15px 10px;color:#777;text-decoration:none;text-shadow:0 1px 0 #fff}.navbar .nav .dropdown-toggle .caret{margin-top:8px}.navbar .nav>li>a:focus,.navbar .nav>li>a:hover{color:#333;text-decoration:none;background-color:transparent}.navbar .nav>.active>a,.navbar .nav>.active>a:hover,.navbar .nav>.active>a:focus{color:#555;text-decoration:none;background-color:#e5e5e5;-webkit-box-shadow:inset 0 3px 8px rgba(0,0,0,0.125);-moz-box-shadow:inset 0 3px 8px rgba(0,0,0,0.125);box-shadow:inset 0 3px 8px rgba(0,0,0,0.125)}.navbar .btn-navbar{display:none;float:right;padding:7px 10px;margin-right:5px;margin-left:5px;color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#ededed;*background-color:#e5e5e5;background-image:-moz-linear-gradient(top,#f2f2f2,#e5e5e5);background-image:-webkit-gradient(linear,0 0,0 100%,from(#f2f2f2),to(#e5e5e5));background-image:-webkit-linear-gradient(top,#f2f2f2,#e5e5e5);background-image:-o-linear-gradient(top,#f2f2f2,#e5e5e5);background-image:linear-gradient(to bottom,#f2f2f2,#e5e5e5);background-repeat:repeat-x;border-color:#e5e5e5 #e5e5e5 #bfbfbf;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2f2f2',endColorstr='#ffe5e5e5',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.075);-moz-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.075);box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.075)}.navbar .btn-navbar:hover,.navbar .btn-navbar:active,.navbar .btn-navbar.active,.navbar .btn-navbar.disabled,.navbar .btn-navbar[disabled]{color:#fff;background-color:#e5e5e5;*background-color:#d9d9d9}.navbar .btn-navbar:active,.navbar .btn-navbar.active{background-color:#ccc \9}.navbar .btn-navbar .icon-bar{display:block;width:18px;height:2px;background-color:#f5f5f5;-webkit-border-radius:1px;-moz-border-radius:1px;border-radius:1px;-webkit-box-shadow:0 1px 0 rgba(0,0,0,0.25);-moz-box-shadow:0 1px 0 rgba(0,0,0,0.25);box-shadow:0 1px 0 rgba(0,0,0,0.25)}.btn-navbar .icon-bar+.icon-bar{margin-top:3px}.navbar .nav>li>.dropdown-menu:before{position:absolute;top:-7px;left:9px;display:inline-block;border-right:7px solid transparent;border-bottom:7px solid #ccc;border-left:7px solid transparent;border-bottom-color:rgba(0,0,0,0.2);content:''}.navbar .nav>li>.dropdown-menu:after{position:absolute;top:-6px;left:10px;display:inline-block;border-right:6px solid transparent;border-bottom:6px solid #fff;border-left:6px solid transparent;content:''}.navbar-fixed-bottom .nav>li>.dropdown-menu:before{top:auto;bottom:-7px;border-top:7px solid #ccc;border-bottom:0;border-top-color:rgba(0,0,0,0.2)}.navbar-fixed-bottom .nav>li>.dropdown-menu:after{top:auto;bottom:-6px;border-top:6px solid #fff;border-bottom:0}.navbar .nav li.dropdown>a:hover .caret{border-top-color:#555;border-bottom-color:#555}.navbar .nav li.dropdown.open>.dropdown-toggle,.navbar .nav li.dropdown.active>.dropdown-toggle,.navbar .nav li.dropdown.open.active>.dropdown-toggle{color:#555;background-color:#e5e5e5}.navbar .nav li.dropdown>.dropdown-toggle .caret{border-top-color:#777;border-bottom-color:#777}.navbar .nav li.dropdown.open>.dropdown-toggle .caret,.navbar .nav li.dropdown.active>.dropdown-toggle .caret,.navbar .nav li.dropdown.open.active>.dropdown-toggle .caret{border-top-color:#555;border-bottom-color:#555}.navbar .pull-right>li>.dropdown-menu,.navbar .nav>li>.dropdown-menu.pull-right{right:0;left:auto}.navbar .pull-right>li>.dropdown-menu:before,.navbar .nav>li>.dropdown-menu.pull-right:before{right:12px;left:auto}.navbar .pull-right>li>.dropdown-menu:after,.navbar .nav>li>.dropdown-menu.pull-right:after{right:13px;left:auto}.navbar .pull-right>li>.dropdown-menu .dropdown-menu,.navbar .nav>li>.dropdown-menu.pull-right .dropdown-menu{right:100%;left:auto;margin-right:-1px;margin-left:0;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px}.navbar-inverse .navbar-inner{background-color:#1b1b1b;background-image:-moz-linear-gradient(top,#222,#111);background-image:-webkit-gradient(linear,0 0,0 100%,from(#222),to(#111));background-image:-webkit-linear-gradient(top,#222,#111);background-image:-o-linear-gradient(top,#222,#111);background-image:linear-gradient(to bottom,#222,#111);background-repeat:repeat-x;border-color:#252525;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222',endColorstr='#ff111111',GradientType=0)}.navbar-inverse .brand,.navbar-inverse .nav>li>a{color:#999;text-shadow:0 -1px 0 rgba(0,0,0,0.25)}.navbar-inverse .brand:hover,.navbar-inverse .nav>li>a:hover{color:#fff}.navbar-inverse .brand{color:#999}.navbar-inverse .navbar-text{color:#999}.navbar-inverse .nav>li>a:focus,.navbar-inverse .nav>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .nav .active>a,.navbar-inverse .nav .active>a:hover,.navbar-inverse .nav .active>a:focus{color:#fff;background-color:#111}.navbar-inverse .navbar-link{color:#999}.navbar-inverse .navbar-link:hover{color:#fff}.navbar-inverse .divider-vertical{border-right-color:#222;border-left-color:#111}.navbar-inverse .nav li.dropdown.open>.dropdown-toggle,.navbar-inverse .nav li.dropdown.active>.dropdown-toggle,.navbar-inverse .nav li.dropdown.open.active>.dropdown-toggle{color:#fff;background-color:#111}.navbar-inverse .nav li.dropdown>a:hover .caret{border-top-color:#fff;border-bottom-color:#fff}.navbar-inverse .nav li.dropdown>.dropdown-toggle .caret{border-top-color:#999;border-bottom-color:#999}.navbar-inverse .nav li.dropdown.open>.dropdown-toggle .caret,.navbar-inverse .nav li.dropdown.active>.dropdown-toggle .caret,.navbar-inverse .nav li.dropdown.open.active>.dropdown-toggle .caret{border-top-color:#fff;border-bottom-color:#fff}.navbar-inverse .navbar-search .search-query{color:#fff;background-color:#515151;border-color:#111;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,0.1),0 1px 0 rgba(255,255,255,0.15);-moz-box-shadow:inset 0 1px 2px rgba(0,0,0,0.1),0 1px 0 rgba(255,255,255,0.15);box-shadow:inset 0 1px 2px rgba(0,0,0,0.1),0 1px 0 rgba(255,255,255,0.15);-webkit-transition:none;-moz-transition:none;-o-transition:none;transition:none}.navbar-inverse .navbar-search .search-query:-moz-placeholder{color:#ccc}.navbar-inverse .navbar-search .search-query:-ms-input-placeholder{color:#ccc}.navbar-inverse .navbar-search .search-query::-webkit-input-placeholder{color:#ccc}.navbar-inverse .navbar-search .search-query:focus,.navbar-inverse .navbar-search .search-query.focused{padding:5px 15px;color:#333;text-shadow:0 1px 0 #fff;background-color:#fff;border:0;outline:0;-webkit-box-shadow:0 0 3px rgba(0,0,0,0.15);-moz-box-shadow:0 0 3px rgba(0,0,0,0.15);box-shadow:0 0 3px rgba(0,0,0,0.15)}.navbar-inverse .btn-navbar{color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#0e0e0e;*background-color:#040404;background-image:-moz-linear-gradient(top,#151515,#040404);background-image:-webkit-gradient(linear,0 0,0 100%,from(#151515),to(#040404));background-image:-webkit-linear-gradient(top,#151515,#040404);background-image:-o-linear-gradient(top,#151515,#040404);background-image:linear-gradient(to bottom,#151515,#040404);background-repeat:repeat-x;border-color:#040404 #040404 #000;border-color:rgba(0,0,0,0.1) rgba(0,0,0,0.1) rgba(0,0,0,0.25);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff151515',endColorstr='#ff040404',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.navbar-inverse .btn-navbar:hover,.navbar-inverse .btn-navbar:active,.navbar-inverse .btn-navbar.active,.navbar-inverse .btn-navbar.disabled,.navbar-inverse .btn-navbar[disabled]{color:#fff;background-color:#040404;*background-color:#000}.navbar-inverse .btn-navbar:active,.navbar-inverse .btn-navbar.active{background-color:#000 \9}.breadcrumb{padding:8px 15px;margin:0 0 20px;list-style:none;background-color:#f5f5f5;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.breadcrumb>li{display:inline-block;*display:inline;text-shadow:0 1px 0 #fff;*zoom:1}.breadcrumb>li>.divider{padding:0 5px;color:#ccc}.breadcrumb>.active{color:#999}.pagination{margin:20px 0}.pagination ul{display:inline-block;*display:inline;margin-bottom:0;margin-left:0;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;*zoom:1;-webkit-box-shadow:0 1px 2px rgba(0,0,0,0.05);-moz-box-shadow:0 1px 2px rgba(0,0,0,0.05);box-shadow:0 1px 2px rgba(0,0,0,0.05)}.pagination ul>li{display:inline}.pagination ul>li>a,.pagination ul>li>span{float:left;padding:4px 12px;line-height:20px;text-decoration:none;background-color:#fff;border:1px solid #ddd;border-left-width:0}.pagination ul>li>a:hover,.pagination ul>.active>a,.pagination ul>.active>span{background-color:#f5f5f5}.pagination ul>.active>a,.pagination ul>.active>span{color:#999;cursor:default}.pagination ul>.disabled>span,.pagination ul>.disabled>a,.pagination ul>.disabled>a:hover{color:#999;cursor:default;background-color:transparent}.pagination ul>li:first-child>a,.pagination ul>li:first-child>span{border-left-width:1px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-bottomleft:4px;-moz-border-radius-topleft:4px}.pagination ul>li:last-child>a,.pagination ul>li:last-child>span{-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;-moz-border-radius-topright:4px;-moz-border-radius-bottomright:4px}.pagination-centered{text-align:center}.pagination-right{text-align:right}.pagination-large ul>li>a,.pagination-large ul>li>span{padding:11px 19px;font-size:17.5px}.pagination-large ul>li:first-child>a,.pagination-large ul>li:first-child>span{-webkit-border-bottom-left-radius:6px;border-bottom-left-radius:6px;-webkit-border-top-left-radius:6px;border-top-left-radius:6px;-moz-border-radius-bottomleft:6px;-moz-border-radius-topleft:6px}.pagination-large ul>li:last-child>a,.pagination-large ul>li:last-child>span{-webkit-border-top-right-radius:6px;border-top-right-radius:6px;-webkit-border-bottom-right-radius:6px;border-bottom-right-radius:6px;-moz-border-radius-topright:6px;-moz-border-radius-bottomright:6px}.pagination-mini ul>li:first-child>a,.pagination-small ul>li:first-child>a,.pagination-mini ul>li:first-child>span,.pagination-small ul>li:first-child>span{-webkit-border-bottom-left-radius:3px;border-bottom-left-radius:3px;-webkit-border-top-left-radius:3px;border-top-left-radius:3px;-moz-border-radius-bottomleft:3px;-moz-border-radius-topleft:3px}.pagination-mini ul>li:last-child>a,.pagination-small ul>li:last-child>a,.pagination-mini ul>li:last-child>span,.pagination-small ul>li:last-child>span{-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-moz-border-radius-topright:3px;-moz-border-radius-bottomright:3px}.pagination-small ul>li>a,.pagination-small ul>li>span{padding:2px 10px;font-size:11.9px}.pagination-mini ul>li>a,.pagination-mini ul>li>span{padding:0 6px;font-size:10.5px}.pager{margin:20px 0;text-align:center;list-style:none;*zoom:1}.pager:before,.pager:after{display:table;line-height:0;content:""}.pager:after{clear:both}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;-webkit-border-radius:15px;-moz-border-radius:15px;border-radius:15px}.pager li>a:hover{text-decoration:none;background-color:#f5f5f5}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:hover,.pager .disabled>span{color:#999;cursor:default;background-color:#fff}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;background-color:#000}.modal-backdrop.fade{opacity:0}.modal-backdrop,.modal-backdrop.fade.in{opacity:.8;filter:alpha(opacity=80)}.modal{position:fixed;top:10%;left:50%;z-index:1050;width:560px;margin-left:-280px;background-color:#fff;border:1px solid #999;border:1px solid rgba(0,0,0,0.3);*border:1px solid #999;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px;outline:0;-webkit-box-shadow:0 3px 7px rgba(0,0,0,0.3);-moz-box-shadow:0 3px 7px rgba(0,0,0,0.3);box-shadow:0 3px 7px rgba(0,0,0,0.3);-webkit-background-clip:padding-box;-moz-background-clip:padding-box;background-clip:padding-box}.modal.fade{top:-25%;-webkit-transition:opacity .3s linear,top .3s ease-out;-moz-transition:opacity .3s linear,top .3s ease-out;-o-transition:opacity .3s linear,top .3s ease-out;transition:opacity .3s linear,top .3s ease-out}.modal.fade.in{top:10%}.modal-header{padding:9px 15px;border-bottom:1px solid #eee}.modal-header .close{margin-top:2px}.modal-header h3{margin:0;line-height:30px}.modal-body{position:relative;max-height:400px;padding:15px;overflow-y:auto}.modal-form{margin-bottom:0}.modal-footer{padding:14px 15px 15px;margin-bottom:0;text-align:right;background-color:#f5f5f5;border-top:1px solid #ddd;-webkit-border-radius:0 0 6px 6px;-moz-border-radius:0 0 6px 6px;border-radius:0 0 6px 6px;*zoom:1;-webkit-box-shadow:inset 0 1px 0 #fff;-moz-box-shadow:inset 0 1px 0 #fff;box-shadow:inset 0 1px 0 #fff}.modal-footer:before,.modal-footer:after{display:table;line-height:0;content:""}.modal-footer:after{clear:both}.modal-footer .btn+.btn{margin-bottom:0;margin-left:5px}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}.tooltip{position:absolute;z-index:1030;display:block;padding:5px;font-size:11px;opacity:0;filter:alpha(opacity=0);visibility:visible}.tooltip.in{opacity:.8;filter:alpha(opacity=80)}.tooltip.top{margin-top:-3px}.tooltip.right{margin-left:3px}.tooltip.bottom{margin-top:3px}.tooltip.left{margin-left:-3px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;text-decoration:none;background-color:#000;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-top-color:#000;border-width:5px 5px 0}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-right-color:#000;border-width:5px 5px 5px 0}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-left-color:#000;border-width:5px 0 5px 5px}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-bottom-color:#000;border-width:0 5px 5px}.popover{position:absolute;top:0;left:0;z-index:1010;display:none;width:236px;padding:1px;text-align:left;white-space:normal;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,0.2);-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,0.2);-moz-box-shadow:0 5px 10px rgba(0,0,0,0.2);box-shadow:0 5px 10px rgba(0,0,0,0.2);-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{padding:8px 14px;margin:0;font-size:14px;font-weight:normal;line-height:18px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;-webkit-border-radius:5px 5px 0 0;-moz-border-radius:5px 5px 0 0;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover .arrow,.popover .arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover .arrow{border-width:11px}.popover .arrow:after{border-width:10px;content:""}.popover.top .arrow{bottom:-11px;left:50%;margin-left:-11px;border-top-color:#999;border-top-color:rgba(0,0,0,0.25);border-bottom-width:0}.popover.top .arrow:after{bottom:1px;margin-left:-10px;border-top-color:#fff;border-bottom-width:0}.popover.right .arrow{top:50%;left:-11px;margin-top:-11px;border-right-color:#999;border-right-color:rgba(0,0,0,0.25);border-left-width:0}.popover.right .arrow:after{bottom:-10px;left:1px;border-right-color:#fff;border-left-width:0}.popover.bottom .arrow{top:-11px;left:50%;margin-left:-11px;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,0.25);border-top-width:0}.popover.bottom .arrow:after{top:1px;margin-left:-10px;border-bottom-color:#fff;border-top-width:0}.popover.left .arrow{top:50%;right:-11px;margin-top:-11px;border-left-color:#999;border-left-color:rgba(0,0,0,0.25);border-right-width:0}.popover.left .arrow:after{right:1px;bottom:-10px;border-left-color:#fff;border-right-width:0}.thumbnails{margin-left:-20px;list-style:none;*zoom:1}.thumbnails:before,.thumbnails:after{display:table;line-height:0;content:""}.thumbnails:after{clear:both}.row-fluid .thumbnails{margin-left:0}.thumbnails>li{float:left;margin-bottom:20px;margin-left:20px}.thumbnail{display:block;padding:4px;line-height:20px;border:1px solid #ddd;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.055);-moz-box-shadow:0 1px 3px rgba(0,0,0,0.055);box-shadow:0 1px 3px rgba(0,0,0,0.055);-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}a.thumbnail:hover{border-color:#08c;-webkit-box-shadow:0 1px 4px rgba(0,105,214,0.25);-moz-box-shadow:0 1px 4px rgba(0,105,214,0.25);box-shadow:0 1px 4px rgba(0,105,214,0.25)}.thumbnail>img{display:block;max-width:100%;margin-right:auto;margin-left:auto}.thumbnail .caption{padding:9px;color:#555}.media,.media-body{overflow:hidden;*overflow:visible;zoom:1}.media,.media .media{margin-top:15px}.media:first-child{margin-top:0}.media-object{display:block}.media-heading{margin:0 0 5px}.media .pull-left{margin-right:10px}.media .pull-right{margin-left:10px}.media-list{margin-left:0;list-style:none}.label,.badge{display:inline-block;padding:2px 4px;font-size:11.844px;font-weight:bold;line-height:14px;color:#fff;text-shadow:0 -1px 0 rgba(0,0,0,0.25);white-space:nowrap;vertical-align:baseline;background-color:#999}.label{-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}.badge{padding-right:9px;padding-left:9px;-webkit-border-radius:9px;-moz-border-radius:9px;border-radius:9px}.label:empty,.badge:empty{display:none}a.label:hover,a.badge:hover{color:#fff;text-decoration:none;cursor:pointer}.label-important,.badge-important{background-color:#b94a48}.label-important[href],.badge-important[href]{background-color:#953b39}.label-warning,.badge-warning{background-color:#f89406}.label-warning[href],.badge-warning[href]{background-color:#c67605}.label-success,.badge-success{background-color:#468847}.label-success[href],.badge-success[href]{background-color:#356635}.label-info,.badge-info{background-color:#3a87ad}.label-info[href],.badge-info[href]{background-color:#2d6987}.label-inverse,.badge-inverse{background-color:#333}.label-inverse[href],.badge-inverse[href]{background-color:#1a1a1a}.btn .label,.btn .badge{position:relative;top:-1px}.btn-mini .label,.btn-mini .badge{top:0}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-moz-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-ms-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-o-keyframes progress-bar-stripes{from{background-position:0 0}to{background-position:40px 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{height:20px;margin-bottom:20px;overflow:hidden;background-color:#f7f7f7;background-image:-moz-linear-gradient(top,#f5f5f5,#f9f9f9);background-image:-webkit-gradient(linear,0 0,0 100%,from(#f5f5f5),to(#f9f9f9));background-image:-webkit-linear-gradient(top,#f5f5f5,#f9f9f9);background-image:-o-linear-gradient(top,#f5f5f5,#f9f9f9);background-image:linear-gradient(to bottom,#f5f5f5,#f9f9f9);background-repeat:repeat-x;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5',endColorstr='#fff9f9f9',GradientType=0);-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,0.1);-moz-box-shadow:inset 0 1px 2px rgba(0,0,0,0.1);box-shadow:inset 0 1px 2px rgba(0,0,0,0.1)}.progress .bar{float:left;width:0;height:100%;font-size:12px;color:#fff;text-align:center;text-shadow:0 -1px 0 rgba(0,0,0,0.25);background-color:#0e90d2;background-image:-moz-linear-gradient(top,#149bdf,#0480be);background-image:-webkit-gradient(linear,0 0,0 100%,from(#149bdf),to(#0480be));background-image:-webkit-linear-gradient(top,#149bdf,#0480be);background-image:-o-linear-gradient(top,#149bdf,#0480be);background-image:linear-gradient(to bottom,#149bdf,#0480be);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff149bdf',endColorstr='#ff0480be',GradientType=0);-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,0.15);-moz-box-shadow:inset 0 -1px 0 rgba(0,0,0,0.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,0.15);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;-webkit-transition:width .6s ease;-moz-transition:width .6s ease;-o-transition:width .6s ease;transition:width .6s ease}.progress .bar+.bar{-webkit-box-shadow:inset 1px 0 0 rgba(0,0,0,0.15),inset 0 -1px 0 rgba(0,0,0,0.15);-moz-box-shadow:inset 1px 0 0 rgba(0,0,0,0.15),inset 0 -1px 0 rgba(0,0,0,0.15);box-shadow:inset 1px 0 0 rgba(0,0,0,0.15),inset 0 -1px 0 rgba(0,0,0,0.15)}.progress-striped .bar{background-color:#149bdf;background-image:-webkit-gradient(linear,0 100%,100% 0,color-stop(0.25,rgba(255,255,255,0.15)),color-stop(0.25,transparent),color-stop(0.5,transparent),color-stop(0.5,rgba(255,255,255,0.15)),color-stop(0.75,rgba(255,255,255,0.15)),color-stop(0.75,transparent),to(transparent));background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-moz-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);-webkit-background-size:40px 40px;-moz-background-size:40px 40px;-o-background-size:40px 40px;background-size:40px 40px}.progress.active .bar{-webkit-animation:progress-bar-stripes 2s linear infinite;-moz-animation:progress-bar-stripes 2s linear infinite;-ms-animation:progress-bar-stripes 2s linear infinite;-o-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-danger .bar,.progress .bar-danger{background-color:#dd514c;background-image:-moz-linear-gradient(top,#ee5f5b,#c43c35);background-image:-webkit-gradient(linear,0 0,0 100%,from(#ee5f5b),to(#c43c35));background-image:-webkit-linear-gradient(top,#ee5f5b,#c43c35);background-image:-o-linear-gradient(top,#ee5f5b,#c43c35);background-image:linear-gradient(to bottom,#ee5f5b,#c43c35);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b',endColorstr='#ffc43c35',GradientType=0)}.progress-danger.progress-striped .bar,.progress-striped .bar-danger{background-color:#ee5f5b;background-image:-webkit-gradient(linear,0 100%,100% 0,color-stop(0.25,rgba(255,255,255,0.15)),color-stop(0.25,transparent),color-stop(0.5,transparent),color-stop(0.5,rgba(255,255,255,0.15)),color-stop(0.75,rgba(255,255,255,0.15)),color-stop(0.75,transparent),to(transparent));background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-moz-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent)}.progress-success .bar,.progress .bar-success{background-color:#5eb95e;background-image:-moz-linear-gradient(top,#62c462,#57a957);background-image:-webkit-gradient(linear,0 0,0 100%,from(#62c462),to(#57a957));background-image:-webkit-linear-gradient(top,#62c462,#57a957);background-image:-o-linear-gradient(top,#62c462,#57a957);background-image:linear-gradient(to bottom,#62c462,#57a957);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462',endColorstr='#ff57a957',GradientType=0)}.progress-success.progress-striped .bar,.progress-striped .bar-success{background-color:#62c462;background-image:-webkit-gradient(linear,0 100%,100% 0,color-stop(0.25,rgba(255,255,255,0.15)),color-stop(0.25,transparent),color-stop(0.5,transparent),color-stop(0.5,rgba(255,255,255,0.15)),color-stop(0.75,rgba(255,255,255,0.15)),color-stop(0.75,transparent),to(transparent));background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-moz-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent)}.progress-info .bar,.progress .bar-info{background-color:#4bb1cf;background-image:-moz-linear-gradient(top,#5bc0de,#339bb9);background-image:-webkit-gradient(linear,0 0,0 100%,from(#5bc0de),to(#339bb9));background-image:-webkit-linear-gradient(top,#5bc0de,#339bb9);background-image:-o-linear-gradient(top,#5bc0de,#339bb9);background-image:linear-gradient(to bottom,#5bc0de,#339bb9);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de',endColorstr='#ff339bb9',GradientType=0)}.progress-info.progress-striped .bar,.progress-striped .bar-info{background-color:#5bc0de;background-image:-webkit-gradient(linear,0 100%,100% 0,color-stop(0.25,rgba(255,255,255,0.15)),color-stop(0.25,transparent),color-stop(0.5,transparent),color-stop(0.5,rgba(255,255,255,0.15)),color-stop(0.75,rgba(255,255,255,0.15)),color-stop(0.75,transparent),to(transparent));background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-moz-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent)}.progress-warning .bar,.progress .bar-warning{background-color:#faa732;background-image:-moz-linear-gradient(top,#fbb450,#f89406);background-image:-webkit-gradient(linear,0 0,0 100%,from(#fbb450),to(#f89406));background-image:-webkit-linear-gradient(top,#fbb450,#f89406);background-image:-o-linear-gradient(top,#fbb450,#f89406);background-image:linear-gradient(to bottom,#fbb450,#f89406);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450',endColorstr='#fff89406',GradientType=0)}.progress-warning.progress-striped .bar,.progress-striped .bar-warning{background-color:#fbb450;background-image:-webkit-gradient(linear,0 100%,100% 0,color-stop(0.25,rgba(255,255,255,0.15)),color-stop(0.25,transparent),color-stop(0.5,transparent),color-stop(0.5,rgba(255,255,255,0.15)),color-stop(0.75,rgba(255,255,255,0.15)),color-stop(0.75,transparent),to(transparent));background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-moz-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,0.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,0.15) 50%,rgba(255,255,255,0.15) 75%,transparent 75%,transparent)}.accordion{margin-bottom:20px}.accordion-group{margin-bottom:2px;border:1px solid #e5e5e5;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px}.accordion-heading{border-bottom:0}.accordion-heading .accordion-toggle{display:block;padding:8px 15px}.accordion-toggle{cursor:pointer}.accordion-inner{padding:9px 15px;border-top:1px solid #e5e5e5}.carousel{position:relative;margin-bottom:20px;line-height:1}.carousel-inner{position:relative;width:100%;overflow:hidden}.carousel-inner>.item{position:relative;display:none;-webkit-transition:.6s ease-in-out left;-moz-transition:.6s ease-in-out left;-o-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>img{display:block;line-height:1}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:40%;left:15px;width:40px;height:40px;margin-top:-20px;font-size:60px;font-weight:100;line-height:30px;color:#fff;text-align:center;background:#222;border:3px solid #fff;-webkit-border-radius:23px;-moz-border-radius:23px;border-radius:23px;opacity:.5;filter:alpha(opacity=50)}.carousel-control.right{right:15px;left:auto}.carousel-control:hover{color:#fff;text-decoration:none;opacity:.9;filter:alpha(opacity=90)}.carousel-caption{position:absolute;right:0;bottom:0;left:0;padding:15px;background:#333;background:rgba(0,0,0,0.75)}.carousel-caption h4,.carousel-caption p{line-height:20px;color:#fff}.carousel-caption h4{margin:0 0 5px}.carousel-caption p{margin-bottom:0}.hero-unit{padding:60px;margin-bottom:30px;font-size:18px;font-weight:200;line-height:30px;color:inherit;background-color:#eee;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px}.hero-unit h1{margin-bottom:0;font-size:60px;line-height:1;letter-spacing:-1px;color:inherit}.hero-unit li{line-height:30px}.pull-right{float:right}.pull-left{float:left}.hide{display:none}.show{display:block}.invisible{visibility:hidden}.affix{position:fixed} diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings-white.png b/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings-white.png new file mode 100644 index 0000000..3bf6484 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings-white.png differ diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings.png b/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings.png new file mode 100644 index 0000000..a996999 Binary files /dev/null and b/build.docset/Contents/Resources/Documents/_static/bootstrap/img/glyphicons-halflings.png differ diff --git a/build.docset/Contents/Resources/Documents/_static/bootstrap/js/bootstrap.js b/build.docset/Contents/Resources/Documents/_static/bootstrap/js/bootstrap.js new file mode 100644 index 0000000..6c15a58 --- /dev/null +++ b/build.docset/Contents/Resources/Documents/_static/bootstrap/js/bootstrap.js @@ -0,0 +1,2159 @@ +/* =================================================== + * bootstrap-transition.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#transitions + * =================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ========================================================== */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* CSS TRANSITION SUPPORT (http://www.modernizr.com/) + * ======================================================= */ + + $(function () { + + $.support.transition = (function () { + + var transitionEnd = (function () { + + var el = document.createElement('bootstrap') + , transEndEventNames = { + 'WebkitTransition' : 'webkitTransitionEnd' + , 'MozTransition' : 'transitionend' + , 'OTransition' : 'oTransitionEnd otransitionend' + , 'transition' : 'transitionend' + } + , name + + for (name in transEndEventNames){ + if (el.style[name] !== undefined) { + return transEndEventNames[name] + } + } + + }()) + + return transitionEnd && { + end: transitionEnd + } + + })() + + }) + +}(window.jQuery);/* ========================================================== + * bootstrap-alert.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#alerts + * ========================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ========================================================== */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* ALERT CLASS DEFINITION + * ====================== */ + + var dismiss = '[data-dismiss="alert"]' + , Alert = function (el) { + $(el).on('click', dismiss, this.close) + } + + Alert.prototype.close = function (e) { + var $this = $(this) + , selector = $this.attr('data-target') + , $parent + + if (!selector) { + selector = $this.attr('href') + selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7 + } + + $parent = $(selector) + + e && e.preventDefault() + + $parent.length || ($parent = $this.hasClass('alert') ? $this : $this.parent()) + + $parent.trigger(e = $.Event('close')) + + if (e.isDefaultPrevented()) return + + $parent.removeClass('in') + + function removeElement() { + $parent + .trigger('closed') + .remove() + } + + $.support.transition && $parent.hasClass('fade') ? + $parent.on($.support.transition.end, removeElement) : + removeElement() + } + + + /* ALERT PLUGIN DEFINITION + * ======================= */ + + var old = $.fn.alert + + $.fn.alert = function (option) { + return this.each(function () { + var $this = $(this) + , data = $this.data('alert') + if (!data) $this.data('alert', (data = new Alert(this))) + if (typeof option == 'string') data[option].call($this) + }) + } + + $.fn.alert.Constructor = Alert + + + /* ALERT NO CONFLICT + * ================= */ + + $.fn.alert.noConflict = function () { + $.fn.alert = old + return this + } + + + /* ALERT DATA-API + * ============== */ + + $(document).on('click.alert.data-api', dismiss, Alert.prototype.close) + +}(window.jQuery);/* ============================================================ + * bootstrap-button.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#buttons + * ============================================================ + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============================================================ */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* BUTTON PUBLIC CLASS DEFINITION + * ============================== */ + + var Button = function (element, options) { + this.$element = $(element) + this.options = $.extend({}, $.fn.button.defaults, options) + } + + Button.prototype.setState = function (state) { + var d = 'disabled' + , $el = this.$element + , data = $el.data() + , val = $el.is('input') ? 'val' : 'html' + + state = state + 'Text' + data.resetText || $el.data('resetText', $el[val]()) + + $el[val](data[state] || this.options[state]) + + // push to event loop to allow forms to submit + setTimeout(function () { + state == 'loadingText' ? + $el.addClass(d).attr(d, d) : + $el.removeClass(d).removeAttr(d) + }, 0) + } + + Button.prototype.toggle = function () { + var $parent = this.$element.closest('[data-toggle="buttons-radio"]') + + $parent && $parent + .find('.active') + .removeClass('active') + + this.$element.toggleClass('active') + } + + + /* BUTTON PLUGIN DEFINITION + * ======================== */ + + var old = $.fn.button + + $.fn.button = function (option) { + return this.each(function () { + var $this = $(this) + , data = $this.data('button') + , options = typeof option == 'object' && option + if (!data) $this.data('button', (data = new Button(this, options))) + if (option == 'toggle') data.toggle() + else if (option) data.setState(option) + }) + } + + $.fn.button.defaults = { + loadingText: 'loading...' + } + + $.fn.button.Constructor = Button + + + /* BUTTON NO CONFLICT + * ================== */ + + $.fn.button.noConflict = function () { + $.fn.button = old + return this + } + + + /* BUTTON DATA-API + * =============== */ + + $(document).on('click.button.data-api', '[data-toggle^=button]', function (e) { + var $btn = $(e.target) + if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn') + $btn.button('toggle') + }) + +}(window.jQuery);/* ========================================================== + * bootstrap-carousel.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#carousel + * ========================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ========================================================== */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* CAROUSEL CLASS DEFINITION + * ========================= */ + + var Carousel = function (element, options) { + this.$element = $(element) + this.options = options + this.options.pause == 'hover' && this.$element + .on('mouseenter', $.proxy(this.pause, this)) + .on('mouseleave', $.proxy(this.cycle, this)) + } + + Carousel.prototype = { + + cycle: function (e) { + if (!e) this.paused = false + this.options.interval + && !this.paused + && (this.interval = setInterval($.proxy(this.next, this), this.options.interval)) + return this + } + + , to: function (pos) { + var $active = this.$element.find('.item.active') + , children = $active.parent().children() + , activePos = children.index($active) + , that = this + + if (pos > (children.length - 1) || pos < 0) return + + if (this.sliding) { + return this.$element.one('slid', function () { + that.to(pos) + }) + } + + if (activePos == pos) { + return this.pause().cycle() + } + + return this.slide(pos > activePos ? 'next' : 'prev', $(children[pos])) + } + + , pause: function (e) { + if (!e) this.paused = true + if (this.$element.find('.next, .prev').length && $.support.transition.end) { + this.$element.trigger($.support.transition.end) + this.cycle() + } + clearInterval(this.interval) + this.interval = null + return this + } + + , next: function () { + if (this.sliding) return + return this.slide('next') + } + + , prev: function () { + if (this.sliding) return + return this.slide('prev') + } + + , slide: function (type, next) { + var $active = this.$element.find('.item.active') + , $next = next || $active[type]() + , isCycling = this.interval + , direction = type == 'next' ? 'left' : 'right' + , fallback = type == 'next' ? 'first' : 'last' + , that = this + , e + + this.sliding = true + + isCycling && this.pause() + + $next = $next.length ? $next : this.$element.find('.item')[fallback]() + + e = $.Event('slide', { + relatedTarget: $next[0] + }) + + if ($next.hasClass('active')) return + + if ($.support.transition && this.$element.hasClass('slide')) { + this.$element.trigger(e) + if (e.isDefaultPrevented()) return + $next.addClass(type) + $next[0].offsetWidth // force reflow + $active.addClass(direction) + $next.addClass(direction) + this.$element.one($.support.transition.end, function () { + $next.removeClass([type, direction].join(' ')).addClass('active') + $active.removeClass(['active', direction].join(' ')) + that.sliding = false + setTimeout(function () { that.$element.trigger('slid') }, 0) + }) + } else { + this.$element.trigger(e) + if (e.isDefaultPrevented()) return + $active.removeClass('active') + $next.addClass('active') + this.sliding = false + this.$element.trigger('slid') + } + + isCycling && this.cycle() + + return this + } + + } + + + /* CAROUSEL PLUGIN DEFINITION + * ========================== */ + + var old = $.fn.carousel + + $.fn.carousel = function (option) { + return this.each(function () { + var $this = $(this) + , data = $this.data('carousel') + , options = $.extend({}, $.fn.carousel.defaults, typeof option == 'object' && option) + , action = typeof option == 'string' ? option : options.slide + if (!data) $this.data('carousel', (data = new Carousel(this, options))) + if (typeof option == 'number') data.to(option) + else if (action) data[action]() + else if (options.interval) data.cycle() + }) + } + + $.fn.carousel.defaults = { + interval: 5000 + , pause: 'hover' + } + + $.fn.carousel.Constructor = Carousel + + + /* CAROUSEL NO CONFLICT + * ==================== */ + + $.fn.carousel.noConflict = function () { + $.fn.carousel = old + return this + } + + /* CAROUSEL DATA-API + * ================= */ + + $(document).on('click.carousel.data-api', '[data-slide]', function (e) { + var $this = $(this), href + , $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7 + , options = $.extend({}, $target.data(), $this.data()) + $target.carousel(options) + e.preventDefault() + }) + +}(window.jQuery);/* ============================================================= + * bootstrap-collapse.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#collapse + * ============================================================= + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============================================================ */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* COLLAPSE PUBLIC CLASS DEFINITION + * ================================ */ + + var Collapse = function (element, options) { + this.$element = $(element) + this.options = $.extend({}, $.fn.collapse.defaults, options) + + if (this.options.parent) { + this.$parent = $(this.options.parent) + } + + this.options.toggle && this.toggle() + } + + Collapse.prototype = { + + constructor: Collapse + + , dimension: function () { + var hasWidth = this.$element.hasClass('width') + return hasWidth ? 'width' : 'height' + } + + , show: function () { + var dimension + , scroll + , actives + , hasData + + if (this.transitioning) return + + dimension = this.dimension() + scroll = $.camelCase(['scroll', dimension].join('-')) + actives = this.$parent && this.$parent.find('> .accordion-group > .in') + + if (actives && actives.length) { + hasData = actives.data('collapse') + if (hasData && hasData.transitioning) return + actives.collapse('hide') + hasData || actives.data('collapse', null) + } + + this.$element[dimension](0) + this.transition('addClass', $.Event('show'), 'shown') + $.support.transition && this.$element[dimension](this.$element[0][scroll]) + } + + , hide: function () { + var dimension + if (this.transitioning) return + dimension = this.dimension() + this.reset(this.$element[dimension]()) + this.transition('removeClass', $.Event('hide'), 'hidden') + this.$element[dimension](0) + } + + , reset: function (size) { + var dimension = this.dimension() + + this.$element + .removeClass('collapse') + [dimension](size || 'auto') + [0].offsetWidth + + this.$element[size !== null ? 'addClass' : 'removeClass']('collapse') + + return this + } + + , transition: function (method, startEvent, completeEvent) { + var that = this + , complete = function () { + if (startEvent.type == 'show') that.reset() + that.transitioning = 0 + that.$element.trigger(completeEvent) + } + + this.$element.trigger(startEvent) + + if (startEvent.isDefaultPrevented()) return + + this.transitioning = 1 + + this.$element[method]('in') + + $.support.transition && this.$element.hasClass('collapse') ? + this.$element.one($.support.transition.end, complete) : + complete() + } + + , toggle: function () { + this[this.$element.hasClass('in') ? 'hide' : 'show']() + } + + } + + + /* COLLAPSE PLUGIN DEFINITION + * ========================== */ + + var old = $.fn.collapse + + $.fn.collapse = function (option) { + return this.each(function () { + var $this = $(this) + , data = $this.data('collapse') + , options = typeof option == 'object' && option + if (!data) $this.data('collapse', (data = new Collapse(this, options))) + if (typeof option == 'string') data[option]() + }) + } + + $.fn.collapse.defaults = { + toggle: true + } + + $.fn.collapse.Constructor = Collapse + + + /* COLLAPSE NO CONFLICT + * ==================== */ + + $.fn.collapse.noConflict = function () { + $.fn.collapse = old + return this + } + + + /* COLLAPSE DATA-API + * ================= */ + + $(document).on('click.collapse.data-api', '[data-toggle=collapse]', function (e) { + var $this = $(this), href + , target = $this.attr('data-target') + || e.preventDefault() + || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') //strip for ie7 + , option = $(target).data('collapse') ? 'toggle' : $this.data() + $this[$(target).hasClass('in') ? 'addClass' : 'removeClass']('collapsed') + $(target).collapse(option) + }) + +}(window.jQuery);/* ============================================================ + * bootstrap-dropdown.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#dropdowns + * ============================================================ + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============================================================ */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* DROPDOWN CLASS DEFINITION + * ========================= */ + + var toggle = '[data-toggle=dropdown]' + , Dropdown = function (element) { + var $el = $(element).on('click.dropdown.data-api', this.toggle) + $('html').on('click.dropdown.data-api', function () { + $el.parent().removeClass('open') + }) + } + + Dropdown.prototype = { + + constructor: Dropdown + + , toggle: function (e) { + var $this = $(this) + , $parent + , isActive + + if ($this.is('.disabled, :disabled')) return + + $parent = getParent($this) + + isActive = $parent.hasClass('open') + + clearMenus() + + if (!isActive) { + $parent.toggleClass('open') + } + + $this.focus() + + return false + } + + , keydown: function (e) { + var $this + , $items + , $active + , $parent + , isActive + , index + + if (!/(38|40|27)/.test(e.keyCode)) return + + $this = $(this) + + e.preventDefault() + e.stopPropagation() + + if ($this.is('.disabled, :disabled')) return + + $parent = getParent($this) + + isActive = $parent.hasClass('open') + + if (!isActive || (isActive && e.keyCode == 27)) return $this.click() + + $items = $('[role=menu] li:not(.divider):visible a', $parent) + + if (!$items.length) return + + index = $items.index($items.filter(':focus')) + + if (e.keyCode == 38 && index > 0) index-- // up + if (e.keyCode == 40 && index < $items.length - 1) index++ // down + if (!~index) index = 0 + + $items + .eq(index) + .focus() + } + + } + + function clearMenus() { + $(toggle).each(function () { + getParent($(this)).removeClass('open') + }) + } + + function getParent($this) { + var selector = $this.attr('data-target') + , $parent + + if (!selector) { + selector = $this.attr('href') + selector = selector && /#/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') //strip for ie7 + } + + $parent = $(selector) + $parent.length || ($parent = $this.parent()) + + return $parent + } + + + /* DROPDOWN PLUGIN DEFINITION + * ========================== */ + + var old = $.fn.dropdown + + $.fn.dropdown = function (option) { + return this.each(function () { + var $this = $(this) + , data = $this.data('dropdown') + if (!data) $this.data('dropdown', (data = new Dropdown(this))) + if (typeof option == 'string') data[option].call($this) + }) + } + + $.fn.dropdown.Constructor = Dropdown + + + /* DROPDOWN NO CONFLICT + * ==================== */ + + $.fn.dropdown.noConflict = function () { + $.fn.dropdown = old + return this + } + + + /* APPLY TO STANDARD DROPDOWN ELEMENTS + * =================================== */ + + $(document) + .on('click.dropdown.data-api touchstart.dropdown.data-api', clearMenus) + .on('click.dropdown touchstart.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() }) + .on('touchstart.dropdown.data-api', '.dropdown-menu', function (e) { e.stopPropagation() }) + .on('click.dropdown.data-api touchstart.dropdown.data-api' , toggle, Dropdown.prototype.toggle) + .on('keydown.dropdown.data-api touchstart.dropdown.data-api', toggle + ', [role=menu]' , Dropdown.prototype.keydown) + +}(window.jQuery);/* ========================================================= + * bootstrap-modal.js v2.2.2 + * http://twitter.github.com/bootstrap/javascript.html#modals + * ========================================================= + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ========================================================= */ + + +!function ($) { + + "use strict"; // jshint ;_; + + + /* MODAL CLASS DEFINITION + * ====================== */ + + var Modal = function (element, options) { + this.options = options + this.$element = $(element) + .delegate('[data-dismiss="modal"]', 'click.dismiss.modal', $.proxy(this.hide, this)) + this.options.remote && this.$element.find('.modal-body').load(this.options.remote) + } + + Modal.prototype = { + + constructor: Modal + + , toggle: function () { + return this[!this.isShown ? 'show' : 'hide']() + } + + , show: function () { + var that = this + , e = $.Event('show') + + this.$element.trigger(e) + + if (this.isShown || e.isDefaultPrevented()) return + + this.isShown = true + + this.escape() + + this.backdrop(function () { + var transition = $.support.transition && that.$element.hasClass('fade') + + if (!that.$element.parent().length) { + that.$element.appendTo(document.body) //don't move modals dom position + } + + that.$element + .show() + + if (transition) { + that.$element[0].offsetWidth // force reflow + } + + that.$element + .addClass('in') + .attr('aria-hidden', false) + + that.enforceFocus() + + transition ? + that.$element.one($.support.transition.end, function () { that.$element.focus().trigger('shown') }) : + that.$element.focus().trigger('shown') + + }) + } + + , hide: function (e) { + e && e.preventDefault() + + var that = this + + e = $.Event('hide') + + this.$element.trigger(e) + + if (!this.isShown || e.isDefaultPrevented()) return + + this.isShown = false + + this.escape() + + $(document).off('focusin.modal') + + this.$element + .removeClass('in') + .attr('aria-hidden', true) + + $.support.transition && this.$element.hasClass('fade') ? + this.hideWithTransition() : + this.hideModal() + } + + , enforceFocus: function () { + var that = this + $(document).on('focusin.modal', function (e) { + if (that.$element[0] !== e.target && !that.$element.has(e.target).length) { + that.$element.focus() + } + }) + } + + , escape: function () { + var that = this + if (this.isShown && this.options.keyboard) { + this.$element.on('keyup.dismiss.modal', function ( e ) { + e.which == 27 && that.hide() + }) + } else if (!this.isShown) { + this.$element.off('keyup.dismiss.modal') + } + } + + , hideWithTransition: function () { + var that = this + , timeout = setTimeout(function () { + that.$element.off($.support.transition.end) + that.hideModal() + }, 500) + + this.$element.one($.support.transition.end, function () { + clearTimeout(timeout) + that.hideModal() + }) + } + + , hideModal: function (that) { + this.$element + .hide() + .trigger('hidden') + + this.backdrop() + } + + , removeBackdrop: function () { + this.$backdrop.remove() + this.$backdrop = null + } + + , backdrop: function (callback) { + var that = this + , animate = this.$element.hasClass('fade') ? 'fade' : '' + + if (this.isShown && this.options.backdrop) { + var doAnimate = $.support.transition && animate + + this.$backdrop = $('