From d90aa43644152a61bd29622276ab4a2c587b63d4 Mon Sep 17 00:00:00 2001 From: sergiotarxz Date: Fri, 18 Mar 2022 07:27:55 +0100 Subject: [PATCH] Finishing the documentation of already created modules. --- doc/lib/Peace/Controller/User.pm.html | 33 +++++++++++- doc/lib/Peace/DAO/Application.pm.html | 4 +- doc/lib/Peace/DAO/Customer.pm.html | 74 ++++++++++++++++++++++++++- doc/lib/Peace/DAO/Developer.pm.html | 2 + lib/Peace/Controller/User.pm | 23 +++++++++ lib/Peace/DAO/Application.pm | 5 +- lib/Peace/DAO/Customer.pm | 60 ++++++++++++++++++++++ lib/Peace/DAO/Developer.pm | 8 ++- t/00009-pod-coverage.t | 2 +- 9 files changed, 204 insertions(+), 7 deletions(-) diff --git a/doc/lib/Peace/Controller/User.pm.html b/doc/lib/Peace/Controller/User.pm.html index 01956d4..1c8b944 100644 --- a/doc/lib/Peace/Controller/User.pm.html +++ b/doc/lib/Peace/Controller/User.pm.html @@ -2,7 +2,7 @@ - +<title>Peace::Controller::User - Controller for user specific actions. @@ -11,6 +11,37 @@ + + +

NAME

+ +

Peace::Controller::User - Controller for user specific actions.

+ +

FUNCTIONS

+ +

Peace::Controller::User implements the following functions.

+ +

post

+ +

For internal usage

+ +

BUGS

+ +

This file is no longer more than a template that's going to be deleted sooner or later when the http logic begins its development.

+ +

SEE ALSO

+ +

Mojolicious::Controller

