-
-
04 Mar 2018 23:07:45 UTC
- Distribution: Treex-PML
- Module version: 2.24
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Issues (0)
- Testers (2180 / 2 / 0)
- Kwalitee
Bus factor: 2- 45.42% Coverage
- License: unknown
- Activity
24 month- Tools
- Download (259.74KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- File::ShareDir
- File::Which
- IO::Zlib
- LWP::UserAgent
- Test::More
- UNIVERSAL::DOES
- URI
- XML::CompactTree
- XML::LibXML
- XML::SAX
- XML::Writer
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
Treex::PML::Container - content and attributes
DESCRIPTION
This class implements the data type 'container'. A container consists of a central value called content annotated by a set of name-value pairs called attributes whose values are atomic. Treex::PML represents the container class as a subclass of Treex::PML::Struct, where attributes are represented as members and the content as a member with a reserved name '#content'.
METHODS
- Treex::PML::Container->new (value?, { name=>attr, ...}?,reuse?)
-
Create a new container (optionally initializing its value and attributes). If reuse is true, the hash reference passed may be reused (re-blessed) into the structure.
NOTE: Don't call this constructor directly, use Treex::PML::Factory->createContainer() instead!
- $container->attributes ()
-
Return (assorted) list of names of all attributes.
- $container->value
-
Return the content value of the container.
- $container->content
-
This is an alias for value().
- $container->get_attribute($name)
-
Get value of a given attribute. This is just an alias for the inherited
Treex::PML::Struct::get_member()
. - $container->set_attribute($name, $value)
-
Set value of a given attribute. This is just an alias for the inherited
Treex::PML::Struct::set_member()
.
SEE ALSO
Treex::PML, Treex::PML::Factory, Treex::PML::Schema, Treex::PML::Struct
COPYRIGHT AND LICENSE
Copyright (C) 2006-2010 by Petr Pajas
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.2 or, at your option, any later version of Perl 5 you may have available.
Module Install Instructions
To install Treex::PML, copy and paste the appropriate command in to your terminal.
cpanm Treex::PML
perl -MCPAN -e shell install Treex::PML
For more information on module installation, please visit the detailed CPAN module installation guide.