The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Zing::Term - Resource Representation

ABSTRACT

Resource Representation

SYNOPSIS

  use Zing::KeyVal;
  use Zing::Term;

  my $term = Zing::Term->new(Zing::KeyVal->new(name => 'nodes'));

  # $term->keyval;

DESCRIPTION

This package provides a mechanism for generating and validating (global and local) resource identifiers.

LIBRARIES

This package uses type constraints from:

Zing::Types

ATTRIBUTES

This package has the following attributes:

bucket

  bucket(Str)

This attribute is read-only, accepts (Str) values, and is required.

facets

  facets(ArrayRef[Str])

This attribute is read-only, accepts (ArrayRef[Str]) values, and is optional.

handle

  handle(Str)

This attribute is read-only, accepts (Str) values, and is required.

symbol

  symbol(Str)

This attribute is read-only, accepts (Str) values, and is required.

system

  system(Str)

This attribute is read-only, accepts (Str) values, and is required.

target

  target(Str)

This attribute is read-only, accepts (Str) values, and is required.

METHODS

This package implements the following methods:

channel

  channel() : Str

The channel method validates and returns a "channel" resource identifier.

channel example #1
  use Zing::Channel;

  Zing::Term->new(Zing::Channel->new(name => 'chat'));

  # $term->channel;

data

  data() : Str

The data method validates and returns a "data" resource identifier.

data example #1
  use Zing::Data;
  use Zing::Process;

  Zing::Term->new(Zing::Data->new(process => Zing::Process->new));

  # $term->data;

domain

  domain() : Str

The domain method validates and returns a "domain" resource identifier.

domain example #1
  use Zing::Domain;

  Zing::Term->new(Zing::Domain->new(name => 'transaction'));

  # $term->domain;

kernel

  kernel() : Str

The kernel method validates and returns a "kernel" resource identifier.

kernel example #1
  use Zing::Kernel;

  Zing::Term->new(Zing::Kernel->new(scheme => ['MyApp', [], 1]));

  # $term->kernel;

keyval

  keyval() : Str

The keyval method validates and returns a "keyval" resource identifier.

keyval example #1
  use Zing::KeyVal;

  Zing::Term->new(Zing::KeyVal->new(name => 'listeners'));

  # $term->keyval;

mailbox

  mailbox() : Str

The mailbox method validates and returns a "mailbox" resource identifier.

mailbox example #1
  use Zing::Mailbox;
  use Zing::Process;

  Zing::Term->new(Zing::Mailbox->new(process => Zing::Process->new));

  # $term->mailbox;

process

  process() : Str

The process method validates and returns a "process" resource identifier.

process example #1
  use Zing::Process;

  Zing::Term->new(Zing::Process->new);

  # $term->process;

pubsub

  pubsub() : Str

The pubsub method validates and returns a "pubsub" resource identifier.

pubsub example #1
  use Zing::PubSub;

  Zing::Term->new(Zing::PubSub->new(name => 'operations'));

  # $term->pubsub;

queue

  queue() : Str

The queue method validates and returns a "queue" resource identifier.

queue example #1
  use Zing::Queue;

  Zing::Term->new(Zing::Queue->new(name => 'workflows'));

  # $term->queue;

registry

  registry() : Str

The registry method validates and returns a "registry" resource identifier.

registry example #1
  use Zing::Registry;

  Zing::Term->new(Zing::Registry->new(name => 'campaigns'));

  # $term->registry;

repo

  repo() : Str

The repo method validates and returns a "repo" resource identifier.

repo example #1
  use Zing::Repo;

  Zing::Term->new(Zing::Repo->new(name => 'miscellaneous'));

  # $term->repo;

string

  string() : Str

The string method returns a resource identifier. This method is called automatically when the object is used as a string.

string example #1
  # given: synopsis

  $term->string;

AUTHOR

Al Newkirk, awncorp@cpan.org

LICENSE

Copyright (C) 2011-2019, Al Newkirk, et al.

This is free software; you can redistribute it and/or modify it under the terms of the The Apache License, Version 2.0, as elucidated in the "license file".

PROJECT

Wiki

Project

Initiatives

Milestones

Contributing

Issues