NAME

Data::Identifier::Interface::Simple - format independent identifier object

VERSION

version v0.36

SYNOPSIS

use parent 'Data::Identifier::Interface::Simple';

(since v0.16, experimental)

This interface is for packages implementing some kind of identifier and/or objects having an identifier.

Note: This is formally an experimental interface. However, it become semi-stable (as of v0.36). It may be changed, but is most unlikely to be renamed or removed.

See also "FURTHER DIRECTIONS" for details.

METHODS

as

my $res = $obj->as($as, %opts);

This method implements the same interface and features as "as" in Data::Identifier.

The default implementation is a proxy for "as" in Data::Identifier.

displayname

my $displayname = $obj->displayname( [ %opts ] );

This method returns a string suitable to display to the user.

The interface and options are the same as "displayname" in Data::Identifier.

The default implementation is equivalent to:

return $obj->as('Data::Identifier')->displayname(%opts);

ise

my $ise = $onj->ise( [ %opts ] );

Returns the ISE (UUID, OID, or URI) for the current object or die if no ISE is known nor can be calculated.

The interface and options are the same as for "ise" in Data::Identifier.

The default implementation is equivalent to:

return $obj->as('Data::Identifier')->ise(%opts);

FURTHER DIRECTIONS

FUTURE METHODS

To be future-safe this interface reserves the following methods: displaycolour (since v0.36), icontext (since v0.36).

Those methods may be used in the same or similar way as the corresponding methods in Data::Identifier.

Future versions of this module may provide default implementations.

UNIVERSAL OPTIONS

Currently methods are defined by their counterparts in Data::Identifier. Future versions might clarify on this.

Currently the options default, and no_defaults are considered universal options. They are most unlikely to be changed, or removed.

In respect to future work the following other options are currently reserved: as (since v0.36), autocreate (since v0.36), context (since v0.36), language (since v0.36), language_tags (since v0.36), listas (since v0.36), list (since v0.36), online (since v0.36), rawtype (since v0.36), so (since v0.36), style (since v0.36).

AUTHOR

Philipp Schafft <lion@cpan.org>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2023-2026 by Philipp Schafft <lion@cpan.org>.

This is free software, licensed under:

The Artistic License 2.0 (GPL Compatible)