leo_ordning_reda_api

The ordning-reda’s API.

References

Description

The ordning-reda’s API

Function Index

add_container/2 Add the container into the App.
has_container/1 Check whether the container exists.
pack/1 Pack the object.
remove_container/1 Remove the container from the App.
stack/3 Stack the object into the container.
start/0 Launch the application.
stop/0 Stop the application.
unpack/2 Unpack the object.

Function Details

add_container/2

add_container(Unit, Options) -> ok | {error, any()}

  • Unit = atom()
  • Options = [any()]

Add the container into the App

has_container/1

has_container(Unit) -> true | false

  • Unit = atom()

Check whether the container exists

pack/1

pack(Object) -> {ok, Bin} | {error, term()}

  • Object = any()
  • Bin = binary()

Pack the object

remove_container/1

remove_container(Unit) -> ok | {error, any()}

  • Unit = atom()

Remove the container from the App

stack/3

stack(Unit, StrawId, Object) -> ok | {error, any()}

  • Unit = atom()
  • StrawId = any()
  • Object = binary()

Stack the object into the container

start/0

start() -> ok | {error, any()}

Launch the application

stop/0

stop() -> ok | {error, any()}

Stop the application

unpack/2

unpack(CompressedBin, Fun) -> ok

  • CompressedBin = binary()
  • Fun = function()

Unpack the object