Coverage Report - org.kuali.rice.krms.impl.repository.PropositionBoService
 
Classes in this File Line Coverage Branch Coverage Complexity
PropositionBoService
N/A
N/A
1
 
 1  
 /**
 2  
  * Copyright 2005-2011 The Kuali Foundation
 3  
  *
 4  
  * Licensed under the Educational Community License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  *
 8  
  * http://www.opensource.org/licenses/ecl2.php
 9  
  *
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  */
 16  
 package org.kuali.rice.krms.impl.repository;
 17  
 
 18  
 import java.util.List;
 19  
 
 20  
 
 21  
 import org.kuali.rice.krms.api.repository.proposition.PropositionDefinition;
 22  
 import org.kuali.rice.krms.api.repository.proposition.PropositionParameter;
 23  
 
 24  
 public interface PropositionBoService {
 25  
 
 26  
     /**
 27  
      * This will create a {@link PropositionDefinition} exactly like the parameter passed in.
 28  
      *
 29  
      * @param prop the proposition to create
 30  
      * @throws IllegalArgumentException if the proposition is null
 31  
      * @throws IllegalStateException if the proposition already exists in the system
 32  
      */
 33  
     PropositionDefinition createProposition(PropositionDefinition prop);
 34  
 
 35  
     /**
 36  
      * This will update an existing {@link PropositionDefinition}.
 37  
      *
 38  
      * @param prop the proposition to update
 39  
      * @throws IllegalArgumentException if the proposition is null
 40  
      * @throws IllegalStateException if the proposition does not exist in the system
 41  
      */
 42  
     void updateProposition(PropositionDefinition prop);
 43  
 
 44  
     /**
 45  
      * Lookup the proposition based on the given proposition id.
 46  
      *
 47  
      * @param propId the given proposition id
 48  
      * @return a proposition associated with the given proposition id.  A null reference is returned if an invalid or
 49  
      *         non-existent id is supplied.
 50  
      */
 51  
     PropositionDefinition getPropositionById(String propId);
 52  
 
 53  
 
 54  
 
 55  
     /**
 56  
      * This will create a {@link PropositionParameter} exactly like the parameter passed in.
 57  
      *
 58  
      * @param parameter the proposition parameter to create
 59  
      * @throws IllegalArgumentException if the proposition parameter is null
 60  
      * @throws IllegalStateException if the proposition parameter is already existing in the system
 61  
      */
 62  
     void createParameter(PropositionParameter parameter);
 63  
 
 64  
     /**
 65  
      * This will update a {@link PropositionParameter}.
 66  
      *
 67  
      *
 68  
      * @param parameter the proposition parameter to update
 69  
      * @throws IllegalArgumentException if the proposition parameter is null
 70  
      * @throws IllegalStateException if the proposition parameter does not exist in the system
 71  
      */
 72  
     void updateParameter(PropositionParameter parameter);
 73  
 
 74  
     /**
 75  
      * Lookup the proposition parameters based on the given proposition id.
 76  
      *
 77  
      * @param id the given proposition id
 78  
      * @return a list of PropositionParameters associated with the given proposition id.  A null reference is returned if an invalid or
 79  
      *         non-existant id is supplied.
 80  
      */
 81  
     List<PropositionParameter> getParameters(String propId);
 82  
 
 83  
     /**
 84  
      * Lookup the proposition parameter based on the id.
 85  
      *
 86  
      * @param id the given proposition id
 87  
      * @return an immutable PropositionParameters associated with the given id.  A null reference is returned if an invalid or
 88  
      *         non-existant id is supplied.
 89  
      */
 90  
     PropositionParameter getParameterById(String id);
 91  
 
 92  
     /**
 93  
      * Lookup the proposition parameter based on the proposition id and sequence number.
 94  
      *
 95  
      * @param id the given proposition id
 96  
      * @return an immutable PropositionParameters associated with the given proposition id and sequence number.  A null reference is returned if an invalid or
 97  
      *         non-existant.
 98  
      */
 99  
     PropositionParameter getParameterByPropIdAndSequenceNumber(String propId, Integer sequenceNumber);
 100  
 
 101  
 
 102  
 }