[Rt-commit] r2269 - in experiments/Bamboo: . lib/Bamboo t
jesse at bestpractical.com
jesse at bestpractical.com
Sun Feb 27 23:58:29 EST 2005
Author: jesse
Date: Sun Feb 27 23:58:29 2005
New Revision: 2269
Modified:
experiments/Bamboo/ (props changed)
experiments/Bamboo/lib/Bamboo/Controller.pm
experiments/Bamboo/t/1basicparse.t
Log:
r6104 at hualien: jesse | 2005-02-27 23:55:22 -0500
docs, a bit
Modified: experiments/Bamboo/lib/Bamboo/Controller.pm
==============================================================================
--- experiments/Bamboo/lib/Bamboo/Controller.pm (original)
+++ experiments/Bamboo/lib/Bamboo/Controller.pm Sun Feb 27 23:58:29 2005
@@ -9,10 +9,28 @@
sub _Init {
my $self = shift;
- $self->{obj_cache} = Bamboo::Controller::ObjectCollection->new();
+ $self->{objects_to_act_on} = Bamboo::Controller::ObjectCollection->new();
return $self;
}
+=head2 parse_param_hash PARAMHASH
+
+parse_param_hash takes a hash of parameters, which Bamboo will turn into a set
+of method calls. They look like this:
+
+Object type - Object moniker - Method - Method Moniker - parameter
+PetStore::User-NewUser-Create-Nonce1-Name => 'Jesse'
+
+An Object type is a Bamboo facade type. It _must_ live under the Bamboo::Facade namespace.
+
+The object moniker is a unique name for a given object. The idea is that you'll be able to perform multiple method calls on one object by using the same nonce.
+
+
+TODO: ordering
+
+
+=cut
+
sub parse_param_hash {
my $self = shift;
my %params = (@_);
@@ -37,6 +55,8 @@
}
}
+
+ return($self);
}
@@ -45,19 +65,19 @@
#figure out which objects we have to look at
foreach my $object ($self->objects->as_array()){
foreach my $method ($object->methods->as_array()) {
- warn "Validating $method";
if ($object->validate_method_call($method)) {
- warn "Calling $method";
$object->call_method($method);
}
}
}
+
+ return($self);
}
sub objects {
my $self = shift;
- return ($self->{obj_cache});
+ return ($self->{objects_to_act_on});
}
1;
Modified: experiments/Bamboo/t/1basicparse.t
==============================================================================
--- experiments/Bamboo/t/1basicparse.t (original)
+++ experiments/Bamboo/t/1basicparse.t Sun Feb 27 23:58:29 2005
@@ -91,3 +91,5 @@
is( $method_set_status->params->get( $params[0] ), 'open' );
$controller->process_method_calls();
+
+
More information about the Rt-commit
mailing list