Download the PHP package dwgebler/doclite without Composer

On this page you can find all versions of the php package dwgebler/doclite. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package doclite

DocLite

A powerful PHP NoSQL document store built on top of SQLite.

Build Status

Table of contents

About DocLite

DocLite is a powerful NoSQL document store for PHP built on top of SQLite. It uses the PHP PDO SQLite library to access a SQLite database and automatically manage documents organized in to named collections, which are stored as JSON.

DocLite takes advantage of the SQLite JSON1 extension (this is usually bundled in to the libsqlite included with your PHP distribution, so you probably already have it) to store, parse, index and query JSON documents - giving you the power and flexibility of a fully transactional and ACID compliant NoSQL solution, yet contained within the local file system. No need for more complex systems like Mongo, CouchDB or Elasticsearch when your requirements are slim. No need for any external dependencies, just PHP with PDO SQLite enabled.

DocLite provides a simple, intuitive, flexible and powerful PHP library that you can learn, install and start using in minutes.

Why DocLite?

DocLite lends itself well to a variety of use cases, including but not limited to:

Broadly speaking, DocLite is suitable for the same uses cases as the underlying SQLite engine it is built on, but where you desire a NoSQL solution.

Getting Started

System requirements - PHP 7.4 or above - With PDO SQLite enabled, built against libsqlite ≥ 3.18.0 with JSON1 extension. (on most systems, if you're running PHP 7.4 you probably already meet the second requirement)
Installation Install with [Composer](https://getcomposer.org/) `composer require dwgebler/doclite`
Usage Overview DocLite provides both a `FileDatabase` and `MemoryDatabase` implementation. To create or open an existing database, simply create a `Database` object, specifying the file path if using a `FileDatabase`. If your `FileDatabase` does not exist, it will be created (ensure your script has the appropriate write permissions). This will include creating any parent directories as required. If you specify an existing directory without a filename, a default filename `data.db` will be used. Once you have opened a database, you can obtain a document `Collection` which will be automatically created if it does not exist. The `Collection` object can then be used to retrieve, create and manipulate documents. In the example above, `$user` is an instance of a DocLite `Document`, but you can also hydrate objects of your own custom classes from a collection. To learn more about the `Collection` object including how to query a document store, please read the full documentation below.

The Database

DocLite is built on top of SQLite 3 and supports two types of database; file and memory. The corresponding classes are FileDatabase and MemoryDatabase.

Creating a memory database

MemoryDatabase is stored in volatile memory and is therefore ephemeral for the lifetime of your application scripts. Its constructor takes optional parameters:

php use Gebler\Doclite\MemoryDatabase;

$db = new MemoryDatabase();

// With full text search enabled and a 2-second connection timeout $logger = new \Monolog\Logger('my-logger'); $db = new MemoryDatabase(true, 2, $logger); yaml username: adamjones first_name: Adam last_name: Jones password: "$2y$10$LRS.0xUCJjWSmQuWMMRsuurZ0OGlU.NH7KYXsipzkfUa0YREEarj2" address: street: 123 Fake Street area: Testville county: Testshire postcode: TE1 3ST roles:

You can now typehint a DatabaseInterface like any other service, using the alias $memoryDb as the parameter name if you'd like a MemoryDatabase.

Licensing

DocLite is available under the MIT license as open source software.

If you use DocLite and find it useful, I am very grateful for any support towards its future development.

Donate

Bugs, issues

Please raise an issue on the project GitHub if you encounter any problems. I am always interested in improving the software.

Contact the author

You can email me on [email protected]


All versions of doclite with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4
ext-json Version *
ext-pdo Version *
ext-pdo_sqlite Version *
swaggest/json-schema Version ^0.12.31
symfony/property-access Version ^5.2 || ^6.0 || ^7.0
symfony/property-info Version ^5.2 || ^6.0 || ^7.0
symfony/serializer Version ^5.2 || ^6.0 || ^7.0
symfony/uid Version ^5.3 || ^6.0 || ^7.0
symfony/yaml Version ^5.2 || ^6.0 || ^7.0
psr/log Version ^1.1 || ^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dwgebler/doclite contains the following files

Loading the files please wait ....