UDDI::Lite(3)
β¨ UDDI::Lite β¨
okay bestie, welcome to UDDI::Lite β the Library for UDDI clients in Perl. she's a Perl module collection that gives you a simple, lightweight lil interface to a Universal Description, Discovery and Integration (UDDI) server. we're doing this together, no stress π
πΈ SYNOPSIS πΈ
the classic, no-frills way:
use UDDI::Lite;
print UDDI::Lite
-> proxy('http://uddi.microsoft.com/inquire')
-> find_business(name => 'old')
-> result
-> businessInfos->businessInfo->serviceInfos->serviceInfo->name;
same exact code but with autodispatch, she's doing the most:
use UDDI::Lite +autodispatch =>
proxy => 'http://uddi.microsoft.com/inquire'
;
print find_business(name => 'old')
-> businessInfos->businessInfo->serviceInfos->serviceInfo->name;
or if you're an importing kinda girl:
use UDDI::Lite
'UDDI::Lite' => [':inquiry'],
proxy => 'http://uddi.microsoft.com/inquire'
;
print find_business(name => 'old')
-> businessInfos->businessInfo->serviceInfos->serviceInfo->name;
and now the Publishing API era π₯:
use UDDI::Lite
import => ['UDDI::Data'],
import => ['UDDI::Lite'],
proxy => "https://some.server.com/endpoint_fot_publishing_API";
my $auth = get_authToken({userID => 'USERID', cred => 'CRED'})->authInfo;
my $busent = with businessEntity =>
name("Contoso Manufacturing"),
description("We make components for business"),
businessKey(''),
businessServices with businessService =>
name("Buy components"),
description("Bindings for buying our components"),
serviceKey(''),
bindingTemplates with bindingTemplate =>
description("BASDA invoices over HTTP post"),
accessPoint('http://www.contoso.com/buy.asp'),
bindingKey(''),
tModelInstanceDetails with tModelInstanceInfo =>
description('some tModel'),
tModelKey('UUID:C1ACF26D-9672-4404-9D70-39B756E62AB4')
;
print save_business($auth, $busent)->businessEntity->businessKey;
(and yes, endpoint_fot_publishing_API is literally spelled like that in the original, iykyk π)
π¦ DESCRIPTION π¦
UDDI::Lite for Perl is a collection of Perl modules that serves up a simple and lightweight interface to the Universal Description, Discovery and Integration (UDDI) server. it's giving minimal effort, maximum slay.
want to learn more about UDDI? go visit http://www.uddi.org/ π
the main features of the library, ranked:
- Supports both inquiry and publishing API
- Builded on top of
SOAP::Litemodule, hence inherited syntax and features - Supports easy-to-use interface with convenient access to (sub)elements and attributes
- Supports
HTTPSprotocol - Supports
SMTPprotocol - Supports Basic/Digest server authentication
note: "Builded" is what the original says, I'm not fixing it, she said what she said π«Ά
π OVERVIEW OF CLASSES AND PACKAGES π
this lil table gives you the quick rundown of the classes this library hands you:
UDDI::Lite.pm
-- UDDI::Lite -- Main class provides all logic
-- UDDI::Data -- Provides extensions for serialization architecture
-- UDDI::Serializer -- Serializes data structures to UDDI/SOAP package
-- UDDI::Deserializer -- Deserializes result into objects
-- UDDI::SOM -- Provides access to deserialized object tree
π UDDI::Lite
every method UDDI::Lite hands you works both ways β for setting and for retrieving. no parameters? you get the current value. parameters? the new value gets assigned and the method returns the object (unless something else is stated, bestie, don't @ me). perfect for stacking calls like this:
$uddi = UDDI::Lite
-> on_debug(sub{print@_})
-> proxy('http://uddi.microsoft.com/inquire')
;
order is insignificant, so you can call new() first if you want. and if you don't? UDDI::Lite will do it for you, she's got you. but new() unlocks extra syntax for you:
$uddi = new UDDI::Lite
on_debug => sub {print@_},
proxy => 'http://uddi.microsoft.com/inquire'
;
new() accepts a hash with method names and values, then calls the appropriate method with the passed value. iconic behaviour honestly.
since new() is optional, we're not gonna mention it again. moving on π
other available methods inherited from SOAP::Lite and most usable are:
proxy()β shortcut fortransport->proxy(). this lets you specify an endpoint and loads the required module at the same time. it's required for dispatching SOAP calls. the name of the module gets defined depending on the protocol specific for the endpoint.SOAP::Litewill do the rest work, she's the main character here.on_fault()β lets you specify a handler for the on_fault event. default behaviour is die on transport error and does nothing on others. you can change this behaviour globally or locally, for a particular object.on_debug()β lets you specify a handler for the on_debug event. default behaviour is do nothing. use the+trace/+debugoption forUDDI::Liteinstead.
want to change to UDDI Version 2? use this pragma:
use UDDI::Lite uddiversion => 2;
π UDDI::Data
use this class when you want to specify both the value and the name for UDDI elements. for example, "UDDI::Data->name('businessInfo')->value(123)" will be serialized to "<businessInfo>123</businessInfo>", and so will "UDDI::Data-"name(businessInfo => 123)>".
if you want to provide names for your parameters you can either specify:
find_business(name => 'old')
or do it with UDDI::Data:
find_business(UDDI::Data->name(name => 'old'))
the latter has some advantages: it'll work on any level, so you can do:
find_business(UDDI::Data->name(name => UDDI::Data->name(subname => 'old')))
and you can also create arrays with this syntax:
find_business(UDDI::Data->name(name =>
[UDDI::Data->name(subname1 => 'name1'),
UDDI::Data->name(subname2 => 'name2')]))
which will be serialized into:
<find_business xmlns="urn:uddi-org:api" generic="1.0">
<name>
<subname1>name1</subname1>
<subname2>name2</subname2>
</name>
</find_business>
for standard elements there's a more convenient syntax available:
find_business(
findQualifiers(findQualifier('sortByNameAsc',
'caseSensitiveMatch')),
name('M')
)
and:
find_business(
findQualifiers([findQualifier('sortByNameAsc'),
findQualifier('caseSensitiveMatch')]),
name('M')
)
both will generate:
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<find_business xmlns="urn:uddi-org:api" generic="1.0">
<findQualifiers>
<findQualifier>sortByNameAsc</findQualifier>
<findQualifier>caseSensitiveMatch</findQualifier>
</findQualifiers>
<name>M</name>
</find_business>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
you can use ANY valid combinations (according to the "UDDI Programmer's API Specification"). but if you try to generate something unusual, like "name(name('myname'))", you'll get this:
Don't know what to do with 'name' and 'name' elements ....
and if you REALLY need to do it, use the "UDDI::Data" syntax described above. no cap.
as a special case you can pass a hash as the first parameter of a method call, and the values of that hash get added as attributes to the top element:
find_business({maxRows => 10}, UDDI::Data->name(name => old))
gives you:
<find_business xmlns="urn:uddi-org:api" generic="1.0" maxRows="10">
....
</find_business>
you can also pass back parameters exactly as you get them from a method call (like you probably want to do with authInfo).
you can get access to attributes and elements through the same interface:
my $list = find_business(name => old);
my $bis = $list->businessInfos;
for ($bis->businessInfo) {
my $s = $_->serviceInfos->serviceInfo;
print $s->name, # element
$s->businessKey, # attribute
"\n";
}
to match the advantages provided by the "with" operator available in other languages (like VB), we provide similar functionality that adds you flexibility:
with findQualifiers =>
findQualifier => 'sortByNameAsc',
findQualifier => 'caseSensitiveMatch'
is the same as:
with(findQualifiers =>
findQualifier('sortByNameAsc'),
findQualifier('caseSensitiveMatch'),
)
and:
findQualifiers->with(
findQualifier('sortByNameAsc'),
findQualifier('caseSensitiveMatch'),
)
will all generate the same code as mentioned above:
findQualifiers(findQualifier('sortByNameAsc',
'caseSensitiveMatch')),
the advantage of the "with" syntax is that you can specify both attributes and elements through the same interface. the first argument is the element where all other elements and attributes will be attached. provided examples and tests cover different syntaxes, she's thorough π
π AUTODISPATCHING
UDDI::Lite provides an autodispatching feature that lets you create code that looks similar for local and remote access.
for example:
use UDDI::Lite +autodispatch =>
proxy => 'http://uddi.microsoft.com/inquire';
tells autodispatch all UDDI calls to go to 'http://uddi.microsoft.com/inquire'. all subsequent calls can look like:
find_business(name => 'old');
find_business(UDDI::Data->name(name => 'old'));
find_business(name('old'));
π BUGS AND LIMITATIONS π
- Interface is still subject to change. (she's a work in progress, be gentle π)
- Though
HTTPS/SSLis supported you should specify it yourself (with"proxy"or"endpoint") for publishing API calls.
π AVAILABILITY π
for now UDDI::Lite is distributed as part of the SOAP::Lite package. you can download it from ( http://soaplite.com/ ) or from CPAN ( http://search.cpan.org/search?dist=SOAP-Lite ).
β SEE ALSO β
SOAP::Lite ( http://search.cpan.org/search?dist=SOAP-Lite ) UDDI ( http://search.cpan.org/search?dist=UDDI )
π«Ά COPYRIGHT π«Ά
Copyright (C) 2000-2004 Paul Kulchenko. All rights reserved.
this library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
πΈ AUTHOR πΈ
Paul Kulchenko (paulclinger@yahoo.com)
and that's the whole page bestie, no notes β¨ this was UDDI::Lite(3) from the User Contributed Perl Documentation, version perl v5.42.0, dated 2025-07-25. mwah π π π¦
π¦ where this page comes from
- fedora 43: perl-UDDI-Lite 0.718-33.fc43 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms