#!/usr/bin/perl -w package iXML::TheConstuct; $VERSION = 0.01; use strict; sub new { my $proto = shift; my $class = ref($proto) || $proto; my $self = []; bless($self, $class); return $class; } sub add { my ($_self, $_obj_html, $_ind) = @_; my $_obj_hash = { OBJ_HTML => $_obj_html, OBJ_IND => $_ind}; push @{$_self}, $_obj_hash; # sort array according to hash OBJ_IND :) } sub output { my ($_self) = @_; my $_html_data; foreach my $_obj ( @{$_self} ) { $_html_data .= $_obj->{'OBJ_HTML'}; }; return $_html_data; } 1;