Clover.NET coverage report - Coverage for s2dao.net

Coverage timestamp: 2006年5月18日 15:09:15

File Stats: LOC: 106   Methods: 13
NCLOC: 73 Classes: 1
 
Source File Conditionals Statements Methods TOTAL
Seasar.Dao.Attrs\AttributeUtil.cs - 100.0% 92.3% 96.0%
coverage coverage
1   #region Copyright
2   /*
3   * Copyright 2005 the Seasar Foundation and the Others.
4   *
5   * Licensed under the Apache License, Version 2.0 (the "License");
6   * you may not use this file except in compliance with the License.
7   * You may obtain a copy of the License at
8   *
9   * http://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
14   * either express or implied. See the License for the specific language
15   * governing permissions and limitations under the License.
16   */
17   #endregion
18  
19   using System;
20   using System.Reflection;
21  
22   namespace Seasar.Dao.Attrs
23   {
24   /// <summary>
25   /// AttributeUtil の概要の説明です。
26   /// </summary>
27   public sealed class AttributeUtil
28   {
29 0 private AttributeUtil()
30   {
31   }
32  
33 244 public static ColumnAttribute GetColumnAttribute(PropertyInfo pi)
34   {
35 244 return Attribute.GetCustomAttribute(pi,
36   typeof(ColumnAttribute)) as ColumnAttribute;
37   }
38  
39 44 public static TableAttribute GetTableAttribute(Type type)
40   {
41 44 return Attribute.GetCustomAttribute(type,
42   typeof(TableAttribute)) as TableAttribute;
43   }
44  
45 44 public static VersionNoPropertyAttribute GetVersionNoPropertyAttribute(Type type)
46   {
47 44 return Attribute.GetCustomAttribute(type,
48   typeof(VersionNoPropertyAttribute)) as VersionNoPropertyAttribute;
49   }
50  
51 44 public static TimestampPropertyAttribute GetTimestampPropertyAttribute(Type type)
52   {
53 44 return Attribute.GetCustomAttribute(type,
54   typeof(TimestampPropertyAttribute)) as TimestampPropertyAttribute;
55   }
56  
57 259 public static RelnoAttribute GetRelnoAttribute(PropertyInfo pi)
58   {
59 259 return Attribute.GetCustomAttribute(pi,
60   typeof(RelnoAttribute)) as RelnoAttribute;
61   }
62  
63 257 public static IDAttribute GetIDAttribute(PropertyInfo pi)
64   {
65 257 return Attribute.GetCustomAttribute(pi,
66   typeof(IDAttribute)) as IDAttribute;
67   }
68  
69 112 public static NoPersistentPropsAttribute GetNoPersistentPropsAttribute(MemberInfo mi)
70   {
71 112 return Attribute.GetCustomAttribute(mi,
72   typeof(NoPersistentPropsAttribute)) as NoPersistentPropsAttribute;
73   }
74  
75 15 public static RelkeysAttribute GetRelkeysAttribute(PropertyInfo pi)
76   {
77 15 return Attribute.GetCustomAttribute(pi,
78   typeof(RelkeysAttribute)) as RelkeysAttribute;
79   }
80  
81 18 public static BeanAttribute GetBeanAttribute(Type type)
82   {
83 18 return Attribute.GetCustomAttribute(type,
84   typeof(BeanAttribute)) as BeanAttribute;
85   }
86  
87 116 public static SqlAttribute[] GetSqlAttributes(MethodInfo mi)
88   {
89 116 return Attribute.GetCustomAttributes(mi,
90   typeof(SqlAttribute)) as SqlAttribute[];
91   }
92  
93 38 public static QueryAttribute GetQueryAttribute(MethodInfo mi)
94   {
95 38 return Attribute.GetCustomAttribute(mi,
96   typeof(QueryAttribute)) as QueryAttribute;
97   }
98  
99 54 public static PersistentPropsAttribute GetPersistentPropsAttribute(MethodInfo mi)
100   {
101 54 return Attribute.GetCustomAttribute(mi,
102   typeof(PersistentPropsAttribute)) as PersistentPropsAttribute;
103   }
104   }
105   }
106