+ diff --git a/doc/lib/Peace/DAO/Application.pm.html b/doc/lib/Peace/DAO/Application.pm.html index 577c6f0..b539f83 100644 --- a/doc/lib/Peace/DAO/Application.pm.html +++ b/doc/lib/Peace/DAO/Application.pm.html @@ -48,7 +48,7 @@ my $applications = $application_dao->recover_by_developer( developer => $d

DESCRIPTION

-

Peace::DAO::Developer allows you to make database operations over the applications table like recover or create.

+

Peace::DAO::Application allows you to make database operations over the applications table like recover or create.

INSTANCE METHODS

@@ -72,6 +72,8 @@ my $applications = $application_dao->recover_by_developer( developer => $d

Takes a Peace::Model::Application and creates its representation in database.

+

As a side effect sets the fields uuid and date_creation in the passed object.

+

recover_by_uuid

my $application = $application_dao->recover_by_uuid(
diff --git a/doc/lib/Peace/DAO/Customer.pm.html b/doc/lib/Peace/DAO/Customer.pm.html
index 01956d4..65a9f77 100644
--- a/doc/lib/Peace/DAO/Customer.pm.html
+++ b/doc/lib/Peace/DAO/Customer.pm.html
@@ -2,7 +2,7 @@
 
 
 
-
+<title>Peace::DAO::Customer - The database access object of customer.
 
 
 
@@ -11,6 +11,78 @@
 
 
 
+
+
+

NAME

+ +

Peace::DAO::Customer - The database access object of customer.

+ +

SYNOPSIS

+ +
my $customer_dao = Peace::DAO::Customer->new(
+  dbh => $dbh,
+);
+
+$customer_dao->create( customer => $customer );
+
+my $customer = $customer_dao->recover_by_uuid(
+  uuid => $uuid,
+);
+ +

DESCRIPTION

+ +

Peace::DAO::Customer allows you to make database operations over the customers table like recover or create.

+ +

INSTANCE METHODS

+ +

Peace::DAO::Customer implements the following instance methods:

+ +

new

+ +
my $customer_dao = Peace::DAO::Customer->new(
+   dbh => $dbh,
+);
+ +

Takes a database handle and instances a Peace::DAO::Customer object.

+ +

METHODS

+ +

create

+ +
$customer_dao->create(
+  customer => $customer,
+);
+ +

Takes a Peace::Model::Customer object and creates its database representation.

+ +

As a side effect sets the fields uuid and date_creation in the passed object.

+ +

recover_by_uuid

+ +
my $customer = $customer_dao->recover_by_uuid(
+  uuid => $uuid,
+);
+ +

SEE ALSO

+ +

Peace::DB, DBI, Peace::Model::Customer

+ diff --git a/doc/lib/Peace/DAO/Developer.pm.html b/doc/lib/Peace/DAO/Developer.pm.html index c90c2fb..4053995 100644 --- a/doc/lib/Peace/DAO/Developer.pm.html +++ b/doc/lib/Peace/DAO/Developer.pm.html @@ -65,6 +65,8 @@ my $developer = $developer_dao->recover_by_uuid( uuid => $uuid );
Creates a representation in database of the passed developer object.

+

As a side effect sets the fields uuid and date_creation in the passed object.

+

recover_by_uuid

my $developer = $developer_dao->recover_by_uuid( uuid => $uuid );
diff --git a/lib/Peace/Controller/User.pm b/lib/Peace/Controller/User.pm index 0603810..098cc4f 100644 --- a/lib/Peace/Controller/User.pm +++ b/lib/Peace/Controller/User.pm @@ -8,3 +8,26 @@ sub post { $self->render( json => $user_data ); } 1; +=encoding utf8 + +=head1 NAME + +Peace::Controller::User - Controller for user specific actions. + +=head1 FUNCTIONS + +Peace::Controller::User implements the following functions. + +=head2 post + +For internal usage + +=head1 BUGS + +This file is no longer more than a template that's going +to be deleted sooner or later when the http logic begins +its development. + +=head1 SEE ALSO + +L diff --git a/lib/Peace/DAO/Application.pm b/lib/Peace/DAO/Application.pm index 2e15a97..96898b0 100644 --- a/lib/Peace/DAO/Application.pm +++ b/lib/Peace/DAO/Application.pm @@ -168,7 +168,7 @@ Peace::DAO::Application - The database access object of applications. =head1 DESCRIPTION -Peace::DAO::Developer allows you to make database +Peace::DAO::Application allows you to make database operations over the applications table like recover or create. @@ -195,6 +195,9 @@ Peace::DAO::Application implements the following methods: Takes a L and creates its representation in database. +As a side effect sets the fields uuid and date_creation +in the passed object. + =head2 recover_by_uuid my $application = $application_dao->recover_by_uuid( diff --git a/lib/Peace/DAO/Customer.pm b/lib/Peace/DAO/Customer.pm index d867b8b..7144536 100644 --- a/lib/Peace/DAO/Customer.pm +++ b/lib/Peace/DAO/Customer.pm @@ -88,3 +88,63 @@ sub _dbh { return $self->{dbh}; } 1; +=encoding utf8 + +=head1 NAME + +Peace::DAO::Customer - The database access object of customer. + +=head1 SYNOPSIS + + my $customer_dao = Peace::DAO::Customer->new( + dbh => $dbh, + ); + + $customer_dao->create( customer => $customer ); + + my $customer = $customer_dao->recover_by_uuid( + uuid => $uuid, + ); + +=head1 DESCRIPTION + +Peace::DAO::Customer allows you to make database +operations over the customers table like recover +or create. + +=head1 INSTANCE METHODS + +Peace::DAO::Customer implements the following instance +methods: + +=head2 new + + my $customer_dao = Peace::DAO::Customer->new( + dbh => $dbh, + ); + +Takes a database handle and instances a Peace::DAO::Customer object. + +=head1 METHODS + +=head2 create + + $customer_dao->create( + customer => $customer, + ); + +Takes a L object and creates its +database representation. + +As a side effect sets the fields uuid and date_creation +in the passed object. + +=head2 recover_by_uuid + + my $customer = $customer_dao->recover_by_uuid( + uuid => $uuid, + ); + +=head1 SEE ALSO + +L, L, L diff --git a/lib/Peace/DAO/Developer.pm b/lib/Peace/DAO/Developer.pm index e9b1efb..3849f69 100644 --- a/lib/Peace/DAO/Developer.pm +++ b/lib/Peace/DAO/Developer.pm @@ -111,8 +111,9 @@ Peace::DAO::Developer - The database access object of developers. =head1 DESCRIPTION -Peace::DAO::Developer allows you to make database operations over the -developers table like recover or create. +Peace::DAO::Developer allows you to make database +operations over the developers table like recover +or create. =head1 INSTANCE METHODS @@ -134,6 +135,9 @@ Peace::DAO::Developer implements the following methods: Creates a representation in database of the passed developer object. +As a side effect sets the fields uuid and date_creation +in the passed object. + =head2 recover_by_uuid my $developer = $developer_dao->recover_by_uuid( uuid => $uuid ); diff --git a/t/00009-pod-coverage.t b/t/00009-pod-coverage.t index 1803fa6..70452a0 100644 --- a/t/00009-pod-coverage.t +++ b/t/00009-pod-coverage.t @@ -5,7 +5,7 @@ use v5.30.0; use strict; use warnings; -use Test::Most tests => 1; +use Test::Most tests => 9; use Test::Pod::Coverage; {