Coverage Report - org.kuali.rice.core.api.criteria.AndExpression
 
Classes in this File Line Coverage Branch Coverage Complexity
AndExpression
100%
5/5
N/A
1
AndExpression$Constants
0%
0/1
N/A
1
 
 1  
 /*
 2  
  * Copyright 2011 The Kuali Foundation
 3  
  *
 4  
  * Licensed under the Educational Community License, Version 1.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/ecl1.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.core.api.criteria;
 17  
 
 18  
 import java.util.List;
 19  
 
 20  
 import javax.xml.bind.annotation.XmlAccessType;
 21  
 import javax.xml.bind.annotation.XmlAccessorType;
 22  
 import javax.xml.bind.annotation.XmlRootElement;
 23  
 import javax.xml.bind.annotation.XmlType;
 24  
 
 25  
 /**
 26  
  * An immutable composite expression which implements "and-ing" of multiple
 27  
  * expressions together. 
 28  
  * 
 29  
  * <p>Constructed as part of a {@link Criteria} when built using a
 30  
  * {@link CriteriaBuilder}.
 31  
  * 
 32  
  * @author Kuali Rice Team (rice.collab@kuali.org)
 33  
  */
 34  13
 @XmlRootElement(name = AndExpression.Constants.ROOT_ELEMENT_NAME)
 35  
 @XmlAccessorType(XmlAccessType.NONE)
 36  
 @XmlType(name = AndExpression.Constants.TYPE_NAME)
 37  
 public final class AndExpression extends AbstractCompositeExpression {
 38  
         
 39  
         private static final long serialVersionUID = -6575256900578172242L;
 40  
 
 41  
         /**
 42  
          * Used only by JAXB for construction.
 43  
          */
 44  
         @SuppressWarnings("unused")
 45  
         private AndExpression() {
 46  8
                 super();
 47  8
         }
 48  
         
 49  
         /**
 50  
          * Construct an "And" expression from the given list of expressions.  The given list
 51  
          * of expressions can be null or empty.  If the list is null then it will be
 52  
          * translated internally to an empty list.
 53  
          * 
 54  
          * @param expressions the List of expressions to set on the And expression
 55  
          */
 56  
         AndExpression(List<Expression> expressions) {
 57  10
             super(expressions);
 58  10
         }
 59  
         
 60  
         /**
 61  
      * Defines some internal constants used on this class.
 62  
      */
 63  0
     static class Constants {
 64  
         final static String ROOT_ELEMENT_NAME = "and";
 65  
         final static String TYPE_NAME = "AndType";
 66  
     }
 67  
 
 68  
 }