| 1 | package DBGp::Client::Response::ContextNames; | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | use parent qw(DBGp::Client::Response::Simple); | ||
| 6 | |||
| 7 | __PACKAGE__->make_attrib_accessors(qw( | ||
| 8 | transaction_id command | ||
| 9 | )); | ||
| 10 | |||
| 11 | sub contexts { | ||
| 12 | return [map +(bless $_, 'DBGp::Client::Response::ContextName'), | ||
| 13 | DBGp::Client::Parser::_nodes($_[0], 'context')]; | ||
| 14 | } | ||
| 15 | |||
| 16 | package DBGp::Client::Response::ContextName; | ||
| 17 | |||
| 18 | use parent qw(DBGp::Client::Response::Simple); | ||
| 19 | |||
| 20 | __PACKAGE__->make_attrib_accessors(qw( | ||
| 21 | name id | ||
| 22 | )); | ||
| 23 | |||
| 24 | 1; |