Download the PHP package inodrahq/bcs without Composer

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

PHP BCS

A PHP implementation of Binary Canonical Serialization (BCS) — the serialization format used by Sui, Aptos, and other Move-based blockchains.

Requirements

Installation

Quick Start

Supported Types

BCS Type PHP Class Description
bool Boolean True/false
u8 U8 Unsigned 8-bit integer
u16 U16 Unsigned 16-bit little-endian
u32 U32 Unsigned 32-bit little-endian
u64 U64 Unsigned 64-bit little-endian
u128 U128 Unsigned 128-bit little-endian
u256 U256 Unsigned 256-bit little-endian
i8 I8 Signed 8-bit integer
i16 I16 Signed 16-bit little-endian
i32 I32 Signed 32-bit little-endian
i64 I64 Signed 64-bit little-endian
i128 I128 Signed 128-bit little-endian
bytes Bytes Fixed-length byte array
string BcsString ULEB128-prefixed UTF-8 string
vector<T> Vector ULEB128-prefixed sequence
option<T> Option 0x00 (None) or 0x01 + value (Some)
map<K,V> Map Sorted key-value pairs
struct Struct Ordered named fields
enum Enum ULEB128 variant index + data
tuple Tuple Ordered unnamed fields
fixed_array FixedArray Fixed-length array (no length prefix)
byte_vector ByteVector ULEB128-prefixed raw bytes

Advanced Usage

Structs

Enums

Options

Maps

Tuples

Fixed Arrays

Decoding

All container types require type context for decoding:

Custom Types

Implement the BcsType interface:

Hex Helpers

All encoded types support hex output via the Encoder:

Testing

228 tests verified against golden vectors generated by the Rust bcs crate.

License

MIT


All versions of bcs with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
ext-bcmath Version *
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 inodrahq/bcs contains the following files

Loading the files please wait ...