Coverage Report - org.jtheque.films.services.able.IRealizersService
 
Classes in this File Line Coverage Branch Coverage Complexity
IRealizersService
N/A
N/A
1
 
 1  
 package org.jtheque.films.services.able;
 2  
 
 3  
 /*
 4  
  * This file is part of JTheque.
 5  
  *
 6  
  * JTheque is free software: you can redistribute it and/or modify
 7  
  * it under the terms of the GNU General Public License as published by
 8  
  * the Free Software Foundation, either version 3 of the License.
 9  
  *
 10  
  * JTheque is distributed in the hope that it will be useful,
 11  
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
 12  
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 13  
  * GNU General Public License for more details.
 14  
  *
 15  
  * You should have received a copy of the GNU General Public License
 16  
  * along with JTheque.  If not, see <http://www.gnu.org/licenses/>.
 17  
  */
 18  
 
 19  
 import org.jtheque.core.managers.persistence.able.DataContainer;
 20  
 import org.jtheque.primary.od.able.Person;
 21  
 
 22  
 import java.util.Collection;
 23  
 
 24  
 /**
 25  
  * A service for the realizers functions.
 26  
  *
 27  
  * @author Baptiste Wicht
 28  
  */
 29  
 public interface IRealizersService extends DataContainer<Person> {
 30  
     String DATA_TYPE = "Realizers";
 31  
     String PERSON_TYPE = "Realizer";
 32  
 
 33  
     /**
 34  
      * Return an empty realizer.
 35  
      *
 36  
      * @return An empty realizer.
 37  
      */
 38  
     Person getEmptyRealizer();
 39  
 
 40  
     /**
 41  
      * Return the default realizer.
 42  
      *
 43  
      * @return The default realizer.
 44  
      */
 45  
     Person getDefaultRealizer();
 46  
 
 47  
     /**
 48  
      * Return all the realizers.
 49  
      *
 50  
      * @return All the realizers.
 51  
      */
 52  
     Collection<Person> getRealizers();
 53  
 
 54  
     /**
 55  
      * Delete the realizer.
 56  
      *
 57  
      * @param realizer The realizer to delete.
 58  
      * @return true if the realizer has been deleted else false.
 59  
      */
 60  
     boolean delete(Person realizer);
 61  
 
 62  
     /**
 63  
      * Indicate if a realizer exists with the first name and name.
 64  
      *
 65  
      * @param firstName The first name.
 66  
      * @param name      The name.
 67  
      * @return true if the realizer exists else false.
 68  
      */
 69  
     boolean exists(String firstName, String name);
 70  
 
 71  
     /**
 72  
      * Return the realizer with this name and first name.
 73  
      *
 74  
      * @param firstName The first name.
 75  
      * @param name      The name.
 76  
      * @return The realizer.
 77  
      */
 78  
     Person getRealizer(String firstName, String name);
 79  
 
 80  
     /**
 81  
      * Create the realizer.
 82  
      *
 83  
      * @param realizer The realizer to create.
 84  
      */
 85  
     void create(Person realizer);
 86  
 
 87  
     /**
 88  
      * Indicate if the realizer exists or not.
 89  
      *
 90  
      * @param realizer The realizer to test.
 91  
      * @return true if the realizer exist else false.
 92  
      */
 93  
     boolean exists(Person realizer);
 94  
 
 95  
     /**
 96  
      * Indicate if there is no realizers.
 97  
      *
 98  
      * @return true if there is no realizers else false.
 99  
      */
 100  
     boolean hasNoRealizers();
 101  
 
 102  
     /**
 103  
      * Save the realizer.
 104  
      *
 105  
      * @param realizer The realizer to save.
 106  
      */
 107  
     void save(Person realizer);
 108  
 }