Download the PHP package brewerwall/unitz without Composer

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

Unitz

example workflow

Introduction

Unitz is a way to address easy conversions among various measurable units. A utility that helps convert a unit to all types and agnostic to what type of unit it was originally set as.

Installation

Single Type Use

Service Provider Use

You can inject the UnitzService class into your application. Setting the user's preferences as an argument in the constructor will allow you to use the getValue() method to get the user's preferred unit of measure.

`

User Centric Unit Creation

When setting a user's preference in the UnitService, you no longer need to specify what type of unit the user is inputting by using the userValue argument in the constructor of the Unit. If the user's value needs to change, the setValue() method will also accomplish the same idea.

User Centric With Service Provider

`

Available Units

Unit Types
Gravity Plato, SpecificGravity, Brix
Pressure Psi, Bar
Temperature Celsius, Fahrenheit
Volume Ounce, Gallon, Barrel, Milliliter, Liter, Hectoliter
Weight Ounce, Pound, Gram, Kilogram
Color Srm, Ebc, Lovibond
Time Millisecond, Second, Minute, Hour, Day, Week, Month, Year
Distillate Proof, Alcohol Percent
Length Inch, Foot, Yard, Mile, Millimeter, Centimeter, Meter, Kilometer

Preferences

By default, all units have a getValue() method that returns the users preference of unit type. There is a default preference set, but can be overridden when instantiating a new unit.

Default
Example

Rounding

In each type's get method, there is the option to pass in a precision of rounding. This also includes the getValue() method that all units share.

Rate

A way of representing a rate of change between two units. When accessing values of rates, all will follow the naming pattern of $rate->get{Unit}Per{Unit} for the respective units. Example using Flow: $flow->getGallonPerHour()

Flow

This class represent the amount of Volume flowed over a period of Time.


Boil

This class represent the amount of Volume boiled over a period of Time.


Speed

This class represent the amount of Length traveled over a period of Time.


Calculate

A library of calculations that can be used with various Unitz classes.

Area

This class will calculate Area related calculations.


Rectangle

This method will calculate the area of a rectangle based on the length and width.

Arguments
Returns

Square

This method will calculate the area of a square based on the length of one side.

Arguments
Returns

Circle

This method will calculate the area of a circle based on the radius.

Arguments
Returns

Ellipse

This method will calculate the area of an ellipse based on the major and minor axis.

Arguments
Returns

Triangle

This method will calculate the area of a triangle based on the base and height.

Arguments
Returns

Equilateral Triangle

This method will calculate the area of an equilateral triangle based on the length of one side.

Arguments
Returns

Trapezoid

This method will calculate the area of a trapezoid based on the length of the two bases and the height.

Arguments
Returns

Regular Pentagon

This method will calculate the area of a regular pentagon based on the length of one side.

Arguments
Returns

Regular Hexagon

This method will calculate the area of a regular hexagon based on the length of one side.

Arguments
Returns

Regular Heptagon

This method will calculate the area of a regular heptagon based on the length of one side.

Arguments
Returns

Regular Octagon

This method will calculate the area of a regular octagon based on the length of one side.

Arguments
Returns

Regular Nonagon

This method will calculate the area of a regular nonagon based on the length of one side.

Arguments
Returns

Regular Decagon

This method will calculate the area of a regular decagon based on the length of one side.

Arguments
Returns

Beer

This class will calculate Beer related calculations.


Alcohol By Volume (ABV)

Alcohol By Volume (ABV) is the percent of alcohol content in the beer based on the original gravity, final gravity and formula version. Source of equation is at Brewer's Friend.

Arguments
Returns

Alcohol By Weight (ABW)

Alcohol By Weight (ABW) is weighing the amount of alcohol in a fixed volume of liquid and comparing it to the weight of pure water based on the original gravity and final gravity.

Arguments
Returns

Standard Reference Method (SRM)

Standard Reference Method (Srm) is the method for color assessment of wort or beer as published in the recommended methods of the American Society of Brewing Chemists

Arguments
Returns

Malt Color Unit (MCU)

Malt Color Unit (MCU) is an equation that helps determine what color a beer would be.

Arguments
Returns

International Bitterness Units (IBU)

International Bitterness Units (IBU) is the bitterness of the beer based on the alpha acid of the hops, weight of the hops, time in the boil, gravity of the wort, and volume of the wort.

Based off Palmer's Calculation

Arguments
Returns

Alpha Acid Units (AAU)

Alpha Acid Units (AAU) is the potential bitterness of the hops based on the alpha acid and weight.

Arguments
Returns

Hop Utilization

This is a hop utilization factor based on the Tinseth formula derived by Glenn Tinseth.

Arguments
Returns

Calories

Determines the number of calories in a finished beer based on the original gravity, final gravity and the volume of the beer consumed.

Arguments
Returns

Real Extract

Real Extract (RE) is a precise calculation concerning the gravity of beer. Source of equation is Craft Beer & Brewing

Arguments
Returns

Apparent Degree of Fermentation

Apparent Degree of Fermentation (ADF) is a measure of the amount of sugar that has been converted to alcohol and carbon dioxide by yeast during fermentation

Arguments
Returns

Gravity Correction

Gravity Correction based on Temperature of Sample and Hydrometer Calibration. Source Brewers Friend

Arguments
Returns

Spirit

This class will calculate Spirit related calculations.


Dilute Down To Desired Proof

Dilute Down To Desired Proof is a calculation to determine how much water to add to a spirit to get to a desired proof.

Arguments
Returns

Distilled Alcohol Volume

Distilled Alcohol Volume is a calculation to determine the volume of alcohol distilled depending on the wash abv and still efficiency.

Arguments
Returns

Distilled Remaining Water Volume

Distilled Remaining Water Volume is a calculation to determine the volume of water remaining after distilling a spirit.

Arguments
Returns

Water

This class will calculate Water related calculations.


Parts Per Million (PPM)

Parts Per Million (PPM) is a calculation to determine the amount of a substance in a solution.

Arguments
Returns

Boil Off Volume

Boil Off Volume determines the Volume boiled off based on Boil Rate and Time.

Arguments
Returns

Post Boil Volume

Post Boil Volume determines the Volume solution remaining after a Pre Boil Volume, Boil Rate and Time are given.

Arguments
Returns

All versions of unitz with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
doctrine/inflector Version ^2.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 brewerwall/unitz contains the following files

Loading the files please wait ....