1 17 18 package org.apache.avalon.fortress; 19 20 29 public final class RoleEntry 30 { 31 private final String m_shortName; 32 private final String m_role; 33 private final Class m_componentClass; 34 private final Class m_handlerClass; 35 36 49 public RoleEntry( final String role, 50 final String shortName, 51 final Class componentClass, 52 final Class handlerClass ) throws IllegalArgumentException 53 { 54 if ( null == role ) 55 { 56 throw new NullPointerException ( "\"role\" cannot be null." ); 57 } 58 if ( null == shortName ) 59 { 60 throw new NullPointerException ( "\"shortname\" cannot be null." ); 61 } 62 if ( null == componentClass ) 63 { 64 throw new NullPointerException ( "\"componentClass\" cannot be null." ); 65 } 66 if ( null == handlerClass ) 67 { 68 throw new NullPointerException ( "\"handlerClass\" cannot be null." ); 69 } 70 71 m_role = role; 72 m_shortName = shortName; 73 m_componentClass = componentClass; 74 m_handlerClass = handlerClass; 75 } 76 77 82 public String getRole() 83 { 84 return m_role; 85 } 86 87 93 public String getShortname() 94 { 95 return m_shortName; 96 } 97 98 103 public Class getComponentClass() 104 { 105 return m_componentClass; 106 } 107 108 114 public Class getHandlerClass() 115 { 116 return m_handlerClass; 117 } 118 } 119 | Popular Tags |