]> git.vpit.fr Git - perl/modules/LaTeX-TikZ.git/blobdiff - lib/LaTeX/TikZ/Scope.pm
First cut at the documentation
[perl/modules/LaTeX-TikZ.git] / lib / LaTeX / TikZ / Scope.pm
index 3686beb28b5e7f73d4b5302524f41b8d317b7fb8..e973adc20d6baa6af64b81c16fe6cc0b2b45b9f4 100644 (file)
@@ -21,6 +21,12 @@ use LaTeX::TikZ::Tools;
 
 use Any::Moose;
 
+=head1 ATTRIBUTES
+
+=head2 C<mods>
+
+=cut
+
 has '_mods' => (
  is       => 'ro',
  isa      => 'Maybe[ArrayRef[LaTeX::TikZ::Mod::Formatted]]',
@@ -37,6 +43,10 @@ has '_mods_cache' => (
  default  => sub { +{ } },
 );
 
+=head2 C<body>
+
+=cut
+
 has '_body' => (
  is       => 'rw',
  isa      => 'LaTeX::TikZ::Scope|ArrayRef[Str]',
@@ -48,6 +58,12 @@ my $ltmf_tc  = LaTeX::TikZ::Tools::type_constraint('LaTeX::TikZ::Mod::Formatted'
 my $_body_tc = __PACKAGE__->meta->find_attribute_by_name('_body')
                                 ->type_constraint;
 
+=head1 METHODS
+
+=head2 C<mod>
+
+=cut
+
 sub mod {
  my $scope = shift;
 
@@ -65,6 +81,10 @@ sub mod {
  $scope;
 }
 
+=head2 C<body>
+
+=cut
+
 sub body {
  my $scope = shift;
 
@@ -80,6 +100,10 @@ use overload (
  '@{}' => 'dereference',
 );
 
+=head2 C<flatten>
+
+=cut
+
 sub flatten {
  my ($scope) = @_;
 
@@ -114,6 +138,10 @@ my $inter = Sub::Name::subname('inter' => sub {
  return \@left, \@common, \@right;
 });
 
+=head2 C<instantiate>
+
+=cut
+
 sub instantiate {
  my ($scope) = @_;
 
@@ -164,8 +192,16 @@ sub instantiate {
  return @body;
 }
 
+=head2 C<dereference>
+
+=cut
+
 sub dereference { [ $_[0]->instantiate ] }
 
+=head2 C<fold>
+
+=cut
+
 sub fold {
  my ($left, $right, $rev) = @_;