Download the PHP package orchestra/memory without Composer

On this page you can find all versions of the php package orchestra/memory. 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 memory

Memory Component for Orchestra Platform

Memory Component handles runtime configuration either using "in memory" Runtime or database using Cache, Fluent Query Builder or Eloquent ORM. Instead of just allowing static configuration to be used, Memory Component allow those configuration to be persistent in between request by utilising multiple data storage option either through cache or database.

tests Latest Stable Version Total Downloads License Coverage Status

Version Compatibility

Laravel Memory
5.5.x 3.5.x
5.6.x 3.6.x
5.7.x 3.7.x
5.8.x 3.8.x
6.x 4.x
7.x 5.x
8.x 6.x

Installation

To install through composer, run the following command from terminal:

Configuration

Next add the service provider in config/app.php.

Aliases

You might want to add Orchestra\Support\Facades\Memory to class aliases in config/app.php:

Migrations

Before we can start using Memory Component, please run the following:

php artisan migrate

Publish Configuration

Optionally, you can also publish the configuration file if there any requirement to change the default:

Usage

Creating Instance

Below are list of possible ways to use Memory Component:

However, most of the time you wouldn't need to have additional memory instance other than the default which is using orchestra_options table.

When using with Orchestra Platform, Memory::make() would be used throughout the application.

Storing Items

Storing items in the Memory Component is simple. Simply call the put method:

The first parameter is the key to the config item. You will use this key to retrieve the item from the config. The second parameter is the value of the item.

Retrieving Items

Retrieving items from Memory Component is even more simple than storing them. It is done using the get method. Just mention the key of the item you wish to retrieve:

By default, NULL will be returned if the item does not exist. However, you may pass a different default value as a second parameter to the method:

Now, "Fred" will be returned if the "site.author" item does not exist.

Removing Items

Need to get rid of an item? No problem. Just mention the name of the item to the forget method:

Extending Memory

There might be requirement that a different type of storage engine would be use for memory instance, you can extending it by adding your own handler.

You can also extends Orchestra\Memory\Handler which add some boilerplate code on your custom handler.


All versions of memory with dependencies

PHP Build Version
Package Version
Requires php Version ^7.3 || ^8.0
illuminate/database Version ^8.37
orchestra/contracts Version ^6.0
orchestra/support Version ^6.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 orchestra/memory contains the following files

Loading the files please wait ....