goriffle

package module
v0.0.0-...-e113d62 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 4, 2015 License: MIT Imports: 15 Imported by: 0

README

Riffle library for golang.

Documentation

Overview

package goriffle implements the WAMPv2 protocol.

See the official WAMP documentation at http://wamp.ws for more details on the protocol.

Index

Constants

View Source
const (

	// Connection provided an incorrect URI for any URI-based attribute of WAMP message,
	// such as realm, topic or procedure.
	ErrInvalidUri = "wamp.error.invalid_uri"

	// A Dealer could not perform a call, since no procedure is currently
	// registered under the given URI.
	ErrNoSuchDomain = "wamp.error.no_such_procedure"

	// A procedure could not be registered, since a procedure with the given URI
	// is already registered.
	ErrDomainAlreadyExists = "wamp.error.procedure_already_exists"

	// A Dealer could not perform an unregister, since the given registration is
	// not active.
	ErrNoSuchRegistration = "wamp.error.no_such_registration"

	// A Broker could not perform an unsubscribe, since the given subscription is
	// not active.
	ErrNoSuchSubscription = "wamp.error.no_such_subscription"

	// A call failed, since the given argument types or values are not acceptable
	// to the called procedure - in which case the Callee may throw this error. Or
	// a Node performing payload validation checked the payload (args / kwargs)
	// of a call, call result, call error or publish, and the payload did not
	// conform - in which case the Node may throw this error.
	ErrInvalidArgument = "wamp.error.invalid_argument"

	// The Connection is shutting down completely - used as a GOODBYE (or aBORT) reason.
	ErrSystemShutdown = "wamp.error.system_shutdown"

	// The Connection wants to leave the realm - used as a GOODBYE reason.
	ErrCloseRealm = "wamp.error.close_realm"

	// A Connection acknowledges ending of a session - used as a GOOBYE reply reason.
	ErrGoodbyeAndOut = "wamp.error.goodbye_and_out"

	// A join, call, register, publish or subscribe failed, since the Connection is not
	// authorized to perform the operation.
	ErrNotAuthorized = "wamp.error.not_authorized"

	// A Dealer or Broker could not determine if the Connection is authorized to perform
	// a join, call, register, publish or subscribe, since the authorization
	// operation itself failed. E.g. a custom authorizer ran into an error.
	ErrAuthorizationFailed = "wamp.error.authorization_failed"

	// Connection wanted to join a non-existing realm (and the Node did not allow to
	// auto-create the realm)
	ErrNoSuchRealm = "wamp.error.no_such_realm"

	// A Connection was to be authenticated under a Role that does not (or no longer)
	// exists on the Node. For example, the Connection was successfully authenticated,
	// but the Role configured does not exists - hence there is some
	// misconfiguration in the Node.
	ErrNoSuchRole = "wamp.error.no_such_role"
)
View Source
const ACTION_SEPARATOR string = "/"
View Source
const DOMAIN_SEPARATOR string = "."

Variables

This section is empty.

Functions

func GoJs

func GoJs(url string, domain string)

func PConnector

func PConnector(url string, domain string) string

Create a global session

func PRecieve

func PRecieve() []byte

Cant return an int safely!

func PRegister

func PRegister(s string) []byte

func PSubscribe

func PSubscribe(s string) []byte

Might not have to use PSubscribe at all, actually. Make the regular methods return their ids and toggle on the custom receiver loop

func PYield

func PYield(args []byte)

func Start

func Start(url string, domain string) (*session, error)

Connect to the node with the given URL

Types

type AuthenticationError

type AuthenticationError string

func (AuthenticationError) Error

func (e AuthenticationError) Error() string

type BinaryData

type BinaryData []byte

Marshals and unmarshals byte arrays according to WAMP specifications: https://github.com/tavendo/WAMP/blob/master/spec/basic.md#binary-conversion-of-json-strings

This type *should* be used in types that will be marshalled as jSON.

type InvalidURIError

type InvalidURIError string

func (InvalidURIError) Error

func (e InvalidURIError) Error() string

type NoDestinationError

type NoDestinationError string

func (NoDestinationError) Error

func (e NoDestinationError) Error() string

type NoSuchRealmError

type NoSuchRealmError string

func (NoSuchRealmError) Error

func (e NoSuchRealmError) Error() string

type RealmExistsError

type RealmExistsError string

func (RealmExistsError) Error

func (e RealmExistsError) Error() string

type Serialization

type Serialization int

Directories

Path Synopsis
package name: reef package name: reef
package name: reef package name: reef

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL